3D FFT. initialization

9 visualizaciones (últimos 30 días)
Tlotlo Oepeng
Tlotlo Oepeng el 10 de Mayo de 2021
%% -- propagation Variable(z) --
L = 30; % length of space
step_num = 300; % represented z steps
dz = L/step_num; % Step size in z = 0.1
%% %% -- t, x, and y Arrays --
nt = 500;
tmax = 50 ; % FFT point and window size
t2 = (0:dt:tmax); % Temporal Grid
t = t2(1:nt);
ktt = (2*pi/tmax)*[0:nt/2 -nt/2:-2]; % Frequency Grid
dt = tmax/nt; % Step size in t
N = 500; % No. of Fourier modes(sample points)
gridsize = 10;
x = (gridsize/N)*(-N/2:N/2-1); % Grid point along x
y = (gridsize/N)*(-N/2:N/2-1); % Grid point along y
[X,Y] = meshgrid(x,y);
% -- wave numbers
kx = [0:N/2 -N/2+1:-1];
ky = [0:N/2 -N/2+1:-1];
[kxx,kyy]= meshgrid(kx,ky); % Wave number along both direction
kxx = (2*pi/gridsize)*kxx; % scaling
kyy = (2*pi/gridsize)*kyy;
im solving a 3D wave eqaution using split step FM. the wave is moving along z, i have an extra propgation Vector K in time "ktt". im wondering if my initializtion is correct. or shoiuld i do a 3d mesh grid [T,X,Y]?

Respuestas (0)

Categorías

Más información sobre Fourier Analysis and Filtering en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by