[cig-commits] r15510 - in seismo/2D/SPECFEM2D/trunk: . DATA

cmorency at geodynamics.org cmorency at geodynamics.org
Mon Aug 3 10:26:40 PDT 2009


Author: cmorency
Date: 2009-08-03 10:26:40 -0700 (Mon, 03 Aug 2009)
New Revision: 15510

Modified:
   seismo/2D/SPECFEM2D/trunk/DATA/STATIONS
   seismo/2D/SPECFEM2D/trunk/specfem2D.F90
   seismo/2D/SPECFEM2D/trunk/write_seismograms.F90
Log:
Merging BIOT: modif write_seismograms.F90 to write acoustic potential in case of adjoint calculation


Modified: seismo/2D/SPECFEM2D/trunk/DATA/STATIONS
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/STATIONS	2009-08-03 17:14:54 UTC (rev 15509)
+++ seismo/2D/SPECFEM2D/trunk/DATA/STATIONS	2009-08-03 17:26:40 UTC (rev 15510)
@@ -1,11 +1,2 @@
-S0001    AA          300.0000000         2997.7298909       0.0         0.0
-S0002    AA          640.0000000         3008.0430011       0.0         0.0
-S0003    AA          980.0000000         3090.8224062       0.0         0.0
-S0004    AA         1320.0000000         3283.0303923       0.0         0.0
-S0005    AA         1660.0000000         3347.8768862       0.0         0.0
-S0006    AA         2000.0000000         3250.0000000       0.0         0.0
-S0007    AA         2340.0000000         3197.3138031       0.0         0.0
-S0008    AA         2680.0000000         3150.9619873       0.0         0.0
-S0009    AA         3020.0000000         3086.5939051       0.0         0.0
-S0010    AA         3360.0000000         3042.8523748       0.0         0.0
-S0011    AA         3700.0000000         3020.6886768       0.0         0.0
+S0001    AA         2000.0000000         2933.3300000       0.0         0.0
+S0002    AA         2000.0000000         1866.6700000       0.0         0.0

Modified: seismo/2D/SPECFEM2D/trunk/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/specfem2D.F90	2009-08-03 17:14:54 UTC (rev 15509)
+++ seismo/2D/SPECFEM2D/trunk/specfem2D.F90	2009-08-03 17:26:40 UTC (rev 15510)
@@ -6706,7 +6706,7 @@
 !----  save temporary or final seismograms
 ! suppress seismograms if we generate traces of the run for analysis with "ParaVer", because time consuming
   if(.not. GENERATE_PARAVER_TRACES) call write_seismograms(sisux,sisuz,siscurl,station_name,network_name,NSTEP, &
-        nrecloc,which_proc_receiver,nrec,myrank,deltat,seismotype,st_xval,t0, &
+        nrecloc,which_proc_receiver,nrec,myrank,deltat,seismotype,st_xval,t0(1), &
         NTSTEP_BETWEEN_OUTPUT_SEISMO,seismo_offset,seismo_current)
 
   seismo_offset = seismo_offset + seismo_current

Modified: seismo/2D/SPECFEM2D/trunk/write_seismograms.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/write_seismograms.F90	2009-08-03 17:14:54 UTC (rev 15509)
+++ seismo/2D/SPECFEM2D/trunk/write_seismograms.F90	2009-08-03 17:26:40 UTC (rev 15510)
@@ -99,7 +99,7 @@
     component = 'v'
   else if(seismotype == 3) then
     component = 'a'
-  else if(seismotype == 4) then
+  else if(seismotype == 4 .or. seismotype == 6) then
     component = 'p'
   else if(seismotype == 5) then
     component = 'c'
@@ -109,7 +109,7 @@
 
 
 ! only one seismogram if pressurs
-  if(seismotype == 4) then
+  if(seismotype == 4 .or. seismotype == 6) then
      number_of_components = 1
   else if(seismotype == 5) then
      number_of_components = NDIM+1
@@ -152,20 +152,20 @@
    if ( myrank == 0 ) then
 
 ! write the new files
-     if(seismotype == 4) then
+     if(seismotype == 4 .or. seismotype == 6) then
         open(unit=12,file='OUTPUT_FILES/pressure_file_single.bin',status='unknown',access='direct',recl=4)
      else
         open(unit=12,file='OUTPUT_FILES/Ux_file_single.bin',status='unknown',access='direct',recl=4)
      endif
 
-     if(seismotype == 4) then
+     if(seismotype == 4 .or. seismotype == 6) then
         open(unit=13,file='OUTPUT_FILES/pressure_file_double.bin',status='unknown',access='direct',recl=8)
      else
         open(unit=13,file='OUTPUT_FILES/Ux_file_double.bin',status='unknown',access='direct',recl=8)
      endif
 
 ! no Z component seismogram if pressure
-     if(seismotype /= 4) then
+     if(seismotype /= 4 .and. seismotype /= 6) then
         open(unit=14,file='OUTPUT_FILES/Uz_file_single.bin',status='unknown',access='direct',recl=4)
         open(unit=15,file='OUTPUT_FILES/Uz_file_double.bin',status='unknown',access='direct',recl=8)
 
@@ -229,7 +229,7 @@
            endif
 
            ! in case of pressure, use different abbreviation
-           if(seismotype == 4) chn = 'PRE'
+           if(seismotype == 4 .or. seismotype == 6) chn = 'PRE'
 
            ! create the name of the seismogram file for each slice
            ! file name includes the name of the station, the network and the component
@@ -275,7 +275,7 @@
         do isample = 1, seismo_current
            write(12,rec=(irec-1)*NSTEP+seismo_offset+isample) sngl(buffer_binary(isample,1))
            write(13,rec=(irec-1)*NSTEP+seismo_offset+isample) buffer_binary(isample,1)
-        if ( seismotype /= 4 ) then
+        if ( seismotype /= 4 .and. seismotype /= 6) then
            write(14,rec=(irec-1)*NSTEP+seismo_offset+isample) sngl(buffer_binary(isample,2))
            write(15,rec=(irec-1)*NSTEP+seismo_offset+isample) buffer_binary(isample,2)
         end if
@@ -306,7 +306,7 @@
 
   close(12)
   close(13)
-  if ( seismotype /= 4 ) then
+  if ( seismotype /= 4 .and. seismotype /= 6) then
      close(14)
      close(15)
   end if



More information about the CIG-COMMITS mailing list