Skip to content

Commit

Permalink
Fix xmax edge index in Stacey ABC
Browse files Browse the repository at this point in the history
  • Loading branch information
SouzaEM committed Oct 31, 2024
1 parent 472e8b3 commit 30ecd38
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions spyro/solvers/elastic_wave/local_abc.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,10 +188,10 @@ def stacey_terms(ndim, rho, c_p, c_s,
sig_xx = -rho*c_p*ux_dt + rho*c_s*(c_p - 2*c_s)*uz_dz
if ndim == 3:
sig_xx += rho*c_s*(c_p - 2*c_s)*uy_dy
F_t += (sig_zx*v[iz] + sig_xx*v[ix])*ds(3, scheme=qr_s)
F_t += (sig_zx*v[iz] + sig_xx*v[ix])*ds(4, scheme=qr_s)
if ndim == 3:
sig_yx = -rho*c_s*uy_dt - rho*c_s*(c_p - 2*c_s)*ux_dy
F_t += sig_yx*v[iy]*ds(3, scheme=qr_s)
F_t += sig_yx*v[iy]*ds(4, scheme=qr_s)

if ndim == 3:
# Plane y = 0
Expand All @@ -206,4 +206,4 @@ def stacey_terms(ndim, rho, c_p, c_s,
sig_yy = -rho*c_p*uy_dt + rho*c_s*(c_p - 2*c_s)*(uz_dz + ux_dx)
F_t += (sig_zy*v[iz] + sig_xy*v[ix] + sig_yy*v[iy])*ds(6, scheme=qr_s)

return F_t
return F_t

0 comments on commit 30ecd38

Please sign in to comment.