MATLAB: Creating Polar mesh in matlab meshmeshgridpolar I want to plot a surface z = f(x,y) and it is desired to plot it on a circle surface. Is it possible in matlab or can create polar mesh on matlab? Best Answer Hi Reza,% make a rectangular grid of r and theta,% then define x and y in the usual way rr = 0:1:20;thth = (0:.05:1)*2*pi;[r th] = meshgrid(rr,thth);x = r.*cos(th);y = r.*sin(th);z = 1 + x.^2 - y.^2;surf(x,y,z) Related SolutionsMATLAB: Creating a mesh or surf with parametric equations r = linspace(0,1) ;th = linspace(0,2*pi) ;[R,TH] = meshgrid(r,th) ;X = 4*R.*sin(TH) ;Y = R.*cos(TH/2) ;Z = R.^2 ;surf(X,Y,Z) MATLAB: How to plot a circle of some radius on a polar plot th = linspace(0,2*pi,50);r = 10;polar(th,r+zeros(size(th))) Related QuestionZ is not matrix for surf(X,Y,Z)Circle plan using plot and pcolorHow to Plot Grid on a Scatter Plot
Best Answer