0

I have a rectangular matrix of dimensions (r,theta) and I am trying to display its contours on polar coordinates:

(r,theta) contour plot of a rectangular matrix

This method basically 'wraps' the contours onto polar coordinates, which produces a discontinuity at 0°. I am looking for a way to avoid this. Any ideas on how to transform this matrix in order to plot continuous contours?

0000011111
  • 133
  • 1
  • 9
  • Could you provide the code that generated the above? I suspect that if you replicated the first theta column (theta=0) at the end (theta=360) the plot would become smoother. – RPM Dec 09 '15 at 09:57
  • I'm using something like this: `r = 100:200:900; th = (0:360).*2*pi/360; [TH,R] = meshgrid(th,r); [x,y] = pol2cart(TH,R); %% DISPLAY h = polar(x,y); hold on delete(h) contourf(x,y,M,10,'color','none') [c,h] = contour(x,y,M,[1.5 1.5],'k'); clabel(c,h,[1.5 1.5],'labelspacing',800)` where M is a (r,th) matrix. I've tried adding the first column at 360° and it creates continuous but very angular contours. – 0000011111 Dec 09 '15 at 18:06
  • If you haven't solved this, it would be interesting to ask Mathworks tech support (that's partly why you pay the big bucks for a license, right?). And then please report back here with the answer. – Rich Signell Jan 17 '17 at 12:03
  • Agreed, Rich! I will contact them – 0000011111 Jan 17 '17 at 21:05

0 Answers0