资源简介
波束形成MATLAB程序,包括线阵、平面阵和圆阵
代码片段和文件信息
clear all;
close all;
clc;
f=1000; %阵元发射信号频率
c=1500; %声速
lamta=c/f; %波长
d=lamta/2; %阵元间距为半波长
%%%%%%%%%%%%%%%%%均匀线阵%%%%%%%%%%%%%%%
theta=-pi:pi/360:pi;
phai=-pi:pi/360:pi; %方位角范围
thetad=30*pi/180; %阵列指向
betad=2*pi*d*sin(thetad)/lamta;
m1=8; %阵元个数
beta = 2*pi*d*sin(theta)/lamta;
G11=sin(m1*(beta-betad)/2);
G12=m1*sin((beta-betad)/2);
G1=abs(G11./G12);
GL=20*log(G1/max(G1));
figure
plot(theta*180/piGL);grid;
axis([-180 180 -100 0]);
title(‘阵元M=8thetad=30均匀线阵方向图‘);
xlabel(‘方位角/度‘);
ylabel(‘G(\theta)/dB‘);
figure
polar(thetaG1);title(‘阵元M=8thetad=30均匀线阵方向图‘);
xx=inline(‘abs((sin(8*(pi*sin(theta))/2))./(8*sin((pi*sin(theta))/2)))*sin(theta)*cos(phai)‘);
yy=inline(‘abs((sin(8*(pi*sin(theta))/2))./(8*sin((pi*sin(theta))/2)))*sin(theta)*sin(phai)‘);
yz=inline(‘abs((sin(8*(pi*sin(theta))/2))./(8*sin((pi*sin(theta))/2)))*cos(theta)‘);
figure
ezmesh(xxyyyz[0 2*pi 0 pi]100);
%%%%%%%%%%%%%%%%%平面阵%%%%%%%%%%%%%%%%%
x=16;
y=16; %16*16面阵
z=16;
theta1=0:pi/360:pi; %方位角
fai1=0:pi/360:pi; %俯仰角
[fai1theta1]=meshgrid(fai1theta1);
beta1=2*pi*d*cos(theta1).*cos(fai1)/lamta;
beta2=2*pi*d*sin(theta1).*cos(fai1)/lamta;
beta3=2*
评论
共有 条评论