[cig-commits] r21375 - seismo/2D/SPECFEM2D/trunk/src/specfem2D
xie.zhinan at geodynamics.org
xie.zhinan at geodynamics.org
Mon Feb 18 03:46:24 PST 2013
Author: xie.zhinan
Date: 2013-02-18 03:46:23 -0800 (Mon, 18 Feb 2013)
New Revision: 21375
Modified:
seismo/2D/SPECFEM2D/trunk/src/specfem2D/compute_forces_viscoelastic.F90
seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
Log:
fix a bug for using stacey boundary condition in elastic kernel computation after adding the support for computing elastic kernel with PML
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/compute_forces_viscoelastic.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/compute_forces_viscoelastic.F90 2013-02-17 06:50:34 UTC (rev 21374)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/compute_forces_viscoelastic.F90 2013-02-18 11:46:23 UTC (rev 21375)
@@ -1433,7 +1433,8 @@
!
!--- absorbing boundaries
!
- if(anyabs .and. .not. PML_BOUNDARY_CONDITIONS .and. backward_simulation) then
+! if(anyabs .and. .not. PML_BOUNDARY_CONDITIONS .and. backward_simulation) then
+ if(anyabs .and. .not. PML_BOUNDARY_CONDITIONS) then
count_left=1
count_right=1
@@ -1537,9 +1538,11 @@
endif
- accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
- accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
- accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ if((SIMULATION_TYPE == 2 .and. .not. backward_simulation) .or. SIMULATION_TYPE == 1) then
+ accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
+ accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
+ accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ endif
if(SAVE_FORWARD .and. SIMULATION_TYPE ==1) then
if(p_sv)then !P-SV waves
@@ -1653,9 +1656,11 @@
endif
- accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx - traction_x_t0+displtx)*weight
- accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
- accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz - traction_z_t0+displtz)*weight
+ if((SIMULATION_TYPE == 2 .and. .not. backward_simulation) .or. SIMULATION_TYPE == 1) then
+ accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx - traction_x_t0+displtx)*weight
+ accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
+ accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz - traction_z_t0+displtz)*weight
+ endif
if(SAVE_FORWARD .and. SIMULATION_TYPE ==1) then
if(p_sv)then !P-SV waves
@@ -1791,9 +1796,11 @@
endif
- accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
- accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
- accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ if((SIMULATION_TYPE == 2 .and. .not. backward_simulation) .or. SIMULATION_TYPE == 1) then
+ accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
+ accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
+ accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ endif
if(SAVE_FORWARD .and. SIMULATION_TYPE ==1) then
if(p_sv)then !P-SV waves
@@ -1924,9 +1931,11 @@
endif
- accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
- accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
- accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ if((SIMULATION_TYPE == 2 .and. .not. backward_simulation) .or. SIMULATION_TYPE == 1) then
+ accel_elastic(1,iglob) = accel_elastic(1,iglob) - (tx + traction_x_t0+displtx)*weight
+ accel_elastic(2,iglob) = accel_elastic(2,iglob) - ty*weight
+ accel_elastic(3,iglob) = accel_elastic(3,iglob) - (tz + traction_z_t0+displtz)*weight
+ endif
if(SAVE_FORWARD .and. SIMULATION_TYPE ==1) then
if(p_sv)then !P-SV waves
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2013-02-17 06:50:34 UTC (rev 21374)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2013-02-18 11:46:23 UTC (rev 21375)
@@ -5647,7 +5647,7 @@
PML_BOUNDARY_CONDITIONS,ROTATE_PML_ACTIVATE,ROTATE_PML_ANGLE,.false.)
if(SIMULATION_TYPE == 2)then
-
+ if(PML_BOUNDARY_CONDITIONS)then
do ispec = 1,nspec
do i = 1, NGLLX
do j = 1, NGLLZ
@@ -5659,6 +5659,7 @@
enddo
enddo
enddo
+ endif
if(PML_BOUNDARY_CONDITIONS)then
do i = 1, nglob_interface
@@ -5706,7 +5707,7 @@
rmemory_duz_dx_LDDRK,rmemory_duz_dz_LDDRK, &
!ZN PML_BOUNDARY_CONDITIONS,ROTATE_PML_ACTIVATE,ROTATE_PML_ANGLE,.true.)
.false.,ROTATE_PML_ACTIVATE,ROTATE_PML_ANGLE,.true.)
-
+ if(PML_BOUNDARY_CONDITIONS)then
do ispec = 1,nspec
do i = 1, NGLLX
do j = 1, NGLLZ
@@ -5718,6 +5719,7 @@
enddo
enddo
enddo
+ endif
if(PML_BOUNDARY_CONDITIONS)then
do i = 1, nglob_interface
More information about the CIG-COMMITS
mailing list