声振论坛

 找回密码
 我要加入

QQ登录

只需一步,快速开始

查看: 1341|回复: 0

[声学基础] 求教:小弟编了一个由点声源计算全息面声压的问题

[复制链接]
发表于 2008-7-6 17:04 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?我要加入

x
我编了一个由点声源辐射到全息面和重建面的声压,然后由全息面的声压重建点声源和重建面的声压,但是结果不对,请问那位大侠能够指点一二,是参数选择有问题还是傅立叶变换有问题?
clear
f=340;
c0=340;
p0=1.25;
w=2*pi*f;
k=2*pi*f/340;
lx=2;
ly=2;
N=32;
zh=0.1;
z=0.05;
N=32;
l1=0:N-1;
m1=0:N-1;
r1=0:N-1;
s1=0:N-1;
l=l1-N/2;
m=m1-N/2;
r=r1-N/2;
s=s1-N/2;
x=l*lx/N;
y=m*ly/N;
dx=lx/N;
dy=ly/N;
r1=sqrt(x.^2+y.^2+zh^2);
r2=sqrt(x.^2+y.^2+z.^2);
r0=0.001;
ua=0.5;
'点声源强度'
Q0=4*pi*r0.^2*ua
t=0:0.001:0.031;
ff1=exp(j*(w*t-k*r1));
ff2=exp(j*(w*t-k*r2));
p1=j*k*p0*c0*Q0*ff1./(4*pi*r1);
'理论全息面的声压'
p1=20*log(abs(p1))
p2=j*k*p0*c0*Q0*ff2./(4*pi*r2);
'理论重建面的声压'
p2=20*log(abs(p2))
%%波数域的参数
kx=r*2*pi/lx;
ky=s*2*pi/ly;
ff=exp(-j*2*pi*(r/N.*l+s/N.*m));
%%全息面的复声压转换到波数
PP1=lx*ly/(2*pi*N.^2)*sum(p1'*ff);
%%重建面的声压转换到波数域
PP2=lx*ly/(2*pi*N.^2)*sum(p2'*ff);
%%%全息面的格林函数的傅立叶变换和声源面的格林函数
Gd1=exp(j*(z-zh)).*sqrt(k.^2-kx.^2-ky.^2);
Gd2=exp(j*(zh)).*sqrt(k.^2-kx.^2-ky.^2);
k0=kx.^2+ky.^2;
Gd=Gd1;
zp0=PP1.*Gd1;
zp1=PP2.*Gd2;
ss0=exp(j*(kx.*x+ky.*y));
%%%重构的全西面声压和重建面的声压
pp1=2*pi/(lx*ly)*sum(zp0'*ss0);
pp2=2*pi/(lx*ly)*sum(zp1'*ss0);
'重建面的声压'
pp1=20*log(abs(pp1))
'重建生源面的声压'
pp2=20*log(abs(pp2))
计算结果:
点声源强度


Q0 =

  6.2832e-006


ans =

理论全息面的声压


p1 =

  Columns 1 through 11

-139.3552 -138.0713 -136.6998 -135.2280 -133.6402 -131.9167 -130.0324 -127.9548 -125.6404 -123.0296 -120.0381

  Columns 12 through 22

-116.5416 -112.3490 -107.1555 -100.4928  -92.0953  -86.3221  -92.0953 -100.4928 -107.1555 -112.3490 -116.5416

  Columns 23 through 32

-120.0381 -123.0296 -125.6404 -127.9548 -130.0324 -131.9167 -133.6402 -135.2280 -136.6998 -138.0713


ans =

理论重建面的声压


p2 =

  Columns 1 through 11

-139.3178 -138.0287 -136.6510 -135.1714 -133.5739 -131.8378 -129.9372 -127.8374 -125.4922 -122.8368 -119.7772

  Columns 12 through 22

-116.1695 -111.7774 -106.1752  -98.4861  -86.6298  -72.4592  -86.6298  -98.4861 -106.1752 -111.7774 -116.1695

  Columns 23 through 32

-119.7772 -122.8368 -125.4922 -127.8374 -129.9372 -131.8378 -133.5739 -135.1714 -136.6510 -138.0287


ans =

重建面的声压


pp1 =

  Columns 1 through 11

  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238

  Columns 12 through 22

  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238

  Columns 23 through 32

  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238  146.3238


ans =

重建生源面的声压


pp2 =

  Columns 1 through 11

  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434

  Columns 12 through 22

  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434

  Columns 23 through 32

  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434  146.1434
谢谢各位指教

本帖被以下淘专辑推荐:

回复
分享到:

使用道具 举报

您需要登录后才可以回帖 登录 | 我要加入

本版积分规则

QQ|小黑屋|Archiver|手机版|联系我们|声振论坛

GMT+8, 2024-11-18 02:48 , Processed in 0.051970 second(s), 19 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表