Matlab 中极坐标图形的画法
首先画极坐标用到的作图命令是 polarplot ,在其内部和直角坐标一样,直角坐标是要标注横纵坐标,那么在极坐标条件下就是要标注 theta (角度) 和 r(半径),其中 theta 的单位要是弧度制(rad),半径的单位就根据自己的需求即可。
然后就是要标注极坐标图的范围,用命令 thetalim([0 180]),本语句中就是画的半圆。
然后就是确定半径的范围 rlim()
例子如下:
figure('NumberTitle', 'off', 'Name', 'S Parameter (dB)-Polar');
polarplot(theta_rad,H,'r--','LineWidth',1.5)
hold on
polarplot(theta_rad,S_PdB,'b','LineWidth',1.5)
thetalim([0 180]);
rmin = S_PdB(1,1);
rmax = max(S_PdB);
rlim([-50 rmax]);
title('chebyshev低副瓣阵列极坐标图')
legend('预设副瓣参考曲线RdB','方向图(dB)')