[cig-commits] r11741 - seismo/3D/SPECFEM3D_GLOBE/trunk

dkomati1 at geodynamics.org dkomati1 at geodynamics.org
Thu Apr 3 04:35:02 PDT 2008


Author: dkomati1
Date: 2008-04-03 04:35:00 -0700 (Thu, 03 Apr 2008)
New Revision: 11741

Modified:
   seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_crust_mantle.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_inner_core.f90
   seismo/3D/SPECFEM3D_GLOBE/trunk/specfem3D.f90
Log:
- fixed the iglob bug for radius_cr = xstore(iglob)
- renamed SAVE_STRAIN to COMPUTE_AND_STORE_STRAIN


Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_crust_mantle.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_crust_mantle.f90	2008-04-03 02:02:25 UTC (rev 11740)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_crust_mantle.f90	2008-04-03 11:35:00 UTC (rev 11741)
@@ -36,7 +36,7 @@
           c23store,c24store,c25store,c26store,c33store,c34store,c35store, &
           c36store,c44store,c45store,c46store,c55store,c56store,c66store, &
           ibool,idoubling,R_memory,epsilondev,epsilon_trace_over_3,one_minus_sum_beta, &
-          alphaval,betaval,gammaval,factor_common,vx,vy,vz,vnspec,SAVE_STRAIN, AM_V)
+          alphaval,betaval,gammaval,factor_common,vx,vy,vz,vnspec,COMPUTE_AND_STORE_STRAIN, AM_V)
 
   implicit none
 
@@ -69,7 +69,7 @@
 ! attenuation_model_variables
 
 ! for forward or backward simulations
-  logical SAVE_STRAIN
+  logical COMPUTE_AND_STORE_STRAIN
 
 ! array with the local to global mapping per slice
   integer, dimension(NSPEC_CRUST_MANTLE) :: idoubling
@@ -269,7 +269,7 @@
           duzdyl_plus_duydzl = duzdyl + duydzl
 
 ! compute deviatoric strain
- if (SAVE_STRAIN) then
+ if (COMPUTE_AND_STORE_STRAIN) then
     if(NSPEC_CRUST_MANTLE_STRAIN_ONLY == 1) then
       ispec_strain = 1
     else
@@ -288,7 +288,7 @@
     if(ATTENUATION_3D_VAL) then
       one_minus_sum_beta_use = one_minus_sum_beta(i,j,k,ispec)
     else
-      radius_cr = xstore(iglob)
+      radius_cr = xstore(ibool(i,j,k,ispec))
       call get_attenuation_index(idoubling(ispec), dble(radius_cr), iregion_selected, .FALSE., AM_V)
       one_minus_sum_beta_use = one_minus_sum_beta(1,1,1,iregion_selected)
     endif
@@ -837,7 +837,7 @@
   endif
 
 ! save deviatoric strain for Runge-Kutta scheme
-  if(SAVE_STRAIN) epsilondev(:,:,:,:,ispec) = epsilondev_loc(:,:,:,:)
+  if(COMPUTE_AND_STORE_STRAIN) epsilondev(:,:,:,:,ispec) = epsilondev_loc(:,:,:,:)
 
   enddo   ! spectral element loop
 

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_inner_core.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_inner_core.f90	2008-04-03 02:02:25 UTC (rev 11740)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/compute_forces_inner_core.f90	2008-04-03 11:35:00 UTC (rev 11741)
@@ -34,7 +34,7 @@
           kappavstore,muvstore,ibool,idoubling, &
           c11store,c33store,c12store,c13store,c44store,R_memory,epsilondev,epsilon_trace_over_3,&
           one_minus_sum_beta,alphaval,betaval,gammaval,factor_common, &
-          vx,vy,vz,vnspec,SAVE_STRAIN, AM_V)
+          vx,vy,vz,vnspec,COMPUTE_AND_STORE_STRAIN, AM_V)
 
   implicit none
 
@@ -67,7 +67,7 @@
 ! attenuation_model_variables
 
 ! for forward or backward simulations
-  logical SAVE_STRAIN
+  logical COMPUTE_AND_STORE_STRAIN
 
 ! displacement and acceleration
   real(kind=CUSTOM_REAL), dimension(NDIM,NGLOB_INNER_CORE) :: displ,accel
@@ -247,7 +247,7 @@
           duzdyl_plus_duydzl = duzdyl + duydzl
 
 ! compute deviatoric strain
-  if (SAVE_STRAIN) then
+  if (COMPUTE_AND_STORE_STRAIN) then
     if(NSPEC_INNER_CORE_STRAIN_ONLY == 1) then
       ispec_strain = 1
     else
@@ -265,8 +265,7 @@
      if(ATTENUATION_3D_VAL) then
         minus_sum_beta =  one_minus_sum_beta(i,j,k,ispec) - 1.0
      else
-        iglob     = ibool(i,j,k,ispec)
-        radius_cr = xstore(iglob)
+        radius_cr = xstore(ibool(i,j,k,ispec))
         call get_attenuation_index(idoubling(ispec), dble(radius_cr), iregion_selected, .TRUE., AM_V)
         minus_sum_beta =  one_minus_sum_beta(1,1,1,iregion_selected) - 1.0
      endif ! ATTENUATION_3D_VAL
@@ -584,7 +583,7 @@
 
      endif
 
