Why won't this equation plot?
1 view (last 30 days)
Show older comments
Hey everyone I'm trying to get this code to plot the equation 'os' but it won't output anything onto my figure. Thanks for any help or suggestions, I appreciate it!
z=0.1:.05:.9;
os = 100*exp(-pi*z/(1-z.^2).^(1/2));
plot(z,y);
0 Comments
Accepted Answer
Star Strider
on 30 Sep 2015
You need to vectorise your os assignment, then you have to tell plot to plot ‘os’ rather than ‘y’:
z=0.1:.05:.9;
os = 100*exp(-pi*z./(1-z.^2).^(1/2));
plot(z,os)
More Answers (0)
See Also
Categories
Find more on Graphics Performance in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!