Z is not matrix for surf(X,Y,Z)
4 views (last 30 days)
Show older comments
I am trying to plot surf(X,Y,Z) but my Z is not a matrix.
TH = [0:0.05*pi:2*pi ];
R = [0:0.5:20];
[X,Y] =pol2cart(TH,R);
[X,Y] = meshgrid(X,Y)
Z = (abs((sqrt(2)/(81*sqrt(pi))).*(6.*R-R.^2).*exp(-R./3).*cos(TH))).^2
Im hoping someone can look over my code and help me out. Thanks
0 Comments
Accepted Answer
More Answers (1)
See Also
Categories
Find more on Creating, Deleting, and Querying Graphics Objects 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!