[cig-commits] r22625 - in seismo/3D/SPECFEM3D_GLOBE/trunk/src: create_header_file meshfem3D shared specfem3D

dkomati1 at geodynamics.org dkomati1 at geodynamics.org
Tue Jul 16 07:15:26 PDT 2013


Author: dkomati1
Date: 2013-07-16 07:15:25 -0700 (Tue, 16 Jul 2013)
New Revision: 22625

Modified:
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/create_header_file/create_header_file.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_mass_matrices.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_regions_mesh.F90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/meshfem3D.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/save_arrays_solver.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/read_compute_parameters.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/save_header_file.F90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/prepare_timerun.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_arrays_solver.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_mesh_databases.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/specfem3D.F90
Log:
converted NGLOB_XY_CM,NGLOB_XY_CM_BACKWARD,NGLOB_XY_IC,NGLOB_XY_IC_BACKWARD from variables to constants in values_from_mesher.h


Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/create_header_file/create_header_file.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/create_header_file/create_header_file.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/create_header_file/create_header_file.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -217,7 +217,8 @@
                   NSPEC_CRUST_MANTLE_STACEY,NSPEC_OUTER_CORE_STACEY, &
                   NGLOB_CRUST_MANTLE_OCEANS,NSPEC_OUTER_CORE_ROTATION, &
                   SIMULATION_TYPE,SAVE_FORWARD,MOVIE_VOLUME,SAVE_REGULAR_KL,NOISE_TOMOGRAPHY, &
-                  ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY,SAVE_SOURCE_MASK)
+                  ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY, &
+                  SAVE_SOURCE_MASK,ABSORBING_CONDITIONS,USE_LDDRK,EXACT_MASS_MATRIX_FOR_ROTATION)
 
   print *
   print *,'edit file OUTPUT_FILES/values_from_mesher.h to see'

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_mass_matrices.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_mass_matrices.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_mass_matrices.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -138,7 +138,7 @@
 
   ! initializes matrices
   !
-  ! in the case of stacey boundary conditions, add C*delta/2 contribution to the mass matrix
+  ! in the case of Stacey boundary conditions, add C*delta/2 contribution to the mass matrix
   ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
   ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
   !

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_regions_mesh.F90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_regions_mesh.F90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/create_regions_mesh.F90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -976,7 +976,7 @@
 
     ! allocates mass matrices in this slice (will be fully assembled in the solver)
     !
-    ! in the case of stacey boundary conditions, add C*delta/2 contribution to the mass matrix
+    ! in the case of Stacey boundary conditions, add C*delta/2 contribution to the mass matrix
     ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
     ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
     !

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/meshfem3D.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/meshfem3D.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/meshfem3D.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -877,7 +877,8 @@
                     NSPEC_CRUST_MANTLE_STACEY,NSPEC_OUTER_CORE_STACEY, &
                     NGLOB_CRUST_MANTLE_OCEANS,NSPEC_OUTER_CORE_ROTATION, &
                     SIMULATION_TYPE,SAVE_FORWARD,MOVIE_VOLUME,SAVE_REGULAR_KL,NOISE_TOMOGRAPHY, &
-                    ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY,SAVE_SOURCE_MASK)
+                    ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY, &
+                    SAVE_SOURCE_MASK,ABSORBING_CONDITIONS,USE_LDDRK,EXACT_MASS_MATRIX_FOR_ROTATION)
 
   endif   ! end of section executed by main process only
 

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/save_arrays_solver.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/save_arrays_solver.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/meshfem3D/save_arrays_solver.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -257,7 +257,7 @@
 
   ! mass matrices
   !
-  ! in the case of stacey boundary conditions, add C*deltat/2 contribution to the mass matrix
+  ! in the case of Stacey boundary conditions, add C*deltat/2 contribution to the mass matrix
   ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
   ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
   !

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/read_compute_parameters.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/read_compute_parameters.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/read_compute_parameters.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -851,8 +851,8 @@
   if(PARTIAL_PHYS_DISPERSION_ONLY .and. UNDO_ATTENUATION) &
     stop 'cannot have both PARTIAL_PHYS_DISPERSION_ONLY and UNDO_ATTENUATION, they are mutually exclusive'
 
