what is my problem using split operator methods on gaussian wave packet time evolution in free space
2 次查看(过去 30 天)
显示 更早的评论
dt = 0.005; % Size of time step
tfinal = 2; % Final time
M = round(tfinal/dt); % Total number of time steps
N = 512; % Number of Fourier modes
L = 20; % Space period
h = L/N; % Space step
n = (-N/2:1:N/2-1)'; % Indices
x = n*h; % Grid points
%initial wavefunction
u0=exp(-1.*(x).^2);
u = u0; % Initial Condition
k = 2*n.*pi/L; % Wavenumbers.
Vx=0; %potential function
ur=exp(-1i*dt/2.*Vx); %U(r) operator
uk=exp(-1i*dt.*k.^2/2); %U(k) operator
for m = 1:1:M % Start time loop
u=ur.*u; %advancing in real space dt/2
c = dt * fftshift(fft(fftshift(u))); % Take Fourier transform
%c=fftshift(fft(u))*dt;% Take Fourier transform
c=uk.*c; %advancing in fourier space dt/2
c=fftshift(ifft(fftshift(c))) * (1/dt); %return to real space
%c=ifft(fftshift(c))*(1/dt); %return to real space
u=ur.*c; %advancing in real space dt/2
end
figure;plot(x,u0,'k',x,u,'r','LineWidth',2)
The time evolution of a gaussian wave packet in free space should be a gaussian wave with spread width, what is the problem about my code?
Your help would be highly appreciated!
0 个评论
回答(1 个)
William Rose
2022-9-17
Plot abs(u), instead of u, and you will see that the transformed signal is still Gaussian, as expected.
.
4 个评论
William Rose
2022-9-19
@Daniel Niu, you are welcome. This problem and the solution are interesting. ur is simply unity. uk is a phase shift only, since the magnitude of uk is unity. The amount of phase shift for each dt (i.e. the rate of phase change) is proportional to the wavenumber squared (k^2).
Each sinusoidal component in the initial Gaussian waveform has phase angle=0. As time progresses, the phase angle of each sinusoid changes, but the magnitude stays the same. As the phase angles change, they interfere with each other in a different way than they did initially. Therefore , even though each sinusoid has the same magnitude and frequency as before, their sum results in a Gaussian which broadens with time. And, as you observed, the wavefunction, withich was purely real initially, becomes complex valued. Good luck!
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!