Hello,
I am trying to replicate the results of a paper where instead of the PML they used Dirichlet periodic boundary condition at the edges of the computational grid, so that opposite edges are mirrored.
The authors give the boundary condition for one pair of edges as:
sigma(0,y,t) = sigma(Lx,y,t), 0 <= y <= Ly
v(0,y,t) = v(Lx,y,t), 0 <= y <= Ly
Where Lx and Ly are the width and height of the computational grid.
How would this be implemented in k wave? I've read on some other posts that you can define Dirichlet sources at the edges to enforce boundary conditions, but I'm not sure how to do it for these conditions.
It seems to me like this is essentially the effect of setting PMLalpha to 0? But the way the conditions are described in the paper make me doubtful and I'm pretty new to this.
Thanks!
k-Wave
A MATLAB toolbox for the time-domain
simulation of acoustic wave fields
Mirroring Boundary Conditions
(3 posts) (2 voices)-
Posted 4 years ago #
-
HI leakerb,
If you want a periodic boundary condition, just set
'PMLAlpha', 0
. The gradients in k-Wave are calculated by an FFT which assumes the field is periodic.You could also see this paper and this respository.
Brad
Posted 4 years ago # -
Thanks Brad!
Posted 4 years ago #
Reply
You must log in to post.