-  if(ROTATION .and. ABSORBING_CONDITIONS .and. .not. EXACT_MASS_MATRIX_FOR_ROTATION) &
-    stop 'set EXACT_MASS_MATRIX_FOR_ROTATION to .true. when ABSORBING_CONDITIONS is on because there is then no additional cost'
+  if(ROTATION .and. ABSORBING_CONDITIONS .and. .not. EXACT_MASS_MATRIX_FOR_ROTATION) stop &
+    'set EXACT_MASS_MATRIX_FOR_ROTATION to .true. when ABSORBING_CONDITIONS is on because there is then almost no additional cost'
 
   if (OUTPUT_SEISMOS_SAC_ALPHANUM .and. (mod(NTSTEP_BETWEEN_OUTPUT_SEISMOS,5)/=0)) &
     stop 'if OUTPUT_SEISMOS_SAC_ALPHANUM = .true. then NTSTEP_BETWEEN_OUTPUT_SEISMOS must be a multiple of 5, check the Par_file'

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/save_header_file.F90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/save_header_file.F90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/shared/save_header_file.F90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -27,7 +27,7 @@
 
 ! save header file OUTPUT_FILES/values_from_mesher.h
 
-  subroutine save_header_file(NSPEC,nglob,NEX_XI,NEX_ETA,NPROC,NPROCTOT, &
+  subroutine save_header_file(NSPEC,NGLOB,NEX_XI,NEX_ETA,NPROC,NPROCTOT, &
                         TRANSVERSE_ISOTROPY,ANISOTROPIC_3D_MANTLE,ANISOTROPIC_INNER_CORE, &
                         ELLIPTICITY,GRAVITY,ROTATION,TOPOGRAPHY, &
                         OCEANS,ATTENUATION,ATTENUATION_3D, &
@@ -52,19 +52,21 @@
                         NSPEC_CRUST_MANTLE_STACEY,NSPEC_OUTER_CORE_STACEY, &
                         NGLOB_CRUST_MANTLE_OCEANS,NSPEC_OUTER_CORE_ROTATION, &
                         SIMULATION_TYPE,SAVE_FORWARD,MOVIE_VOLUME,SAVE_REGULAR_KL,NOISE_TOMOGRAPHY, &
-                        ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY,SAVE_SOURCE_MASK)
+                        ATT1,ATT2,ATT3,ATT4,ATT5,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY, &
+                        SAVE_SOURCE_MASK,ABSORBING_CONDITIONS,USE_LDDRK,EXACT_MASS_MATRIX_FOR_ROTATION)
 
   implicit none
 
   include "constants.h"
 
-  integer, dimension(MAX_NUM_REGIONS) :: NSPEC, nglob
+  integer, dimension(MAX_NUM_REGIONS) :: NSPEC,NGLOB
 
   integer NEX_XI,NEX_ETA,NPROC,NPROCTOT,NCHUNKS,NSOURCES,NSTEP,NOISE_TOMOGRAPHY
 
   logical TRANSVERSE_ISOTROPY,ANISOTROPIC_3D_MANTLE,ANISOTROPIC_INNER_CORE, &
           ELLIPTICITY,GRAVITY,ROTATION,TOPOGRAPHY,OCEANS,ATTENUATION,ATTENUATION_3D,INCLUDE_CENTRAL_CUBE, &
-          SAVE_REGULAR_KL,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY,SAVE_SOURCE_MASK
+          SAVE_REGULAR_KL,APPROXIMATE_HESS_KL,ANISOTROPIC_KL,PARTIAL_PHYS_DISPERSION_ONLY, &
+          SAVE_SOURCE_MASK,ABSORBING_CONDITIONS,USE_LDDRK,EXACT_MASS_MATRIX_FOR_ROTATION
 
   double precision ANGULAR_WIDTH_XI_IN_DEGREES,ANGULAR_WIDTH_ETA_IN_DEGREES, &
           CENTER_LONGITUDE_IN_DEGREES,CENTER_LATITUDE_IN_DEGREES,GAMMA_ROTATION_AZIMUTH
