I try to understand a matlab code for planar arrays. I would be very appreciated if somebody help me.
In the following code, there are 2 angels. Theta and phi. The theta is array element angel to z direction and phi is to x direction.as i know. If I want to see braodside pattern ,which theta or phi angle do i need ? And if want to compare my pattern for different angles, which angle should i compare ? I am little bit confused about theta and phi, how i should understandt these two.
%AF calculation
theta0=pi/200
i/200:2*pi;
phi0=pi/200
i/200
i;
[phi,theta]=meshgrid(phi0,theta0);
sinU=sin(theta).*cos(phi);
sinV=sin(theta).*sin(phi);
AF=0;
for n=1:5
for m=1:4
AF = AB_coe(n,m)*exp(j*
*k*dx*(sinU)).*exp(j*k*(m)*dy*(sinV)) + AF;
end
end