theta = linspace(-pi, pi, 300);
p = 2-4*cos(theta);
polar(theta, p)