@@ -89,7 +91,8 @@
          NGLOB_INNER_CORE_ADJOINT,NSPEC_OUTER_CORE_ROT_ADJOINT, &
          NSPEC_CRUST_MANTLE_STACEY,NSPEC_OUTER_CORE_STACEY, &
          NGLOB_CRUST_MANTLE_OCEANS,NSPEC_OUTER_CORE_ROTATION, &
-         NSPEC2D_MOHO, NSPEC2D_400, NSPEC2D_670, NSPEC2D_CMB, NSPEC2D_ICB
+         NSPEC2D_MOHO, NSPEC2D_400, NSPEC2D_670, NSPEC2D_CMB, NSPEC2D_ICB, &
+         NGLOB_XY_CM, NGLOB_XY_IC, NGLOB_XY_CM_BACKWARD, NGLOB_XY_IC_BACKWARD
 
   integer :: SIMULATION_TYPE
   logical :: SAVE_FORWARD,MOVIE_VOLUME
@@ -140,15 +143,15 @@
   write(IOUT,*) '!'
   write(IOUT,*) '! number of processors = ',NPROCTOT ! should be = NPROC
   write(IOUT,*) '!'
-  write(IOUT,*) '! maximum number of points per region = ',nglob(IREGION_CRUST_MANTLE)
+  write(IOUT,*) '! maximum number of points per region = ',NGLOB(IREGION_CRUST_MANTLE)
   write(IOUT,*) '!'
 ! use fused loops on NEC SX
   write(IOUT,*) '! on NEC SX, make sure "loopcnt=" parameter'
-  write(IOUT,*) '! in Makefile is greater than max vector length = ',nglob(IREGION_CRUST_MANTLE)*NDIM
+  write(IOUT,*) '! in Makefile is greater than max vector length = ',NGLOB(IREGION_CRUST_MANTLE)*NDIM
   write(IOUT,*) '!'
 
   write(IOUT,*) '! total elements per slice = ',sum(NSPEC)
-  write(IOUT,*) '! total points per slice = ',sum(nglob)
+  write(IOUT,*) '! total points per slice = ',sum(NGLOB)
   write(IOUT,*) '!'
 
   write(IOUT,'(1x,a,i1,a)') '! total for full ',NCHUNKS,'-chunk mesh:'
@@ -157,11 +160,11 @@
   write(IOUT,*) '! exact total number of spectral elements in entire mesh = '
   write(IOUT,*) '! ',dble(NCHUNKS)*dble(NPROC)*dble(sum(NSPEC)) - subtract_central_cube_elems
   write(IOUT,*) '! approximate total number of points in entire mesh = '
-  write(IOUT,*) '! ',dble(NCHUNKS)*dble(NPROC)*dble(sum(nglob)) - subtract_central_cube_points
+  write(IOUT,*) '! ',dble(NCHUNKS)*dble(NPROC)*dble(sum(NGLOB)) - subtract_central_cube_points
 ! there are 3 DOFs in solid regions, but only 1 in fluid outer core
   write(IOUT,*) '! approximate total number of degrees of freedom in entire mesh = '
-  write(IOUT,*) '! ',dble(NCHUNKS)*dble(NPROC)*(3.d0*(dble(sum(nglob))) &
-    - 2.d0*dble(nglob(IREGION_OUTER_CORE))) &
+  write(IOUT,*) '! ',dble(NCHUNKS)*dble(NPROC)*(3.d0*(dble(sum(NGLOB))) &
+    - 2.d0*dble(NGLOB(IREGION_OUTER_CORE))) &
     - 3.d0*subtract_central_cube_points
   write(IOUT,*) '!'
 
