plotting dipole antenna far-field pattern, with multiple slices
古いコメントを表示
i'm attempting to plot the far field pattern for multiple dipoles in a line, which make up one large one,
however, i need an input for current for each slice, so they can all be plotted on top of eachother so it appears as one dipole.
however, i am running into bugs in ths program, and i need it to ot only calculate the entire thing up at one point, but to do it in a circle so it can plot the field pattern
deltaL=.003366 %meters
beta=12.5664 %
eta=377
i=1.5 %current
betasq=157.914 %beta squared
addpath c:\antennas\ewa
l=.68
a=.001
ker='a'
basis='d'
R=1 %distance, one meter from dipole
E=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,100/.001,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]
pfield(l,a,E,ker,basis)
%this spits out a large complex vector of many rows of the current
for k=0:1:49
i=abs(ans(k))%this will extract a different rom/value from the answer for each count
E=-x*(377*i*betasq*deltaL)/(2*pi)*e^(-sqrt(-1)*beta*R)*cos(theta)(1/(sqrt(-1)*beta*r)^2+1/(sqrt(-1)*beta*r)^3)-y*(377*i*betasq*deltaL)/(4*pi)*e^(-sqrt(-1)*beta)*R*sin(theta)*(1/(sqrt(-1)*beta*r)+1/(sqrt(-1)*beta*r)^2+1/(sqrt(-1)*beta*r)^3)
E=E*2 %second half of dipole
plot(x,y)
hold on
end
回答 (1 件)
Vinod Dwarapudi
2026 年 8 月 4 日 14:05
Hi Neil,
The following example approximates a dipole using multiple short dipoles. The current distribution of a reference dipole is sampled and applied as amplitude and phase excitations to the short dipoles, and the resulting pattern is compared with that of the original dipole.
%% Compare a physical dipole with an equivalent set of short dipoles
fc = 300e6;
c = physconst("lightspeed");
lambda = c/fc;
%% Reference dipole (designed at fc for proper half-wave behavior)
d = design(dipole, fc);
%% Discretize dipole into short dipoles
L = d.Length;
N = 21; % Number of segments
dL = L/N;
% Short dipole element (width must be < length)
elem = dipole;
elem.Length = dL;
elem.Width = dL * 0.05;
% Segment locations along z-axis
z = linspace(-L/2, L/2, N);
% Build conformal array
ca = conformalArray;
ca.ElementPosition = [zeros(N,1), zeros(N,1), z'];
ca.Element = repmat({elem}, 1, N);
%% Sample current distribution from the large dipole
[I_ref, pos_ref] = current(d, fc);
% For z-oriented dipole, use z-component of current (row 3)
z_ref = pos_ref(3,:);
Iz = I_ref(3,:);
% Sort by z-position
[z_sorted, idx] = sort(z_ref);
Iz_sorted = Iz(idx);
% Interpolate amplitude and phase at segment centers
amp_weights = interp1(z_sorted, abs(Iz_sorted), z, 'linear', 0);
phase_weights = interp1(z_sorted, angle(Iz_sorted), z, 'linear', 0);
% Normalize amplitude
amp_weights = amp_weights / max(abs(amp_weights));
ca.AmplitudeTaper = amp_weights;
ca.PhaseShift = rad2deg(phase_weights);
%% Compare directivity patterns
theta = -180:180;
E_dipole = pattern(d, fc, 0, theta,...
Type="directivity");
E_array = pattern(ca, fc, 0, theta,...
Type="directivity");
figure
plot(theta, E_dipole, 'LineWidth', 2)
hold on
plot(theta, E_array, '--', 'LineWidth', 2)
grid on
xlabel('Elevation Angle (deg)')
ylabel('Directivity (dBi)')
title('Dipole vs Array of Short Dipoles (Current Sampled)')
legend('Single Dipole', 'Array of Short Dipoles')

カテゴリ
ヘルプ センター および File Exchange で Language Fundamentals についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!