[cig-commits] r20315 - in seismo/2D/SPECFEM2D/trunk: DATA src/specfem2D
dkomati1 at geodynamics.org
dkomati1 at geodynamics.org
Tue Jun 5 04:43:02 PDT 2012
Author: dkomati1
Date: 2012-06-05 04:43:02 -0700 (Tue, 05 Jun 2012)
New Revision: 20315
Modified:
seismo/2D/SPECFEM2D/trunk/DATA/Par_file
seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
Log:
flags NSTEP_BETWEEN_OUTPUT_SEISMOS, NSTEP_BETWEEN_OUTPUT_INFO, NSTEP_BETWEEN_OUTPUT_IMAGES and NSTEP_BETWEEN_OUTPUT_WAVE_DUMPS are now correctly implemented
Modified: seismo/2D/SPECFEM2D/trunk/DATA/Par_file
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/Par_file 2012-06-05 10:55:52 UTC (rev 20314)
+++ seismo/2D/SPECFEM2D/trunk/DATA/Par_file 2012-06-05 11:43:02 UTC (rev 20315)
@@ -71,7 +71,7 @@
USE_SNAPSHOT_NUMBER_IN_FILENAME = .false. # use snapshot number in the file name of JPEG color snapshots instead of the time step (for instance to create movies in an easier way later)
#### for PostScript snapshots ####
output_postscript_snapshot = .true. # output Postscript snapshot of the results every NSTEP_BETWEEN_OUTPUT_IMAGES time steps or not
-imagetype_postscript = 1 # display 1=displ vector 2=veloc vector 3=accel vector 4=pressure; small arrows are displayed for vectors
+imagetype_postscript = 1 # display 1=displ vector 2=veloc vector 3=accel vector; small arrows are displayed for the vectors
meshvect = .true. # display mesh on PostScript plots or not
modelvect = .false. # display velocity model on PostScript plots or not
boundvect = .true. # display boundary conditions on PostScript plots or not
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2012-06-05 10:55:52 UTC (rev 20314)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2012-06-05 11:43:02 UTC (rev 20315)
@@ -915,7 +915,7 @@
surface_movie_x_noise, surface_movie_y_noise, surface_movie_z_noise
! For writing noise wavefields
- logical :: output_wavefields_noise = .true.
+ logical :: output_wavefields_noise = .true. ! this is output only in the case of noise tomography
logical :: ex, od
integer :: noise_output_ncol
real(kind=CUSTOM_REAL), dimension(:,:), allocatable :: noise_output_array
@@ -7066,6 +7066,7 @@
!---- display time step and max of norm of displacement
if(mod(it,NSTEP_BETWEEN_OUTPUT_INFO) == 0 .or. it == 5 .or. it == NSTEP) then
+
call check_stability(myrank,time,it,NSTEP,NOISE_TOMOGRAPHY, &
nglob_acoustic,nglob_elastic,nglob_poroelastic, &
any_elastic_glob,any_elastic,displ_elastic, &
@@ -7073,6 +7074,12 @@
displs_poroelastic,displw_poroelastic, &
any_acoustic_glob,any_acoustic,potential_acoustic, &
timestamp_seconds_start)
+
+#ifdef USE_MPI
+! add a barrier if we generate traces of the run for analysis with "ParaVer"
+ if(GENERATE_PARAVER_TRACES) call MPI_BARRIER(MPI_COMM_WORLD,ier)
+#endif
+
endif
!---- loop on all the receivers to compute and store the seismograms
@@ -7550,7 +7557,7 @@
!
!---- display results at given time steps
!
- if(mod(it,NSTEP_BETWEEN_OUTPUT_INFO) == 0 .or. it == 5 .or. it == NSTEP) then
+ if(mod(it,NSTEP_BETWEEN_OUTPUT_IMAGES) == 0 .or. it == 5 .or. it == NSTEP) then
!
! kernels output files
@@ -7634,7 +7641,7 @@
if ( NOISE_TOMOGRAPHY == 3 .and. output_wavefields_noise ) then
- !load ensemble foward source
+ !load ensemble forward source
inquire(unit=500,exist=ex,opened=od)
if (.not. od) &
open(unit=500,file='OUTPUT_FILES/NOISE_TOMOGRAPHY/eta',access='direct', &
@@ -7945,12 +7952,14 @@
endif
endif
+ endif ! of display images at a given time step
!----------------------------------------------
! write the full (local) wavefield to file as three components (Uy = 0 for PSV; Ux,Uz = 0 for SH)
! note 1: for SH case, this requires output_color_image = .true. in order to have vector_field_display
! note 2: for MPI, it would be more convenient to output a single file rather than one for each myrank
+ if(mod(it,NSTEP_BETWEEN_OUTPUT_WAVE_DUMPS) == 0 .or. it == NSTEP) then
if (output_wavefield_dumps) then
write(wavefield_file,"('OUTPUT_FILES/wavefield',i7.7,'_',i2.2,'_',i3.3,'.txt')") it,SIMULATION_TYPE,myrank
open(unit=27,file=wavefield_file,status='unknown')
@@ -7959,6 +7968,7 @@
do i = 1,NGLLX
!!!!!!!!!! DK DK save NGLOB on the first line maybe
iglob = ibool(i,j,ispec)
+!!!!!!!!!! DK DK save the grid separately and once only
write(27,'(5e16.6)') coord(1,iglob), coord(2,iglob), &
sngl(vector_field_display(1,iglob)), &
sngl(vector_field_display(2,iglob)), &
@@ -7968,9 +7978,11 @@
enddo
close(27)
endif
+ endif ! of display wavefield dumps at a given time step
!---- save temporary or final seismograms
! suppress seismograms if we generate traces of the run for analysis with "ParaVer", because time consuming
+ if(mod(it,NSTEP_BETWEEN_OUTPUT_SEISMOS) == 0 .or. it == NSTEP) then
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, &
@@ -7980,13 +7992,8 @@
seismo_offset = seismo_offset + seismo_current
seismo_current = 0
- endif ! display results for specified time step
+ endif ! of display images at a given time step
-#ifdef USE_MPI
-! add a barrier if we generate traces of the run for analysis with "ParaVer"
- if(GENERATE_PARAVER_TRACES) call MPI_BARRIER(MPI_COMM_WORLD,ier)
-#endif
-
enddo ! end of the main time loop
! *********************************************************
More information about the CIG-COMMITS
mailing list