@@ -306,9 +309,9 @@
   write(IOUT,*) 'integer, parameter :: NSPEC_OUTER_CORE = ',NSPEC(IREGION_OUTER_CORE)
   write(IOUT,*) 'integer, parameter :: NSPEC_INNER_CORE = ',NSPEC(IREGION_INNER_CORE)
   write(IOUT,*)
-  write(IOUT,*) 'integer, parameter :: NGLOB_CRUST_MANTLE = ',nglob(IREGION_CRUST_MANTLE)
-  write(IOUT,*) 'integer, parameter :: NGLOB_OUTER_CORE = ',nglob(IREGION_OUTER_CORE)
-  write(IOUT,*) 'integer, parameter :: NGLOB_INNER_CORE = ',nglob(IREGION_INNER_CORE)
+  write(IOUT,*) 'integer, parameter :: NGLOB_CRUST_MANTLE = ',NGLOB(IREGION_CRUST_MANTLE)
+  write(IOUT,*) 'integer, parameter :: NGLOB_OUTER_CORE = ',NGLOB(IREGION_OUTER_CORE)
+  write(IOUT,*) 'integer, parameter :: NGLOB_INNER_CORE = ',NGLOB(IREGION_INNER_CORE)
   write(IOUT,*)
 
   write(IOUT,*) 'integer, parameter :: NSPECMAX_ANISO_IC = ',NSPECMAX_ANISO_IC
@@ -580,6 +583,46 @@
   endif
   write(IOUT,*)
 
+  ! in the case of Stacey boundary conditions, add C*delta/2 contribution to the mass matrix
+  ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
+  ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
+  !
+  ! if absorbing_conditions are not set or if NCHUNKS=6, only one mass matrix is needed
+  ! for the sake of performance, only "rmassz" array will be filled and "rmassx" & "rmassy" will be obsolete
+
+  NGLOB_XY_CM = 1
+  NGLOB_XY_IC = 1
+  NGLOB_XY_CM_BACKWARD = 1
+  NGLOB_XY_IC_BACKWARD = 1
+
+  if(NCHUNKS /= 6 .and. ABSORBING_CONDITIONS .and. .not. USE_LDDRK) then
+     NGLOB_XY_CM = NGLOB(IREGION_CRUST_MANTLE)
+  else
+     NGLOB_XY_CM = 1
+  endif
+
+  if(SIMULATION_TYPE /= 3  .and. .not. USE_LDDRK .and. EXACT_MASS_MATRIX_FOR_ROTATION) then
+    if(ROTATION) then
+      NGLOB_XY_CM = NGLOB(IREGION_CRUST_MANTLE)
+      NGLOB_XY_IC = NGLOB(IREGION_INNER_CORE)
+    endif
+  endif
+
+  if(SIMULATION_TYPE == 3  .and. .not. USE_LDDRK .and. EXACT_MASS_MATRIX_FOR_ROTATION) then
+    if(ROTATION) then
+      NGLOB_XY_CM = NGLOB(IREGION_CRUST_MANTLE)
+      NGLOB_XY_IC = NGLOB(IREGION_INNER_CORE)
+      NGLOB_XY_CM_BACKWARD = NGLOB(IREGION_CRUST_MANTLE)
+      NGLOB_XY_IC_BACKWARD = NGLOB(IREGION_INNER_CORE)
+    endif
+  endif
+
+  write(IOUT,*) 'integer, parameter :: NGLOB_XY_CM = ',NGLOB_XY_CM
+  write(IOUT,*) 'integer, parameter :: NGLOB_XY_IC = ',NGLOB_XY_IC
+  write(IOUT,*) 'integer, parameter :: NGLOB_XY_CM_BACKWARD = ',NGLOB_XY_CM_BACKWARD
+  write(IOUT,*) 'integer, parameter :: NGLOB_XY_IC_BACKWARD = ',NGLOB_XY_IC_BACKWARD
+  write(IOUT,*)
+
 !! DK DK Jul 2013: we need that for the part1_*.f90 and part2_*.f90 include files, which some compilers
 !! DK DK Jul 2013: refuse to preprocess even if we rename them *.F90
 #ifdef FORCE_VECTORIZATION

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/prepare_timerun.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/prepare_timerun.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/prepare_timerun.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -44,12 +44,12 @@
                       iproc_master_corners,iproc_worker1_corners,iproc_worker2_corners, &
                       buffer_send_faces_scalar,buffer_received_faces_scalar, &
                       buffer_send_chunkcorn_scalar,buffer_recv_chunkcorn_scalar, &
