登 录
註 冊
论坛
微波仿真网
注册
登录论坛可查看更多信息
微波仿真论坛
>
矩量法 MOM
>
阵列天线程序
发帖
回复
1940
阅读
6
回复
[
资料共享
]
阵列天线程序
离线
任玉虎
江海客
UID :77517
注册:
2011-05-16
登录:
2013-03-07
发帖:
79
等级:
仿真一级
0楼
发表于: 2011-07-04 17:57:53
clear;
u)7 ]1e{
timesrun=0;
>h[(w
while timesrun<1000,
pb$fb
if timesrun==0,
& z gPN8u
SP=0.5;
?f@ 9n ph
PH=0;
ih!~G5Xi9i
N=5;
n4>cERfa
MF=1;
4p x_ZD#J
else,
B+Q+0tw*i
SP=input('Enter element spacing in wavelengths: ');
d +xA:
PH=input('Enter phase difference between elements in degrees: ');
C<t RU5|
N=input('Enter number of elements: ');
cqk]NL`'
MF=input('Enter pattern multiplication factor: ')';
y#bK,}
end;
Y*\6o7
M]B3vPA/v
% This version modified to include isotropic AND short dipole sources
cDO:'-
% both of which are displayed on the same polar plot. This version
DVzssPg
% does not do phase plots.
?48AY6
% F. Merat 3/29/03
\[T{M!s
F;a3
% Compute fields for plotting
a)S(p1BGg
A=0.01:0.01:6.27; % Angle over 2pi radians
BVAr&cu
U=(2*pi*SP*cos(A)+(pi*PH/180))/2; % compute argument
t {=i=K3
FP=(sin(N*U)./sin(U)); % compute isotropic electric field
-,/3"}<^78
FPD=(sin(N*U)./sin(U)).*cos(A); % computer dipole electric field
ss; 5C:*y
R=MF.*abs(FP); % multiply as appropriate
!2tw, QM
Rdipole=MF.*abs(FPD); % compute for array of short dipoles
OT+ Ee
pause(0.9);
SKJW%(|3
% compute the beam area in theta
M1(9A>|nF
B=0.01:0.01:3.14; % B is theta -- the angle from 0 degrees
&9@gm--b:
% 0 <theta (B) < 180 degrees
o4'Wr
W=(2*pi*SP*cos(B)+(pi*PH/180))/2; % compute psi -- phase shift
/=trj5h
PP=(sin(N*W)./sin(W)).^2; % compute unnormalized power
Oc^m_U8>^
Z=0.01*sin(B).*PP; % differential power is PP*sin(theta)*d(theta)
;[caiMA-
SUM=sum(Z); % integrate the elements over 180 degrees
#gI&lO*\gr
DR=(2*(N^2))/SUM; % numerical directivity is Pmax/Pavg.
\kk!Dz*H
% N^2 is Pmax
bx7\QU+
% Not sure of 2; because I only did pi?
F8 ?uQP8
F(E<,l2[
DBI=10*log10(DR); % express in dBi
~B*~'I9b*
% REPEAT FOR DIPOLE
<p)Z/
% compute the beam area in theta
ixzTJ]y u
B=0.01:0.01:3.14; % B is theta -- the angle from 0 degrees
<c\]Ct
% 0 <theta (B) < 180 degrees
{Ve D@
W=(2*pi*SP*cos(B)+(pi*PH/180))/2; % compute psi -- phase shift
mo*'"/
PP=(sin(N*W)./sin(W).*cos(B)).^2; % compute unnormalized power
7&px+155
Z=0.01*sin(B).*PP; % differential power is PP*sin(theta)*d(theta)
d|3o/@k
SUM=sum(Z); % integrate the elements over 180 degrees
Ivjw<XP6K
DRdipole=(2*(N^2))/SUM; % numerical directivity is Pmax/Pavg.
#~1wv^
% N^2 is Pmax
-s89)lUkS
% Not sure of 2; because I only did pi?
=Pj@g/25u
>3+FZ@.iT
DBIdipole=10*log10(DRdipole); % express in dBi
@9<S*
theta=(0:2*pi/626:2*pi); % plot antenna pattern in polar coordinates
YJc%h@ _=]
S" {GlRpd
% plot isotropic pattern
lDlj+fK
polar(theta,(round(R*100))/100,'r');
H1C%o0CPY
hold on;
I)rGOda{
polar(theta,(round(Rdipole*100))/100,'g:');
WCoF{*
title(['Field pattern of ',num2str(N),' sources spaced by ',num2str(SP),' lambda, ','phase delta= ',num2str(PH),' deg']);
mb~./.5F
text(max(R),max(R),['Dtheta = ',num2str((round(DBI*100))/100),' dBi']);
r!~(R+,c
text(max(R),max(R)-1,['Dphi = ',num2str((round(DBIdipole*100))/100),' dBi']);
_^b@>C>O
hold off;
)"F5lOA6
sep=max(R)/20;
u x#.:C|
xcent=sep*((-(N-1)/2)-1);
[NZ-WU&&LP
for elcount=1:N
g#Mv&tU
xcent=xcent+sep;
K@*rVor{
ycent=0;
eB7>t@ED
radius=sep/5;
]DU61Z"v?b
xp=xcent+[-radius:radius/10:radius];
HlF}
yp=ycent+real(sqrt((radius^2)-(xp-xcent).^2));
]xI?,('_m
patch(xp,yp,'k');
qf)C%3gXI
patch(xp,-yp,'k');
RZe#|k+ 8
end;
&8wa ih(|
rp=input('Enter 1 for rectangular plot: ');
vi<X3G6Xh
if rp==1
[='p!7z
figure(2);
4XD)E&
plot(theta*(180/pi),R);
O!yakU+
grid on;
H):-!?:
zoom on;
y]J3hKs
title(['Field Pattern of ',num2str(N),' sources spaced by ',num2str(SP),' lambda, ','phase delta= ',num2str(PH),' deg']);
*i%.{ YH
xlabel('Angle (deg)');
>j) w\i
ylabel('Amplitude (linear)');
FXeV6zfrE
end;
=Iy/cHK
logp=input('Enter 1 for dB plot: ');
e"PMvQ
if logp==1
>"O1`xdG
figure(3);
Yg$@ Wb6
&nb ..
:;q>31:h
VOg/VGJ
未注册仅能浏览
部分内容
,查看
全部内容及附件
请先
登录
或
注册
共
1
条评分
,
rf币
+8
redmoon
rf币
+8
十分期待您分享下一贴!
2012-11-06
离线
klingy
UID :73343
注册:
2011-03-07
登录:
2014-10-09
发帖:
704
等级:
积极交流五级
1楼
发表于: 2011-07-04 18:51:40
楼主辛苦。。。。。。
共
条评分
离线
wsszmy
UID :40419
注册:
2009-08-29
登录:
2015-11-05
发帖:
176
等级:
仿真二级
2楼
发表于: 2012-09-13 16:59:22
多些楼主,楼主辛苦了
共
条评分
离线
yzxsq
奋斗
UID :78446
注册:
2011-06-01
登录:
2018-07-27
发帖:
409
等级:
积极交流四级
3楼
发表于: 2012-11-05 23:44:52
谢谢啊,不错
共
条评分
好好学习,天天向上
离线
redmoon
巍巍昆仑雪莲花
UID :20062
注册:
2008-10-25
登录:
2018-10-28
发帖:
4586
等级:
九级仿真大师
4楼
发表于: 2012-11-06 07:34:11
为何那么多隐藏到字符干扰实验呢
共
条评分
离线
bandwidth
UID :187
注册:
2006-11-08
登录:
2025-09-30
发帖:
7158
等级:
九级仿真大师
5楼
发表于: 2012-11-06 08:05:32
哦,这么多
共
条评分
离线
luokui
向同仁学习!
UID :57314
注册:
2010-04-15
登录:
2013-02-28
发帖:
221
等级:
仿真三级
6楼
发表于: 2012-11-07 08:17:47
如何用,在什么里操作应用啊。谢谢指导
共
条评分
发帖
回复