1. 平行二元半波振子阵立体方向图的源代码:clear;clc;sita=meshgrid(eps:pi/180:pi);fai=meshgrid(eps:2*pi/180:2*pi);l=0.25;%对称振子的长度为0.25d=1;%二元阵的间隔距离此处取一倍波长beta=0;%电流初始相位差为0m=1;%电流的幅度比为1r1=abs(cos(2*pi*l*cos(sita)-cos(2*pi*l)./abs(sin(sita);r2=sqrt(1+m*m+2*m*cos(beta+2*pi*d*sin(sita).*sin(fai);r3=r1.*r2;r1max=max(max(r1);r2max=max(max(r2);r3max=max(max(r3);x1,y1,z1=sph2cart(fai,pi/2-sita,r1/r1max);x2,y2,z2=sph2cart(fai,pi/2-sita,r2/r2max);x3,y3,z3=sph2cart(fai,pi/2-sita,r3/r3