-     if (SAVE_STRAIN) then
+     if (COMPUTE_AND_STORE_STRAIN) then
 ! save deviatoric strain for Runge-Kutta scheme
        epsilondev(:,:,:,:,ispec) = epsilondev_loc(:,:,:,:)
      endif

Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/specfem3D.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/specfem3D.f90	2008-04-03 02:02:25 UTC (rev 11740)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/specfem3D.f90	2008-04-03 11:35:00 UTC (rev 11741)
@@ -731,7 +731,7 @@
 
   integer, external :: err_occurred
 
-  logical SAVE_STRAIN
+  logical COMPUTE_AND_STORE_STRAIN
 
 ! for SAC headers for seismograms
   integer NSOURCES_SAC,yr_SAC,jda_SAC,ho_SAC,mi_SAC
@@ -1075,9 +1075,9 @@
      call exit_MPI(myrank, 'anisotropic model is not implemented for kernel simulations yet')
 
   if (ATTENUATION_VAL .or. SIMULATION_TYPE /= 1 .or. SAVE_FORWARD .or. (MOVIE_VOLUME .and. SIMULATION_TYPE /= 3)) then
-    SAVE_STRAIN = .true.
+    COMPUTE_AND_STORE_STRAIN = .true.
   else
-    SAVE_STRAIN = .false.
+    COMPUTE_AND_STORE_STRAIN = .false.
   endif
 
 ! get the base pathname for output files
@@ -2684,7 +2684,7 @@
      endif
   endif
 
-  if (SAVE_STRAIN) then
+  if (COMPUTE_AND_STORE_STRAIN) then
     eps_trace_over_3_crust_mantle(:,:,:,:) = 0._CUSTOM_REAL
     epsilondev_crust_mantle(:,:,:,:,:) = 0._CUSTOM_REAL
     eps_trace_over_3_inner_core(:,:,:,:) = 0._CUSTOM_REAL
@@ -2913,7 +2913,7 @@
 
     endif
 
-    if (SAVE_STRAIN) then
+    if (COMPUTE_AND_STORE_STRAIN) then
       Strain_norm = maxval(abs(eps_trace_over_3_crust_mantle))
       strain2_norm= maxval(abs(epsilondev_crust_mantle))
       call MPI_REDUCE(Strain_norm,Strain_norm_all,1,CUSTOM_MPI_TYPE,MPI_MAX,0, &
@@ -2936,7 +2936,7 @@
       write(IMAIN,*) 'Max norm displacement vector U in solid in all slices for back prop.(m) = ',b_Usolidnorm_all
       write(IMAIN,*) 'Max non-dimensional potential Ufluid in fluid in all slices for back prop.= ',b_Ufluidnorm_all
       endif
-      if(SAVE_STRAIN) then
+      if(COMPUTE_AND_STORE_STRAIN) then
       write(IMAIN,*) 'Max of strain, eps_trace_over_3_crust_mantle =',Strain_norm_all
       write(IMAIN,*) 'Max of strain, epsilondev_crust_mantle  =',Strain2_norm_all
       endif
@@ -3563,7 +3563,7 @@
           R_memory_crust_mantle,epsilondev_crust_mantle,eps_trace_over_3_crust_mantle,one_minus_sum_beta_crust_mantle, &
           alphaval,betaval,gammaval,factor_common_crust_mantle, &
           size(factor_common_crust_mantle,2), size(factor_common_crust_mantle,3), &
-          size(factor_common_crust_mantle,4), size(factor_common_crust_mantle,5),SAVE_STRAIN,AM_V)
+          size(factor_common_crust_mantle,4), size(factor_common_crust_mantle,5),COMPUTE_AND_STORE_STRAIN,AM_V)
 
   if (SIMULATION_TYPE == 3) then
 ! for anisotropy and gravity, x y and z contain r theta and phi
@@ -3589,7 +3589,7 @@
           b_R_memory_crust_mantle,b_epsilondev_crust_mantle,b_eps_trace_over_3_crust_mantle,one_minus_sum_beta_crust_mantle, &
           b_alphaval,b_betaval,b_gammaval,factor_common_crust_mantle, &
           size(factor_common_crust_mantle,2), size(factor_common_crust_mantle,3), &
-          size(factor_common_crust_mantle,4), size(factor_common_crust_mantle,5),SAVE_STRAIN,AM_V)
+          size(factor_common_crust_mantle,4), size(factor_common_crust_mantle,5),COMPUTE_AND_STORE_STRAIN,AM_V)
   endif
 
 
@@ -3838,7 +3838,7 @@
           alphaval,betaval,gammaval, &
           factor_common_inner_core, &
           size(factor_common_inner_core,2), size(factor_common_inner_core,3), &
-          size(factor_common_inner_core,4), size(factor_common_inner_core,5),SAVE_STRAIN,AM_V)
+          size(factor_common_inner_core,4), size(factor_common_inner_core,5),COMPUTE_AND_STORE_STRAIN,AM_V)
 
   if (SIMULATION_TYPE == 3) then
   call compute_forces_inner_core(minus_gravity_table,density_table,minus_deriv_gravity_table, &
@@ -3856,7 +3856,7 @@
           b_alphaval,b_betaval,b_gammaval, &
           factor_common_inner_core, &
           size(factor_common_inner_core,2), size(factor_common_inner_core,3), &
-          size(factor_common_inner_core,4), size(factor_common_inner_core,5),SAVE_STRAIN,AM_V)
+          size(factor_common_inner_core,4), size(factor_common_inner_core,5),COMPUTE_AND_STORE_STRAIN,AM_V)
   endif
 
 ! add the sources



More information about the cig-commits mailing list