-                      NUMMSGS_FACES,NUM_MSG_TYPES,NCORNERSCHUNKS,NGLOB_XY_CM,ABSORBING_CONDITIONS, &
+                      NUMMSGS_FACES,NUM_MSG_TYPES,NCORNERSCHUNKS,ABSORBING_CONDITIONS, &
                       NGLOB1D_RADIAL,NGLOB2DMAX_XMIN_XMAX,NGLOB2DMAX_YMIN_YMAX,npoin2D_max_all_CM_IC, &
-                      SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK,NGLOB_XY_CM_BACKWARD,&
+                      SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK,&
                       b_rmassx_crust_mantle,b_rmassy_crust_mantle,&
-                      NGLOB_XY_IC,rmassx_inner_core,rmassy_inner_core,&
-                      NGLOB_XY_IC_BACKWARD,b_rmassx_inner_core,b_rmassy_inner_core)
+                      rmassx_inner_core,rmassy_inner_core,&
+                      b_rmassx_inner_core,b_rmassy_inner_core)
 
   use mpi
   implicit none
@@ -58,7 +58,7 @@
   include "OUTPUT_FILES/values_from_mesher.h"
 
   integer myrank,npoin2D_max_all_CM_IC
-  integer SIMULATION_TYPE,NGLOB_XY_CM,NGLOB_XY_CM_BACKWARD,NGLOB_XY_IC,NGLOB_XY_IC_BACKWARD
+  integer SIMULATION_TYPE
 
   logical ABSORBING_CONDITIONS,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK
 

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_arrays_solver.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_arrays_solver.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_arrays_solver.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -174,7 +174,7 @@
 
   ! mass matrices
   !
-  ! in the case of stacey boundary conditions, add C*deltat/2 contribution to the mass matrix
+  ! in the case of Stacey boundary conditions, add C*deltat/2 contribution to the mass matrix
   ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
   ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
   !

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_mesh_databases.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_mesh_databases.f90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/read_mesh_databases.f90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -1,3 +1,4 @@
+
 !=====================================================================
 !
 !          S p e c f e m 3 D  G l o b e  V e r s i o n  5 . 1
@@ -59,11 +60,11 @@
             c33store_inner_core,c44store_inner_core, &
             ibool_inner_core,idoubling_inner_core,ispec_is_tiso_inner_core, &
             is_on_a_slice_edge_inner_core,rmass_inner_core, &
-            ABSORBING_CONDITIONS,LOCAL_PATH,NGLOB_XY_CM,&
-            SIMULATION_TYPE,NGLOB_XY_CM_BACKWARD,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK, &
+            ABSORBING_CONDITIONS,LOCAL_PATH,&
+            SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK, &
             b_rmassx_crust_mantle,b_rmassy_crust_mantle,&
-            NGLOB_XY_IC,rmassx_inner_core,rmassy_inner_core,&
-            NGLOB_XY_IC_BACKWARD,b_rmassx_inner_core,b_rmassy_inner_core)
+            rmassx_inner_core,rmassy_inner_core,&
+            b_rmassx_inner_core,b_rmassy_inner_core)
 
   implicit none
 
@@ -106,13 +107,13 @@
 
   ! mass matrices
   !
-  ! in the case of stacey boundary conditions, add C*delta/2 contribution to the mass matrix
+  ! in the case of Stacey boundary conditions, add C*delta/2 contribution to the mass matrix
   ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
   ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
   !
   ! if absorbing_conditions are not set or if NCHUNKS=6, only one mass matrix is needed
   ! for the sake of performance, only "rmassz" array will be filled and "rmassx" & "rmassy" will be obsolete
