Coding angular spectrum of waves in a fluid

In summary, the person is trying to code ultrasonic transducer radiation in water. They are having difficulties and need help. They post the code and ask for help.
  • #1
chiraganand
113
1
Hi,
I am trying to code ultrasonic transducer radiation in water using angular spectrum of plane waves. I am having difficulties in the sampling and fft. If anybody has an idea about this can you please help me out? I can paste the code once i get some response.
Thanks for your help!
 
Physics news on Phys.org
  • #2
The thing is, it is hard to know whether I can help before I know more details. Perhaps post the code and explain in detail what you have and where you need to go with it.
 
  • #3
mfig said:
The thing is, it is hard to know whether I can help before I know more details. Perhaps post the code and explain in detail what you have and where you need to go with it.
I don't know if the code makes any sense. Initially i assume the velocity on the trnasdcuer surface as constant and 1. I find the directivity function yy and then multiply this with the pressure in the fluid. This multiplied pressure I fast Fourier transform to get the required pressure at the point. Let me know if I am right. Thank you for your help anyways!
tic;
clear all;
c=1480000; %speed of sound in water mm/sec.
f=5000000; %freq. in Hz
w=20; %transducer width in mm
xx=[];
fss=0.01
xx=[-40:fss:40];
zz=[];
zz=[1:0.1:400];
yy=sinc(w*(f/c)*(((xx))));
bbb=[];
dd = 1;
gg=length(xx);
x(1:gg)=0;
x(gg/2-w/(2*fss):gg/2+w/(2*fss))=1;
y=x;
%y=fft(x);
figure; plot(abs(y));
zzz=length(zz);
for ii =1:zzz
d=dd*zz(ii); %distance from transducer in mm
df(ii)=d;
p=y.*exp(1i*2.*(f/c).*pi.*d.^2.*sqrt(((((((xx.^2+d.^2))))))));
h=p.*yy;
u=fft(h);
g=u;
g=fftshift(u);
aaa(ii)=abs(g(round(gg/2)));
bbb(ii,:)=abs(w);
bbb(ii,:)=bbb(ii,:)/max(bbb(ii,:));
end
figure; plot(df,aaa);
toc;
 
  • #4
mfig said:
The thing is, it is hard to know whether I can help before I know more details. Perhaps post the code and explain in detail what you have and where you need to go with it.
I also chanced upon the FOCUS simulation software and they have an angular spectrum module. There are a few places in that code which I am not able to understand. If you could help me understand these parts of the code I would be extremely grateful
 

1. What is the angular spectrum of waves in a fluid?

The angular spectrum of waves in a fluid is a mathematical representation of the spatial distribution of a wave's energy. It describes the amplitude and phase of the wave at different points in space.

2. Why is coding the angular spectrum important?

Coding the angular spectrum allows us to simulate and analyze the behavior of waves in a fluid. This can be useful in understanding and predicting the movement of fluids, such as ocean waves or sound waves in air.

3. What factors affect the coding of the angular spectrum?

The coding of the angular spectrum is affected by the properties of the fluid, such as density and viscosity, as well as the frequency and amplitude of the wave. It can also be influenced by external factors such as boundaries or obstacles in the fluid.

4. How is the angular spectrum coded?

The angular spectrum is typically coded using mathematical algorithms and numerical methods, such as the Fast Fourier Transform (FFT) or Finite Difference Time Domain (FDTD) method. These methods allow for efficient and accurate simulation of the wave behavior in a fluid.

5. What are some applications of coding the angular spectrum of waves in a fluid?

Coding the angular spectrum has many practical applications, including fluid dynamics research, ocean and coastal engineering, and acoustic imaging. It can also be used in the development of technologies such as sonar and ultrasound imaging.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
737
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • Other Physics Topics
Replies
1
Views
3K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
10
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
8
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
Back
Top