[cig-commits] r18805 - in seismo/2D/SPECFEM2D/trunk: . DATA EXAMPLES EXAMPLES/noise_examples src/meshfem2D src/specfem2D
rmodrak at geodynamics.org
rmodrak at geodynamics.org
Thu Jul 28 13:22:28 PDT 2011
Author: rmodrak
Date: 2011-07-28 13:22:28 -0700 (Thu, 28 Jul 2011)
New Revision: 18805
Added:
seismo/2D/SPECFEM2D/trunk/EXAMPLES/noise_examples/
seismo/2D/SPECFEM2D/trunk/EXAMPLES/noise_examples/uniform.dat
seismo/2D/SPECFEM2D/trunk/NOISE_TOMOGRAPHY/
Modified:
seismo/2D/SPECFEM2D/trunk/DATA/Par_file.in
seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_1
seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_2
seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_3
seismo/2D/SPECFEM2D/trunk/src/meshfem2D/read_parameter_file.F90
seismo/2D/SPECFEM2D/trunk/src/meshfem2D/save_databases.f90
seismo/2D/SPECFEM2D/trunk/src/specfem2D/noise_tomography.f90
seismo/2D/SPECFEM2D/trunk/src/specfem2D/read_databases.f90
seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
Log:
adds NOISE_TOMOGRAPHY flag to Par_file
Modified: seismo/2D/SPECFEM2D/trunk/DATA/Par_file.in
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/Par_file.in 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/DATA/Par_file.in 2011-07-28 20:22:28 UTC (rev 18805)
@@ -3,6 +3,7 @@
# forward or adjoint simulation
SIMULATION_TYPE = 1 # 1 = forward, 2 = adjoint + kernels
+NOISE_TOMOGRAPHY = 0 # 0 = earthquake simulation, 1/2/3 = noise simulation
SAVE_FORWARD = .false. # save the last frame, needed for adjoint simulation
# parameters concerning partitioning
Modified: seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_1
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_1 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_1 2011-07-28 20:22:28 UTC (rev 18805)
@@ -3,6 +3,7 @@
# forward or adjoint simulation
SIMULATION_TYPE = 1 # 1 = forward, 2 = adjoint + kernels
+NOISE_TOMOGRAPHY = 1 # 0 = earthquake simulation, 1/2/3 = noise simulation
SAVE_FORWARD = .false. # save the last frame, needed for adjoint simulation
# parameters concerning partitioning
@@ -97,7 +98,7 @@
# PARAMETERS FOR INTERNAL MESHING
# file containing interfaces for internal mesh
-interfacesfile = ../EXAMPLES/noise_example/uniform.dat
+interfacesfile = ../EXAMPLES/noise_examples/uniform.dat
# geometry of the model (origin lower-left corner = 0,0) and mesh description
xmin = 0.d0 # abscissa of left side of the model
Modified: seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_2
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_2 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_2 2011-07-28 20:22:28 UTC (rev 18805)
@@ -3,6 +3,7 @@
# forward or adjoint simulation
SIMULATION_TYPE = 1 # 1 = forward, 2 = adjoint + kernels
+NOISE_TOMOGRAPHY = 2 # 0 = earthquake simulation, 1/2/3 = noise simulation
SAVE_FORWARD = .true. # save the last frame, needed for adjoint simulation
# parameters concerning partitioning
@@ -97,7 +98,7 @@
# PARAMETERS FOR INTERNAL MESHING
# file containing interfaces for internal mesh
-interfacesfile = ../EXAMPLES/noise_example/uniform.dat
+interfacesfile = ../EXAMPLES/noise_examples/uniform.dat
# geometry of the model (origin lower-left corner = 0,0) and mesh description
xmin = 0.d0 # abscissa of left side of the model
Modified: seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_3
===================================================================
--- seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_3 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/DATA/Par_file_noise_3 2011-07-28 20:22:28 UTC (rev 18805)
@@ -3,6 +3,7 @@
# forward or adjoint simulation
SIMULATION_TYPE = 2 # 1 = forward, 2 = adjoint + kernels
+NOISE_TOMOGRAPHY = 3 # 0 = earthquake simulation, 1/2/3 = noise simulation
SAVE_FORWARD = .false. # save the last frame, needed for adjoint simulation
# parameters concerning partitioning
Added: seismo/2D/SPECFEM2D/trunk/EXAMPLES/noise_examples/uniform.dat
===================================================================
--- seismo/2D/SPECFEM2D/trunk/EXAMPLES/noise_examples/uniform.dat (rev 0)
+++ seismo/2D/SPECFEM2D/trunk/EXAMPLES/noise_examples/uniform.dat 2011-07-28 20:22:28 UTC (rev 18805)
@@ -0,0 +1,26 @@
+#
+# number of interfaces
+#
+ 2
+#
+# for each interface below, we give the number of points and then x,y for each point
+#
+#
+# interface number 1 (bottom of the mesh)
+#
+ 2
+ 0 0
+ 4000 0
+#
+# interface number 2
+#
+ 2
+ 0 3000
+ 4000 3000
+#
+# for each layer, we give the number of spectral elements in the vertical direction
+#
+#
+# layer number 1
+#
+ 60
Modified: seismo/2D/SPECFEM2D/trunk/src/meshfem2D/read_parameter_file.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/meshfem2D/read_parameter_file.F90 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/src/meshfem2D/read_parameter_file.F90 2011-07-28 20:22:28 UTC (rev 18805)
@@ -54,7 +54,7 @@
implicit none
character(len=100) :: interfacesfile,title
- integer :: SIMULATION_TYPE
+ integer :: SIMULATION_TYPE, NOISE_TOMOGRAPHY
logical :: SAVE_FORWARD,read_external_mesh
character(len=256) :: mesh_file, nodes_coords_file, materials_file, &
@@ -141,6 +141,10 @@
call read_value_integer_p(SIMULATION_TYPE, 'solver.SIMULATION_TYPE')
if(err_occurred() /= 0) stop 'error reading parameter 2 in Par_file'
+ !call read_value_integer(IIN,IGNORE_JUNK,NOISE_TOMOGRAPHY)
+ call read_value_integer_p(NOISE_TOMOGRAPHY, 'solver.NOISE_TOMOGRAPHY')
+ if(err_occurred() /= 0) stop 'error reading parameter NOISE_TOMOGRAPHY in Par_file'
+
!call read_value_logical(IIN,IGNORE_JUNK,SAVE_FORWARD)
call read_value_logical_p(SAVE_FORWARD, 'solver.SAVE_FORWARD')
if(err_occurred() /= 0) stop 'error reading parameter 3 in Par_file'
Modified: seismo/2D/SPECFEM2D/trunk/src/meshfem2D/save_databases.f90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/meshfem2D/save_databases.f90 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/src/meshfem2D/save_databases.f90 2011-07-28 20:22:28 UTC (rev 18805)
@@ -92,7 +92,7 @@
write(15,"(a100)") title
write(15,*) 'Type of simulation'
- write(15,*) SIMULATION_TYPE, SAVE_FORWARD
+ write(15,*) SIMULATION_TYPE, NOISE_TOMOGRAPHY, SAVE_FORWARD
call write_glob2loc_nodes_database(15, iproc, npgeo, 1)
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/noise_tomography.f90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/noise_tomography.f90 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/noise_tomography.f90 2011-07-28 20:22:28 UTC (rev 18805)
@@ -44,9 +44,9 @@
!NOISE TOMOGRAPHY TO DO LIST
!1. Replace ad hoc scaling in add_surface_movie_noise by expression involving Jacobian
-!2. Move NOISE_TOMOGRAPHY flag from source code to Par_file
-!3. Use separate STATIONS_ADJOINT file
-!4. Add test case (uniform model) under EXAMPLES
+!2. Use separate STATIONS_ADJOINT file
+!3. Add membrane surface wave test case under EXAMPLES
+!4. Add exploartion test case under EXAMPLES
!5. Update manual
! =============================================================================================================
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/read_databases.f90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/read_databases.f90 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/read_databases.f90 2011-07-28 20:22:28 UTC (rev 18805)
@@ -45,7 +45,7 @@
subroutine read_databases_init(myrank,ipass, &
- simulation_title,SIMULATION_TYPE,SAVE_FORWARD,npgeo, &
+ simulation_title,SIMULATION_TYPE,NOISE_TOMOGRAPHY,SAVE_FORWARD,npgeo, &
gnuplot,interpol,NTSTEP_BETWEEN_OUTPUT_INFO, &
output_postscript_snapshot,output_color_image,colors,numbers, &
meshvect,modelvect,boundvect,cutsnaps,subsamp,sizemax_arrows, &
@@ -62,7 +62,7 @@
integer :: myrank,ipass
character(len=60) simulation_title
- integer :: SIMULATION_TYPE,npgeo
+ integer :: SIMULATION_TYPE,NOISE_TOMOGRAPHY,npgeo
integer :: colors,numbers,subsamp,seismotype,imagetype
logical :: SAVE_FORWARD,gnuplot,interpol,output_postscript_snapshot, &
output_color_image
@@ -111,7 +111,7 @@
!---- read parameters from input file
read(IIN,"(a80)") datlin
- read(IIN,*) SIMULATION_TYPE, SAVE_FORWARD
+ read(IIN,*) SIMULATION_TYPE, NOISE_TOMOGRAPHY, SAVE_FORWARD
read(IIN,"(a80)") datlin
read(IIN,*) npgeo
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2011-07-28 17:10:16 UTC (rev 18804)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2011-07-28 20:22:28 UTC (rev 18805)
@@ -808,26 +808,17 @@
! al., 2011, Noise Cross-Correlation Sensitivity Kernels, Geophysical Journal
! International"
-
- integer, parameter :: NOISE_TOMOGRAPHY = 0
- !setting this flag to a value other than 0 will result in a noise simulation
-
- !for NOISE_TOMOGRAPHY = 1
+ integer :: NOISE_TOMOGRAPHY
integer :: irec_master, ispec_noise
real(kind=CUSTOM_REAL) :: xi_noise, gamma_noise, angle_noise
real(kind=CUSTOM_REAL), dimension(:), allocatable :: time_function_noise
real(kind=CUSTOM_REAL), dimension(:,:,:,:), allocatable :: source_array_noise
-
- !for NOISE_TOMOGRAPHY = 2
real(kind=CUSTOM_REAL), dimension(:), allocatable :: mask_noise
!to avoid empty arrays depending on SH/P_SV, use separate arrays for x,y,z
real(kind=CUSTOM_REAL), dimension(:), allocatable :: &
surface_movie_x_noise, surface_movie_y_noise, surface_movie_z_noise
- !for NOISE_TOMOGRAPHY = 3
- !no additional declarations required for NOISE_TOMOGRAPHY = 3
-
!>RMODRAK
@@ -850,7 +841,7 @@
! starts reading in Database file
call read_databases_init(myrank,ipass, &
- simulation_title,SIMULATION_TYPE,SAVE_FORWARD,npgeo, &
+ simulation_title,SIMULATION_TYPE,NOISE_TOMOGRAPHY,SAVE_FORWARD,npgeo, &
gnuplot,interpol,NTSTEP_BETWEEN_OUTPUT_INFO, &
output_postscript_snapshot,output_color_image,colors,numbers, &
meshvect,modelvect,boundvect,cutsnaps,subsamp,sizemax_arrows, &
More information about the CIG-COMMITS
mailing list