-  integer :: NGLOB_DUMMY,NGLOB_XY_CM,NGLOB_XY_CM_BACKWARD
+  integer :: NGLOB_DUMMY
   logical :: EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK
   real(kind=CUSTOM_REAL), dimension(NGLOB_XY_CM) :: rmassx_crust_mantle
   real(kind=CUSTOM_REAL), dimension(NGLOB_XY_CM) :: rmassy_crust_mantle
@@ -154,7 +155,6 @@
   integer, dimension(NSPEC_INNER_CORE) :: idoubling_inner_core
   logical, dimension(NSPEC_INNER_CORE) :: ispec_is_tiso_inner_core
 
-  integer :: NGLOB_XY_IC,NGLOB_XY_IC_BACKWARD
   real(kind=CUSTOM_REAL), dimension(NGLOB_XY_IC) :: rmassx_inner_core
   real(kind=CUSTOM_REAL), dimension(NGLOB_XY_IC) :: rmassy_inner_core
   real(kind=CUSTOM_REAL), dimension(NGLOB_XY_IC_BACKWARD) :: b_rmassx_inner_core

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/specfem3D.F90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/specfem3D.F90	2013-07-16 03:23:53 UTC (rev 22624)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/src/specfem3D/specfem3D.F90	2013-07-16 14:15:25 UTC (rev 22625)
@@ -549,7 +549,7 @@
 
 ! mass matrices
 !
-! in the case of stacey boundary conditions, add C*delta/2 contribution to the mass matrix
+! in the case of Stacey boundary conditions, add C*delta/2 contribution to the mass matrix
 ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
 ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
 !
@@ -569,8 +569,6 @@
   real(kind=CUSTOM_REAL), dimension(NGLOB_CRUST_MANTLE) :: b_rmassz_crust_mantle
   equivalence(rmassz_crust_mantle,b_rmassz_crust_mantle)
 
-  integer :: NGLOB_XY_CM,NGLOB_XY_CM_BACKWARD
-
 ! displacement, velocity, acceleration
   real(kind=CUSTOM_REAL), dimension(NDIM,NGLOB_CRUST_MANTLE) :: &
      displ_crust_mantle,veloc_crust_mantle,accel_crust_mantle
@@ -630,7 +628,6 @@
   real(kind=CUSTOM_REAL), dimension(:), allocatable :: b_rmassy_inner_core
   real(kind=CUSTOM_REAL), dimension(NGLOB_INNER_CORE) :: rmass_inner_core
   real(kind=CUSTOM_REAL), dimension(NGLOB_INNER_CORE) :: b_rmass_inner_core
-  integer :: NGLOB_XY_IC,NGLOB_XY_IC_BACKWARD
   equivalence(rmass_inner_core,b_rmass_inner_core)
 
 ! displacement, velocity, acceleration
@@ -1164,41 +1161,6 @@
 #endif
 
   ! allocates mass matrices in this slice (will be fully assembled in the solver)
