hi, I trying to plot radiation resistance and Directivity of Horizontal electric dipole, but i am not getting correct result as given in Balanis Book.
I have also attached graph from Balanis
Here is my code,
PI = 4.0*atan(1.0);
Wave_impe = 120.0*PI;
h=5;
L=1/50;
A = L*PI;
Io = 1;
r=2;
% U=zeros(2000,2000);
UMAX=0;
k=2*pi;
i=0;
j=1;
a=0;
for i=0:0.01:h;
R=(2/3 - sin(2*k*i)/2*k*i - cos(2*k*i)/(2*k*i)^2 + sin(2*k*i)/(2*k*i)^3);
Rr(j)=Wave_impe*pi*R*L^2;
if (k*i<= pi/2)
a(j)= (4* (sin(k*i))^2)/R;
else
a(j)=4/R;
end
D(j)=a(j);
j=j+1;
end
plot(Rr,'r');
hold on;
plot(D,'k');