[cig-commits] [commit] devel: reverted my changes for hdur_tiny(), which did not fix the bug when FORCE_SOLUTION is used (81e6e91)
cig_noreply at geodynamics.org
cig_noreply at geodynamics.org
Fri Oct 3 07:42:04 PDT 2014
Repository : https://github.com/geodynamics/specfem3d
On branch : devel
Link : https://github.com/geodynamics/specfem3d/compare/41b02e93e740a016757934b1be4d36eee444ec39...e0b7c32c2be8739824d62f655af795bab5c732be
>---------------------------------------------------------------
commit 81e6e91552a42aa6f202385c7869848b1d6f3150
Author: Dimitri Komatitsch <komatitsch at lma.cnrs-mrs.fr>
Date: Fri Oct 3 16:21:59 2014 +0200
reverted my changes for hdur_tiny(), which did not fix the bug when FORCE_SOLUTION is used
>---------------------------------------------------------------
81e6e91552a42aa6f202385c7869848b1d6f3150
src/specfem3D/finalize_simulation.f90 | 5 +++--
src/specfem3D/setup_sources_receivers.f90 | 11 +++++++----
2 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/src/specfem3D/finalize_simulation.f90 b/src/specfem3D/finalize_simulation.f90
index d22a8c8..d880c43 100644
--- a/src/specfem3D/finalize_simulation.f90
+++ b/src/specfem3D/finalize_simulation.f90
@@ -169,10 +169,11 @@
deallocate(comp_dir_vect_source_E)
deallocate(comp_dir_vect_source_N)
deallocate(comp_dir_vect_source_Z_UP)
+ if (.not. USE_RICKER_TIME_FUNCTION) then
+ deallocate(hdur_tiny)
+ endif
endif
- deallocate(hdur_tiny)
-
! mass matrices
if( ELASTIC_SIMULATION ) then
deallocate(rmassx)
diff --git a/src/specfem3D/setup_sources_receivers.f90 b/src/specfem3D/setup_sources_receivers.f90
index 66ef435..50d9655 100644
--- a/src/specfem3D/setup_sources_receivers.f90
+++ b/src/specfem3D/setup_sources_receivers.f90
@@ -106,11 +106,12 @@
comp_dir_vect_source_N(NSOURCES), &
comp_dir_vect_source_Z_UP(NSOURCES),stat=ier)
if (ier /= 0) stop 'error allocating arrays for force point sources'
+ if (.not. USE_RICKER_TIME_FUNCTION) then
+ allocate(hdur_tiny(NSOURCES),stat=ier)
+ if (ier /= 0) stop 'error allocating arrays for force point sources'
+ endif
endif
- allocate(hdur_tiny(NSOURCES),stat=ier)
- if (ier /= 0) stop 'error allocating arrays for force point sources'
-
! for source encoding (acoustic sources so far only)
allocate(pm1_source_encoding(NSOURCES),stat=ier)
if( ier /= 0 ) stop 'error allocating arrays for sources'
@@ -145,7 +146,9 @@
hdur_gaussian(:) = hdur(:)/SOURCE_DECAY_MIMIC_TRIANGLE
! initialize a very short (but non-zero) half duration to use a pseudo-Dirac function
- hdur_tiny(:) = 5.d0*DT
+ if(USE_FORCE_POINT_SOURCE .and. .not. USE_RICKER_TIME_FUNCTION) then
+ hdur_tiny(:) = 5*DT
+ endif
! define t0 as the earliest start time
! note: an earlier start time also reduces numerical noise due to a
More information about the CIG-COMMITS
mailing list