-  !
-  ! in the case of stacey boundary conditions, add C*delta/2 contribution to the mass matrix
-  ! on the Stacey edges for the crust_mantle and outer_core regions but not for the inner_core region
-  ! thus the mass matrix must be replaced by three mass matrices including the "C" damping matrix
-  !
-  ! if absorbing_conditions are not set or if NCHUNKS=6, only one mass matrix is needed
-  ! for the sake of performance, only "rmassz" array will be filled and "rmassx" & "rmassy" will be obsolete
-
-  NGLOB_XY_CM = 1
-  NGLOB_XY_IC = 1
-  NGLOB_XY_CM_BACKWARD = 1
-  NGLOB_XY_IC_BACKWARD = 1
-
-  if(NCHUNKS_VAL /= 6 .and. ABSORBING_CONDITIONS .and. (.not. USE_LDDRK)) then
-     NGLOB_XY_CM = NGLOB_CRUST_MANTLE
-  else
-     NGLOB_XY_CM = 1
-  endif
-
-  if(SIMULATION_TYPE /=3  .and. (.not. USE_LDDRK) .and. EXACT_MASS_MATRIX_FOR_ROTATION)then
-    if(ROTATION_VAL)then
-      NGLOB_XY_CM = NGLOB_CRUST_MANTLE
-      NGLOB_XY_IC = NGLOB_INNER_CORE
-    endif
-  endif
-
-  if(SIMULATION_TYPE ==3  .and. (.not. USE_LDDRK) .and. EXACT_MASS_MATRIX_FOR_ROTATION )then
-    if(ROTATION_VAL)then
-      NGLOB_XY_CM = NGLOB_CRUST_MANTLE
-      NGLOB_XY_IC = NGLOB_INNER_CORE
-      NGLOB_XY_CM_BACKWARD = NGLOB_CRUST_MANTLE
-      NGLOB_XY_IC_BACKWARD = NGLOB_INNER_CORE
-    endif
-  endif
-
   allocate(rmassx_crust_mantle(NGLOB_XY_CM),stat=ier)
   if( ier /= 0 ) call exit_MPI(myrank,'error allocating rmassx_crust_mantle')
   allocate(rmassy_crust_mantle(NGLOB_XY_CM),stat=ier)
@@ -1253,11 +1215,11 @@
               c33store_inner_core,c44store_inner_core, &
               ibool_inner_core,idoubling_inner_core,ispec_is_tiso_inner_core, &
               is_on_a_slice_edge_inner_core,rmass_inner_core, &
-              ABSORBING_CONDITIONS,LOCAL_PATH,NGLOB_XY_CM,&
-              SIMULATION_TYPE,NGLOB_XY_CM_BACKWARD,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK, &
+              ABSORBING_CONDITIONS,LOCAL_PATH,&
+              SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK, &
               b_rmassx_crust_mantle,b_rmassy_crust_mantle,&
-              NGLOB_XY_IC,rmassx_inner_core,rmassy_inner_core,&
-              NGLOB_XY_IC_BACKWARD,b_rmassx_inner_core,b_rmassy_inner_core)
+              rmassx_inner_core,rmassy_inner_core,&
+              b_rmassx_inner_core,b_rmassy_inner_core)
 
   ! read 2-D addressing for summation between slices with MPI
   call read_mesh_databases_addressing(myrank, &
@@ -1777,12 +1739,12 @@
                       iproc_master_corners,iproc_worker1_corners,iproc_worker2_corners, &
                       buffer_send_faces,buffer_received_faces, &
                       buffer_send_chunkcorn_scalar,buffer_recv_chunkcorn_scalar, &
-                      NUMMSGS_FACES,NUM_MSG_TYPES,NCORNERSCHUNKS,NGLOB_XY_CM,ABSORBING_CONDITIONS, &
+                      NUMMSGS_FACES,NUM_MSG_TYPES,NCORNERSCHUNKS,ABSORBING_CONDITIONS, &
                       NGLOB1D_RADIAL,NGLOB2DMAX_XMIN_XMAX,NGLOB2DMAX_YMIN_YMAX,npoin2D_max_all_CM_IC,&
-                      SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK,NGLOB_XY_CM_BACKWARD,&
+                      SIMULATION_TYPE,EXACT_MASS_MATRIX_FOR_ROTATION,USE_LDDRK,&
                       b_rmassx_crust_mantle,b_rmassy_crust_mantle,&
-                      NGLOB_XY_IC,rmassx_inner_core,rmassy_inner_core,&
-                      NGLOB_XY_IC_BACKWARD,b_rmassx_inner_core,b_rmassy_inner_core)
+                      rmassx_inner_core,rmassy_inner_core,&
+                      b_rmassx_inner_core,b_rmassy_inner_core)
 
   ! mass matrix including central cube
   if(INCLUDE_CENTRAL_CUBE) then



More information about the CIG-COMMITS mailing list