\begin{tikzpicture}[scale=0.8]
\begin{axis}[
trig format plots=rad,
axis equal, axis x line=middle, axis y line=
middle, xlabel={$x$}, ylabel={$y$},xmin=-3,xmax=3,ymin=-4,ymax=4]
\addplot [domain=-2:2, samples=590, red,very thick]({(3*x)/(1+x^3)},{(3*x^2)/(1+x^3)});
\end{axis}
\end{tikzpicture}
请参阅上面我的笛卡尔叶代码。我的问题是,如何让它看起来像叶。我尝试增加样本,但在输入 600 后,我收到错误(尺寸太大)
答案1
如果你想坚持斜坡,你必须小心领域。
\documentclass[tikz,border=3.14mm]{standalone}
\usepackage{pgfplots}
\begin{document}
\begin{tikzpicture}
\begin{axis}[
trig format plots=rad,
axis equal, axis x line=middle, axis y line=
middle, xlabel={$x$}, ylabel={$y$},xmin=-3,xmax=3,ymin=-4,ymax=4]
\addplot [domain=-1:180, smooth,samples=2000, red,very thick]({(3*x)/(1+x^3)},{(3*x^2)/(1+x^3)});
\addplot [domain=-180:-1, smooth,samples=2000, red,very thick]({(3*x)/(1+x^3)},{(3*x^2)/(1+x^3)});
\end{axis}
\end{tikzpicture}
\end{document}
最好用极坐标来绘制它。