How to get in a plot a circle and not an ellipse
2 views (last 30 days)
Show older comments
Boughrara kamel
on 28 Apr 2015
Answered: Image Analyst
on 28 Apr 2015
Hi all, How to get in the figure a circle and not an ellipse. Thank you
t=0:2*pi/50:2*pi;
y=1*sin(4*t);
figure(1);hold on; polar(t,5+y,'-r');ezpolar('5');hold off;
0 Comments
Accepted Answer
Star Strider
on 28 Apr 2015
Specify axis square:
t=0:2*pi/50:2*pi;
y=1*sin(4*t);
figure(1);hold on; polar(t,5+y,'-r');ezpolar('5');hold off;axis square
0 Comments
More Answers (1)
Image Analyst
on 28 Apr 2015
Code for plotting both a circle and an ellipse are in the FAQ: http://matlab.wikia.com/wiki/FAQ#How_do_I_create_a_circle.3F.
0 Comments
See Also
Categories
Find more on Spline Postprocessing in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!