You're converting expression to polar form incorrectly.
You should get r=r(theta) from {r=r(t),theta=theta(t)} by excluding parameter
t (which is not an argument). Anyway, it's better to start from known polar
equation of cardioid
r = a (1-cos(theta)).
So, parametric equations are
x = a cos t (1-cos(t)),
y = a sin t (1-cos(t)).
In your case a = 1/2:
e^{it}/2 - e^{2it}/4 =
= (1/2 cos(t) - 1/4 cos(2t)) + i (1/2 sin(t) - 1/4 sin(2t)) =
= 1/2 cos(t) (1-cos(t)) + i 1/2 sin(t) (1-cos(t)).
On Sunday 30 March 2008 11:12, Adam Majewski wrote:
> I want to draw special cardioid defined by equation:
>
> e1:exp(t*%i)/2-exp(2*t*%i)/4;
>
> Can I draw it in such form ?
>
> I have done it by 2 methods:
>
> /* draws cardioid in parametric form */
> e1:exp(t*%i)/2-exp(2*t*%i)/4;
> re:realpart(e1);
> im:imagpart(e1);
> /*demoivre(e1);*/
> plot2d ([parametric,re,im,[t,0,2*%pi],[nticks,200]],[x,-2.5,
> 0.5],[y,-1.5,1.5],[gnuplot_preamble, "set xzeroaxis; set grid"])$
>
>
> I works good.
>
> And second method :
>
> /* draws cardioid in polar form */
> e1:exp(t*%i)/2-exp(2*t*%i)/4;
> r:abs(e1);
> load(draw);
> draw2d(nticks = 2000, xrange = [-2.5,0.5], yrange=[-1.5,1.5], color =
> blue, line_width
> = 3, polar(r,t,0,2*%pi),grid=true)$
>
> It semms to me the same but graphical result is diffrent.
>
> Can it be done better ?
--
Alexey Beshenov <al at beshenov.ru>
http://beshenov.ru/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.math.utexas.edu/pipermail/maxima/attachments/20080330/d8508dcd/attachment.pgp