
Plot circle with radius r and roughness amplitude e
16 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
pramod pal
le 17 Mai 2020
Réponse apportée : Ameer Hamza
le 17 Mai 2020
How to model or plot circular cross-section of radius (r) with roughness of amplitude (e) on the circumference.
0 commentaires
Réponse acceptée
Ameer Hamza
le 17 Mai 2020
Try this
r = 1; % radius
e = 0.15;
theta = linspace(0, 2*pi, 100);
R = r*ones(size(theta)) + (rand(size(theta))-0.5).*e/2;
x = R.*cos(theta);
y = R.*sin(theta);
plot(x, y, '.-');
axis([-r-0.5 r+0.5 -r-0.5 r+0.5])

0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Descriptive Statistics and Visualization dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!