How do I convert spirographic values for r, R, and a to the code for a polar plot?
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Bella Finkel
le 6 Déc 2015
Réponse apportée : Star Strider
le 6 Déc 2015
I'm trying to create a polar plot using the radius of a large circle, a small circle, and the distance from the center of the small circle to the drawing point. I don't know how these values relate to what is used in a MATLAB code.
0 commentaires
Réponse acceptée
Star Strider
le 6 Déc 2015
If you want to plot a hypotrochoid, you do not need a polar plot. This code uses a Cartesian plot:
A = 5.0;
B = 0.5;
d = 2.0;
t = linspace(0, 2*pi, 500);
x=(A-B)*cos(t)+d*cos((A-B)/(B)*t);
y=(A-B)*sin(t)-d*sin((A-B)/(B)*t);
figure(1)
plot(x, y, '-r')
grid
axis equal
to produce this figure:
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Polar Plots dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!