diff --git a/DATA/Par_file b/DATA/Par_file index f0be31694..64783dfe1 100644 --- a/DATA/Par_file +++ b/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -336,6 +339,9 @@ nbregions = 5 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/Rayleigh_wave_no_crack/DATA/Par_file b/EXAMPLES/applications/Rayleigh_wave_no_crack/DATA/Par_file index 490bff77b..3ac37d0b3 100644 --- a/EXAMPLES/applications/Rayleigh_wave_no_crack/DATA/Par_file +++ b/EXAMPLES/applications/Rayleigh_wave_no_crack/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/Rayleigh_wave_no_crack_simpler_way_to_generate_the_wave/DATA/Par_file b/EXAMPLES/applications/Rayleigh_wave_no_crack_simpler_way_to_generate_the_wave/DATA/Par_file index ba0a7fd2d..54209d75a 100644 --- a/EXAMPLES/applications/Rayleigh_wave_no_crack_simpler_way_to_generate_the_wave/DATA/Par_file +++ b/EXAMPLES/applications/Rayleigh_wave_no_crack_simpler_way_to_generate_the_wave/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/Rayleigh_wave_with_crack/DATA/Par_file b/EXAMPLES/applications/Rayleigh_wave_with_crack/DATA/Par_file index 12bd791a7..eb7acf01b 100644 --- a/EXAMPLES/applications/Rayleigh_wave_with_crack/DATA/Par_file +++ b/EXAMPLES/applications/Rayleigh_wave_with_crack/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file b/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file index 50a04c776..eb07e4526 100644 --- a/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file +++ b/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -325,6 +328,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file_homogeneous_with_attenuation b/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file_homogeneous_with_attenuation index 3ea5fae6c..d5670a24d 100644 --- a/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file_homogeneous_with_attenuation +++ b/EXAMPLES/applications/anisotropy/anisotropic_isotropic_model/DATA/Par_file_homogeneous_with_attenuation @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -330,6 +333,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/anisotropy/anisotropic_zinc_crystal/DATA/Par_file b/EXAMPLES/applications/anisotropy/anisotropic_zinc_crystal/DATA/Par_file index 44fc87a9b..33c7300ff 100644 --- a/EXAMPLES/applications/anisotropy/anisotropic_zinc_crystal/DATA/Par_file +++ b/EXAMPLES/applications/anisotropy/anisotropic_zinc_crystal/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/DATA/Par_file b/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/DATA/Par_file index 5324f1b37..b92467b56 100644 --- a/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/DATA/Par_file +++ b/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -339,6 +342,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/REF_SEIS/Par_file b/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/REF_SEIS/Par_file index 5324f1b37..b92467b56 100644 --- a/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/REF_SEIS/Par_file +++ b/EXAMPLES/applications/axisymmetric_examples/axisymmetric_case_AXISYM_option/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -339,6 +342,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/axisymmetric_examples/global_Earth_ak135f/DATA/Par_file b/EXAMPLES/applications/axisymmetric_examples/global_Earth_ak135f/DATA/Par_file index c66082d0f..54c7f5d43 100644 --- a/EXAMPLES/applications/axisymmetric_examples/global_Earth_ak135f/DATA/Par_file +++ b/EXAMPLES/applications/axisymmetric_examples/global_Earth_ak135f/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -325,6 +328,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/fluid_solid_kernel/DATA/Par_file b/EXAMPLES/applications/fluid_solid_kernel/DATA/Par_file index a9a311fd4..dc3b863af 100644 --- a/EXAMPLES/applications/fluid_solid_kernel/DATA/Par_file +++ b/EXAMPLES/applications/fluid_solid_kernel/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -326,6 +329,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/initial_mode_LDDRK/DATA/Par_file b/EXAMPLES/applications/initial_mode_LDDRK/DATA/Par_file index 28cdaf4fb..86059434d 100644 --- a/EXAMPLES/applications/initial_mode_LDDRK/DATA/Par_file +++ b/EXAMPLES/applications/initial_mode_LDDRK/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -311,6 +314,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/initial_plane_wave_with_free_surface/DATA/Par_file b/EXAMPLES/applications/initial_plane_wave_with_free_surface/DATA/Par_file index d36ff3190..6458e64e7 100644 --- a/EXAMPLES/applications/initial_plane_wave_with_free_surface/DATA/Par_file +++ b/EXAMPLES/applications/initial_plane_wave_with_free_surface/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -310,6 +313,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Gmsh_example_CPML_MPI/DATA/Par_file b/EXAMPLES/applications/meshing/Gmsh_example_CPML_MPI/DATA/Par_file index 83766b342..6cc45c217 100644 --- a/EXAMPLES/applications/meshing/Gmsh_example_CPML_MPI/DATA/Par_file +++ b/EXAMPLES/applications/meshing/Gmsh_example_CPML_MPI/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -333,6 +336,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file b/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file index 241c7e0ea..b77664c22 100644 --- a/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file +++ b/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -323,6 +326,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 300 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file.serial b/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file.serial index f0ad6eefb..74e1406b3 100644 --- a/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file.serial +++ b/EXAMPLES/applications/meshing/Gmsh_example_Stacey_MPI/DATA/Par_file.serial @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -323,6 +326,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 300 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/CUBIT_meshing/4_export_mesh.py b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/CUBIT_meshing/4_export_mesh.py index a56184dea..ebbc9f38b 100755 --- a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/CUBIT_meshing/4_export_mesh.py +++ b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/CUBIT_meshing/4_export_mesh.py @@ -212,9 +212,9 @@ # this will help when creating a new nummaterial_velocity_file for Marmousi2 with different properties for each surface. print("# each surface with its own block material definition") print("#") - print("# using elastic material definition") + print("# using elastic material definition") print("#") - + for i in surfaces: isurf = i # surface ids start at 1 print("# surface: ",isurf) diff --git a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file index 52585e4b4..67ec7b14b 100644 --- a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file +++ b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -322,6 +325,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file.mesh-improved b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file.mesh-improved index c059046ac..e256d6caa 100644 --- a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file.mesh-improved +++ b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/DATA/Par_file.mesh-improved @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -322,6 +325,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/REF_SEIS/Par_file b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/REF_SEIS/Par_file index 52585e4b4..67ec7b14b 100644 --- a/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/REF_SEIS/Par_file +++ b/EXAMPLES/applications/meshing/Marmousi_mesh_of_the_model/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -322,6 +325,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_homogeneous/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_homogeneous/DATA/Par_file index 9adc8855b..57b0f160e 100644 --- a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_homogeneous/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_homogeneous/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -316,6 +319,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_fluid_solid/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_fluid_solid/DATA/Par_file index 24be14a90..6d9a2f9b5 100644 --- a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_fluid_solid/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_fluid_solid/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -323,6 +326,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_solid_only/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_solid_only/DATA/Par_file index 7999bdb31..199d3180f 100644 --- a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_solid_only/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/CPML_normal_solid_only/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -322,6 +325,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_homogeneous/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_homogeneous/DATA/Par_file index 379b8f8c3..3c4aee8b4 100644 --- a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_homogeneous/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_homogeneous/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -316,6 +319,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_normal_fluid_solid/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_normal_fluid_solid/DATA/Par_file index 6636e3c4b..7912407e5 100644 --- a/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_normal_fluid_solid/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_CUBIT_mesh_from_Ronan_Madec/Stacey_normal_fluid_solid/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -323,6 +326,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file index d334a9f28..462b44fbf 100644 --- a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file +++ b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_adj b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_adj index c46602d39..05235aebd 100644 --- a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_adj +++ b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_adj @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_fwd b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_fwd index 38aaa1f7b..07cca4e8a 100644 --- a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_fwd +++ b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_fwd @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_kernel b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_kernel index 14ae4731e..0156859bf 100644 --- a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_kernel +++ b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_kernel @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_save_forward b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_save_forward index d43196aaa..c97b0bce2 100644 --- a/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_save_forward +++ b/EXAMPLES/applications/meshing/salt_dome_Vadim/specfem2d_run_input_files_and_scripts/DATA/Par_file_save_forward @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/moving_sources_acoustic/DATA/Par_file b/EXAMPLES/applications/moving_sources_acoustic/DATA/Par_file index 98f968c5e..8a9e787d8 100644 --- a/EXAMPLES/applications/moving_sources_acoustic/DATA/Par_file +++ b/EXAMPLES/applications/moving_sources_acoustic/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -310,6 +313,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/nondestructive_testing/BENCHIE_water_PVC/DATA/Par_file b/EXAMPLES/applications/nondestructive_testing/BENCHIE_water_PVC/DATA/Par_file index 3b1715bca..749f07a94 100644 --- a/EXAMPLES/applications/nondestructive_testing/BENCHIE_water_PVC/DATA/Par_file +++ b/EXAMPLES/applications/nondestructive_testing/BENCHIE_water_PVC/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -337,6 +340,9 @@ nbregions = 7 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/Pekeris_waveguide/DATA/Par_file b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/Pekeris_waveguide/DATA/Par_file index e1399fd50..188be0f2f 100644 --- a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/Pekeris_waveguide/DATA/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/Pekeris_waveguide/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -312,6 +315,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_free_bottom_surface/DATA/Par_file b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_free_bottom_surface/DATA/Par_file index bf2825927..e6d7cf0d9 100644 --- a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_free_bottom_surface/DATA/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_free_bottom_surface/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -310,6 +313,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 10000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_rigid_bottom_surface/DATA/Par_file b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_rigid_bottom_surface/DATA/Par_file index 49d00f9cc..faa70f7a6 100644 --- a/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_rigid_bottom_surface/DATA/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/perfect_idealized_oceanic_guide_in_underwater_acoustics/with_rigid_bottom_surface/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/thermocline/DATA/Par_file b/EXAMPLES/applications/ocean_acoustics/thermocline/DATA/Par_file index a99607255..25d24a29d 100644 --- a/EXAMPLES/applications/ocean_acoustics/thermocline/DATA/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/thermocline/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -320,6 +323,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 300 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/DATA/Par_file b/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/DATA/Par_file index e248857c0..05a1d3998 100644 --- a/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/DATA/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -333,6 +336,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .true. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .true. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/REF_SEIS/Par_file b/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/REF_SEIS/Par_file index e248857c0..05a1d3998 100644 --- a/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/REF_SEIS/Par_file +++ b/EXAMPLES/applications/ocean_acoustics/tomographic_ocean_model/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -333,6 +336,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .true. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .true. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/DATA/Par_file b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/DATA/Par_file index 94c7ddfe3..2e0fdb73b 100644 --- a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/DATA/Par_file +++ b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -335,6 +338,9 @@ nbregions = 4 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .true. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .true. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_KERNEL/Par_file b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_KERNEL/Par_file index a823dad90..6a038f3d5 100644 --- a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_KERNEL/Par_file +++ b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_KERNEL/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -335,6 +338,9 @@ nbregions = 4 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .true. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .true. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_SEIS/Par_file b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_SEIS/Par_file index 94c7ddfe3..2e0fdb73b 100644 --- a/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_SEIS/Par_file +++ b/EXAMPLES/applications/simple_topography_and_also_a_simple_fluid_layer/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -335,6 +338,9 @@ nbregions = 4 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .true. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .true. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/Par_file_fluid_solid b/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/Par_file_fluid_solid index 9d480ddc6..497947cec 100644 --- a/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/Par_file_fluid_solid +++ b/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/Par_file_fluid_solid @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -329,6 +332,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/the_same_bug_appears_from_the_right_PML/Par_file_fluid_solid b/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/the_same_bug_appears_from_the_right_PML/Par_file_fluid_solid index 9d480ddc6..497947cec 100644 --- a/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/the_same_bug_appears_from_the_right_PML/Par_file_fluid_solid +++ b/EXAMPLES/applications/unresolved_bugs/bugPMLs_1_extra_phase_coming_back_from_the_left_PML/the_same_bug_appears_from_the_right_PML/Par_file_fluid_solid @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -329,6 +332,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/applications/unresolved_bugs/bugPMLs_2_weak_instability_in_long_times/DATA/Par_file b/EXAMPLES/applications/unresolved_bugs/bugPMLs_2_weak_instability_in_long_times/DATA/Par_file index e9e09ed7c..4f88a3ce3 100644 --- a/EXAMPLES/applications/unresolved_bugs/bugPMLs_2_weak_instability_in_long_times/DATA/Par_file +++ b/EXAMPLES/applications/unresolved_bugs/bugPMLs_2_weak_instability_in_long_times/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -327,6 +330,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 1000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC/DATA/Par_file b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC/DATA/Par_file index 6f2a9abd6..fd287cb00 100644 --- a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC/DATA/Par_file +++ b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -313,6 +316,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC_ELASTIC/DATA/Par_file b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC_ELASTIC/DATA/Par_file index b5481f9fa..ec924de18 100644 --- a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC_ELASTIC/DATA/Par_file +++ b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ACOUSTIC_ELASTIC/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -316,6 +319,9 @@ nbregions = 3 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ELASTIC/DATA/Par_file b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ELASTIC/DATA/Par_file index 206ed7060..815a83dac 100644 --- a/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ELASTIC/DATA/Par_file +++ b/EXAMPLES/benchmarks/BENCHMARK_CLAERBOUT_ADJOINT/ELASTIC/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -313,6 +316,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_off_versus_analytical/DATA/Par_file b/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_off_versus_analytical/DATA/Par_file index 59ff92cda..308a25860 100644 --- a/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_off_versus_analytical/DATA/Par_file +++ b/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_off_versus_analytical/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_on_versus_analytical/DATA/Par_file b/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_on_versus_analytical/DATA/Par_file index cdabb87b5..0071488f8 100644 --- a/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_on_versus_analytical/DATA/Par_file +++ b/EXAMPLES/benchmarks/attenuation/viscoacoustic_attenuation_on_versus_analytical/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_inside_an_element b/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_inside_an_element index dc40e65b5..57a654336 100644 --- a/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_inside_an_element +++ b/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_inside_an_element @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -317,6 +320,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_shared_by_four_elements b/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_shared_by_four_elements index fd6e32de2..2a3ddc0b4 100644 --- a/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_shared_by_four_elements +++ b/EXAMPLES/benchmarks/attenuation/viscoelastic/DATA/Par_file_attenuation_2D_source_in_point_shared_by_four_elements @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -317,6 +320,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements index b89987a1e..d3f7e2ff4 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element index 9e51b92d4..ed67bfe59 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/REF_SEIS/Par_file b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/REF_SEIS/Par_file index b89987a1e..d3f7e2ff4 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/REF_SEIS/Par_file +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/analytical_solution_elastic_Carcione.py b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/analytical_solution_elastic_Carcione.py index c765d230c..b3ccd8a70 100755 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/analytical_solution_elastic_Carcione.py +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_elastic/analytical_solution_elastic_Carcione.py @@ -88,52 +88,52 @@ def heaviside(t): def G1(r, t, v1, v2, do_not_compute_near_field=False): """ - Green's function G1 from equation (B2a) of Carcione et al., Wave propagation simulation + Green's function G1 from equation (B2a) of Carcione et al., Wave propagation simulation in a linear viscoelastic medium, Geophysical Journal, vol. 95, p. 597-611 (1988) """ tau1 = r / v1 tau2 = r / v2 - + heaviside_tau1 = heaviside(t - tau1) heaviside_tau2 = heaviside(t - tau2) - + G1_val = 0.0 - + if heaviside_tau1 == 1: G1_val += 1.0 / (v1**2 * np.sqrt(t**2 - tau1**2)) - + if not do_not_compute_near_field: if heaviside_tau1 == 1: G1_val += np.sqrt(t**2 - tau1**2) / (r**2) if heaviside_tau2 == 1: G1_val -= np.sqrt(t**2 - tau2**2) / (r**2) - + return G1_val def G2(r, t, v1, v2, do_not_compute_near_field=False): """ - Green's function G2 from equation (B2a) of Carcione et al., Wave propagation simulation + Green's function G2 from equation (B2a) of Carcione et al., Wave propagation simulation in a linear viscoelastic medium, Geophysical Journal, vol. 95, p. 597-611 (1988) """ tau1 = r / v1 tau2 = r / v2 - + heaviside_tau1 = heaviside(t - tau1) heaviside_tau2 = heaviside(t - tau2) - + G2_val = 0.0 - + if heaviside_tau2 == 1: G2_val -= 1.0 / (v2**2 * np.sqrt(t**2 - tau2**2)) - + if not do_not_compute_near_field: if heaviside_tau1 == 1: G2_val += np.sqrt(t**2 - tau1**2) / (r**2) if heaviside_tau2 == 1: G2_val -= np.sqrt(t**2 - tau2**2) / (r**2) - + return G2_val def u1(t, v1, v2, x1, x2, rho, F, do_not_compute_near_field=False): @@ -141,7 +141,7 @@ def u1(t, v1, v2, x1, x2, rho, F, do_not_compute_near_field=False): # Source-receiver distance r = np.sqrt(x1**2 + x2**2) - return F * x1 * x2 * (G1(r, t, v1, v2, do_not_compute_near_field) + + return F * x1 * x2 * (G1(r, t, v1, v2, do_not_compute_near_field) + G2(r, t, v1, v2, do_not_compute_near_field)) / (2.0 * pi * rho * r**2) def u2(t, v1, v2, x1, x2, rho, F, do_not_compute_near_field=False): @@ -149,7 +149,7 @@ def u2(t, v1, v2, x1, x2, rho, F, do_not_compute_near_field=False): # Source-receiver distance r = np.sqrt(x1**2 + x2**2) - return F * (x2*x2*G1(r, t, v1, v2, do_not_compute_near_field) - + return F * (x2*x2*G1(r, t, v1, v2, do_not_compute_near_field) - x1*x1*G2(r, t, v1, v2, do_not_compute_near_field)) / (2.0 * pi * rho * r**2) @@ -298,7 +298,7 @@ def main(): # ********** # Compute Ux # ********** - + print("computing Ux component...") # Store the Green function (using 1-based indexing equivalent) @@ -339,7 +339,7 @@ def main(): # ********** # Compute Uz # ********** - + print("computing Uz component...") # Store the Green function (using 1-based indexing equivalent) diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements index e16e76a11..4685082a6 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/REF_SEIS/Par_file b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/REF_SEIS/Par_file index e16e76a11..4685082a6 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/REF_SEIS/Par_file +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_force_source_seismograms_viscoelastic/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements index 8d32d65f8..1c9f4450b 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_at_the_corner_between_several_spectral_elements @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element index 0ab68b068..8df95bc85 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/DATA/Par_file_no_attenuation_2D_inside_a_given_spectral_element @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/REF_SEIS/Par_file b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/REF_SEIS/Par_file index 8d32d65f8..1c9f4450b 100644 --- a/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/REF_SEIS/Par_file +++ b/EXAMPLES/benchmarks/check_absolute_amplitude_of_pressure_source_seismograms_acoustic/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/DATA/Par_file b/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/DATA/Par_file index 719567ca4..bca2cf911 100644 --- a/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/DATA/Par_file +++ b/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/DATA/Par_file @@ -79,7 +79,7 @@ TOMOGRAPHY_FILE = dummy #----------------------------------------------------------- # attenuation parameters -ATTENUATION_VISCOELASTIC = .false. # turn attenuation (viscoelasticity) on or off for non-poroelastic solid parts of the model +ATTENUATION_VISCOELASTIC = .false. # turn attenuation (viscoelasticity) on or off for non-poroelastic solid parts of the model ATTENUATION_VISCOACOUSTIC = .false. # turn attenuation (viscoacousticity) on or off for non-poroelastic fluid parts of the model # for viscoelastic or viscoacoustic attenuation @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -150,7 +153,7 @@ write_moving_sources_database = .false. # receiver set parameters for recording stations (i.e. recording points) # seismotype : record 1=displ 2=veloc 3=accel 4=pressure 5=curl of displ 6=the fluid potential 7=electric field -seismotype = 1,4 # several values can be chosen. For example : 1,2,4 +seismotype = 1,4 # several values can be chosen. For example : 1,2,4 # interval in time steps for writing of seismograms # every how many time steps we save the seismograms @@ -306,7 +309,7 @@ nbmodels = 1 # Please also note that Qmu is always equal to Qs, but Qkappa is in general not equal to Qp. # To convert one to the other see doc/Qkappa_Qmu_versus_Qp_Qs_relationship_in_2D_plane_strain.pdf and # utils/attenuation/conversion_from_Qkappa_Qmu_to_Qp_Qs_from_Dahlen_Tromp_959_960.f90. -1 1 2500.d0 3400.d0 1963.d0 0 0 9999 9999 0 0 0 0 0 0 # elastic +1 1 2500.d0 3400.d0 1963.d0 0 0 9999 9999 0 0 0 0 0 0 # elastic # file containing interfaces for internal mesh interfacesfile = ./interfaces.dat @@ -337,6 +340,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/compare_with_reference_solution_Aki.py b/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/compare_with_reference_solution_Aki.py index e423b7d51..03af94182 100755 --- a/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/compare_with_reference_solution_Aki.py +++ b/EXAMPLES/benchmarks/infinite_homogeneous_axisymmetric_force_source/compare_with_reference_solution_Aki.py @@ -206,7 +206,7 @@ def get_fullspace_solution_time_domain(x, y, z, else: print(f"Error: Invalid source time function type {specfem2d_stf} - not implemented yet") sys.exit(1) - + print("") # amplification diff --git a/EXAMPLES/benchmarks/infinite_homogeneous_moment_tensor_vertical_dip_slip/DATA/Par_file b/EXAMPLES/benchmarks/infinite_homogeneous_moment_tensor_vertical_dip_slip/DATA/Par_file index 09e83118c..3e51b30e2 100644 --- a/EXAMPLES/benchmarks/infinite_homogeneous_moment_tensor_vertical_dip_slip/DATA/Par_file +++ b/EXAMPLES/benchmarks/infinite_homogeneous_moment_tensor_vertical_dip_slip/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -310,6 +313,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/infinite_homogeneous_plane_wave/DATA/Par_file b/EXAMPLES/benchmarks/infinite_homogeneous_plane_wave/DATA/Par_file index 7202daa8b..7ab067058 100644 --- a/EXAMPLES/benchmarks/infinite_homogeneous_plane_wave/DATA/Par_file +++ b/EXAMPLES/benchmarks/infinite_homogeneous_plane_wave/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -317,6 +320,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 50 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/benchmarks/semi_infinite_homogeneous/DATA/Par_file b/EXAMPLES/benchmarks/semi_infinite_homogeneous/DATA/Par_file index 7cf086989..c2941320b 100644 --- a/EXAMPLES/benchmarks/semi_infinite_homogeneous/DATA/Par_file +++ b/EXAMPLES/benchmarks/semi_infinite_homogeneous/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 100 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/process_DATA_Par_files_to_update_their_parameters_from_a_main_file.py b/EXAMPLES/process_DATA_Par_files_to_update_their_parameters_from_a_main_file.py index 3d9eb8d1e..4643c3c59 100755 --- a/EXAMPLES/process_DATA_Par_files_to_update_their_parameters_from_a_main_file.py +++ b/EXAMPLES/process_DATA_Par_files_to_update_their_parameters_from_a_main_file.py @@ -55,6 +55,11 @@ "small_SEM_solvers_in_Fortran_and_C_without_MPI_to_learn" \ ] +# optional parameters in Par_file +OPTIONAL_PARAMETERS = [ + #"IS_WAVEFIELD_DISCONTINUITY" +] + # #---------------------------------------------------------------------------- # @@ -121,7 +126,7 @@ def read_Par_file_sections(parameters,file,verbose=False): for line in f: dataline = line.strip() - #print("line: ",dataline) + #print("debug: dataline = ",dataline) if dataline: # line with some data @@ -132,6 +137,8 @@ def read_Par_file_sections(parameters,file,verbose=False): else: # parameter line (eventually with comment appended) # for example: SIMULATION_TYPE = 1 # or 2 # or 3 + par_string = "" + app_string = "" # separates parameter from appended comment(s) index_app = dataline.find('#') @@ -197,7 +204,7 @@ def read_Par_file_sections(parameters,file,verbose=False): value = par_string # appended comment - if index_app > 0: + if len(app_string) > 0: appendix = app_string else: appendix = '' @@ -285,9 +292,9 @@ def get_maximum_parameter_name_length(parameters,verbose=False): #print("parameter name: ",name) # exclude record_at_surface_same_vertical** with set number if "record_at_surface_same_vertical" in name: - if max_name_length < 31: max_name_length = 31 + if 31 > max_name_length: max_name_length = 31 else: - if max_name_length < len(name): max_name_length = len(name) + if len(name) > max_name_length: max_name_length = len(name) # user info if verbose: @@ -295,15 +302,15 @@ def get_maximum_parameter_name_length(parameters,verbose=False): print(" maximum name length: ",max_name_length) # restrict to a minimum of 32 character until = sign, we will add 1 space when writing out line below - if max_name_length <= 31: - max_name_length = 31 + if max_name_length <= 32-1: + max_name_length = 32-1 else: # add additional white space max_name_length += 1 # user info if verbose: - print(" using parameter format length: ",max_name_length) + print(" using parameter format length: ",max_name_length," + 1") print("") return max_name_length @@ -407,7 +414,10 @@ def write_template_file(parameters,tmp_file,verbose=False): f.write( "%s = %s\n" % (name.ljust(max_name_length),value) ) else: # Mesh_Par_file data line - f.write( "%s\n" % value ) + if appendix: + f.write( "%s %s\n" % (value,appendix) ) + else: + f.write( "%s\n" % value ) f.write( "\n" ) f.close() @@ -492,20 +502,50 @@ def check_and_update_Par_file(my_parameters,file): """ updates parameter entries """ - global DEPRECATED_RENAMED_PARAMETERS + global DEPRECATED_RENAMED_PARAMETERS,OPTIONAL_PARAMETERS global main_parameters global is_Par_file_with_data # checks for old, deprecated parameters nold_parameters = 0 + noptional_parameters = 0 #print(" searching deprecated parameters...") my_parameters_new = my_parameters.copy() + main_parameters_new = main_parameters.copy() for name in my_parameters.keys(): if not name in main_parameters.keys(): - if (not "PAR_FILE_DATA" in name) and \ - (not "NZ_DOUBLING" in name) and \ - (not "PAR_FILE_RECEIVERSET_" in name): + if name in OPTIONAL_PARAMETERS: + print(" optional parameter: ",name) + noptional_parameters += 1 + # adds optional parameter to main parameter list + is_found = True + (val,comment,appendix) = my_parameters[name] + + # gets current index of item in parameter list + index = list(my_parameters.keys()).index(name) + index_previous = 0 + if index > 0: + # gets name from previous item + previous = list(my_parameters.keys())[index-1] + # gets index from previous item in main_parameter list + index_previous = list(main_parameters_new.keys()).index(previous) + + # adds to ordered dict + if index_previous > 0: + # adds new item after previous + keys = list(main_parameters_new.keys())[index_previous+1:] + main_parameters_new[name] = (val,comment,appendix) + # moves keys below current item + for k in keys: + main_parameters_new.move_to_end(k) + else: + # adds item to the end + main_parameters_new[name] = (val,comment,appendix) + + elif (not "PAR_FILE_DATA" in name) and \ + (not "NZ_DOUBLING" in name) and \ + (not "PAR_FILE_RECEIVERSET_" in name): print(" deprecated parameter: ",name) nold_parameters += 1 @@ -546,20 +586,22 @@ def check_and_update_Par_file(my_parameters,file): # add missing main parameters and replaces comment lines to compare sections nmissing_parameters = 0 #print(" searching missing parameters...") - for name in main_parameters.keys(): - if (not "PAR_FILE_DATA" in name) and (not "PAR_FILE_RECEIVERSET_" in name): + for name in main_parameters_new.keys(): + if (not "PAR_FILE_DATA" in name) and \ + (not "PAR_FILE_RECEIVERSET_" in name): # checks if missing if not name in my_parameters.keys(): print(" misses parameter: ",name) nmissing_parameters += 1 # adds from main template record - (val,comment,appendix) = main_parameters[name] + (val,comment,appendix) = main_parameters_new[name] my_parameters[name] = (val,comment,appendix) # updates comments nold_comments = 0 - for name in main_parameters.keys(): - if (not "PAR_FILE_DATA" in name) and (not "PAR_FILE_RECEIVERSET_" in name): + for name in main_parameters_new.keys(): + if (not "PAR_FILE_DATA" in name) and \ + (not "PAR_FILE_RECEIVERSET_" in name): # checks we have this parameter if not name in my_parameters.keys(): print("Error comparing main with current file format parameter",name) @@ -568,7 +610,7 @@ def check_and_update_Par_file(my_parameters,file): # compares and replaces comments and appendix (val_orig,comment_orig,appendix_orig) = my_parameters[name] - (val,comment,appendix) = main_parameters[name] + (val,comment,appendix) = main_parameters_new[name] if comment_orig != comment or appendix != appendix_orig: nold_comments += 1 # replace with new comment/appendix and only keep original value @@ -579,23 +621,29 @@ def check_and_update_Par_file(my_parameters,file): iorder_new = 0 num_material_entries = 0 num_region_entries = 0 - for name in main_parameters.keys(): + for name in main_parameters_new.keys(): if not is_Par_file_with_data: # regular Par_file must have a one-to-one match # checks that name is available - if not name in my_parameters.keys(): + if (not name in my_parameters.keys()) and (not name in OPTIONAL_PARAMETERS): print("Error ordering with current file format parameter",name) sys.tracebacklimit=0 raise Exception('parameter list invalid: %s' % file) - # get values - (val,comment,appendix) = my_parameters[name] - # put into same order of appearance - ordered_parameters[name] = (val,comment,appendix) + # adds parameter + if name in my_parameters.keys(): + # get values + (val,comment,appendix) = my_parameters[name] + + # put into same order of appearance + ordered_parameters[name] = (val,comment,appendix) + iorder_new += 1 else: # Mesh_Par_file can have different number of lines for data ranges # new parameter file entry - if (not "PAR_FILE_DATA" in name) and (not "NZ_DOUBLING" in name) and (not "PAR_FILE_RECEIVERSET_" in name): + if (not "PAR_FILE_DATA" in name) and \ + (not "NZ_DOUBLING" in name) and \ + (not "PAR_FILE_RECEIVERSET_" in name): # checks that name is available if not name in my_parameters.keys(): print("Error ordering with current file format parameter",name) @@ -689,8 +737,8 @@ def check_and_update_Par_file(my_parameters,file): if len(ordered_parameters.keys()) != len(my_parameters.keys()): print("Error ordering with parameters got different lengths:") print("new length is ",len(ordered_parameters.keys())," instead of ",len(my_parameters.keys())) - #sys.tracebacklimit=0 - #raise Exception('parameter list invalid: %s' % file) + sys.tracebacklimit=0 + raise Exception('parameter list invalid: %s' % file) # checks if order changed nold_order = 0 @@ -701,7 +749,9 @@ def check_and_update_Par_file(my_parameters,file): print(" needs re-ordering...",nold_order) # replace old file if necessary - if nold_parameters == 0 and nmissing_parameters == 0 and nold_comments == 0 and nold_order == 0: + if nold_parameters == 0 and nmissing_parameters == 0 and \ + noptional_parameters == 0 and \ + nold_comments == 0 and nold_order == 0: # user info print(" file is okay and up-to-date") else: @@ -722,7 +772,8 @@ def check_and_update_Par_file(my_parameters,file): # frees new order del ordered_parameters - + del my_parameters_new + del main_parameters_new def check_parameter_file_type(file): """ @@ -832,10 +883,10 @@ def update_Par_files(main_file,replace=False): def usage(): print("usage:") - print(" ./process_DATA_Par_files_to_update_their_parameters_from_a_main.py Main-Par-file replace") + print(" ./process_DATA_Par_files_to_update_their_parameters_from_a_main_file.py Main-Par-file replace") print(" with") print(" Main-Par_file - Par_file which serves as main template (e.g. DATA/Par_file)") - print(" replace = flag to force replacing of file [0==check-only/1==replace]") + print(" replace - flag to force replacing of file [0==check-only/1==replace]") # #---------------------------------------------------------------------------- diff --git a/EXAMPLES/real_world/Industrial_Format_SEP/DATA/Par_file b/EXAMPLES/real_world/Industrial_Format_SEP/DATA/Par_file index ddf686235..18a0bc10c 100644 --- a/EXAMPLES/real_world/Industrial_Format_SEP/DATA/Par_file +++ b/EXAMPLES/real_world/Industrial_Format_SEP/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_1 b/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_1 index 9c209b117..9b0e4f9cb 100644 --- a/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_1 +++ b/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_1 @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_2 b/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_2 index d4e1c258c..75ec1c634 100644 --- a/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_2 +++ b/EXAMPLES/real_world/Industrial_Format_SEP/REF_SEIS/Par_file.step_2 @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/real_world/Marmousi2/DATA/Par_file b/EXAMPLES/real_world/Marmousi2/DATA/Par_file index b0b27e258..830f54721 100644 --- a/EXAMPLES/real_world/Marmousi2/DATA/Par_file +++ b/EXAMPLES/real_world/Marmousi2/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -325,6 +328,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/real_world/Marmousi2/interpolate_Marmousi_2_tomo.py b/EXAMPLES/real_world/Marmousi2/interpolate_Marmousi_2_tomo.py index 38b6cec31..d391d5a1a 100755 --- a/EXAMPLES/real_world/Marmousi2/interpolate_Marmousi_2_tomo.py +++ b/EXAMPLES/real_world/Marmousi2/interpolate_Marmousi_2_tomo.py @@ -147,7 +147,7 @@ def load_marmousi2(): # convert units vs *= 1000.0 # from km/s to m/s vp *= 1000.0 - rho *= 1000.0 # from g/cm^3 to kg/m^3 + rho *= 1000.0 # from g/cm^3 to kg/m^3 # determine grid spacing nx, nz = vp.shape @@ -266,7 +266,7 @@ def modify_original_model(model): fluid_layer_depth = index_fluid * 1.25 # original grid sampling uses 1.25 m print(" fluid layer depth = {} (m)".format(fluid_layer_depth)) print("") - + # replaces fluid layer with extended solid domain velocities # takes top layer from solid domain vs_top_solid = vs[:,index_solid] @@ -906,7 +906,7 @@ def create_tomography_file(model): # binary format print(" using binary file format") print("") - + # collects header info output_header_data = np.array([ header_origin_x, header_origin_z, header_end_x, header_end_z, \ header_dx, header_dz, \ diff --git a/EXAMPLES/reproducible_study/Bottero2016_axisymmetry_example/DATA/Par_file b/EXAMPLES/reproducible_study/Bottero2016_axisymmetry_example/DATA/Par_file index 393cbf417..c1ec22fe4 100644 --- a/EXAMPLES/reproducible_study/Bottero2016_axisymmetry_example/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Bottero2016_axisymmetry_example/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -322,6 +325,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Komatitsch1999_canyon/DATA/Par_file b/EXAMPLES/reproducible_study/Komatitsch1999_canyon/DATA/Par_file index 684536278..1eb074f49 100644 --- a/EXAMPLES/reproducible_study/Komatitsch1999_canyon/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Komatitsch1999_canyon/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -310,6 +313,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/fluid_solid_external_mesh/DATA/Par_file b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/fluid_solid_external_mesh/DATA/Par_file index 46f196658..b07ce80cd 100644 --- a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/fluid_solid_external_mesh/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/fluid_solid_external_mesh/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -316,6 +319,9 @@ nbregions = 6 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 2000 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_flat_ocean_bottom/DATA/Par_file b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_flat_ocean_bottom/DATA/Par_file index 3e652abff..d423417f4 100644 --- a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_flat_ocean_bottom/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_flat_ocean_bottom/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -312,6 +315,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_sinusoidal_ocean_bottom/DATA/Par_file b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_sinusoidal_ocean_bottom/DATA/Par_file index ff072e10a..2f6a0d0e8 100644 --- a/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_sinusoidal_ocean_bottom/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Komatitsch2000_fluid_solid/from_2000_Geophysics_paper_sinusoidal_ocean_bottom/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -312,6 +315,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Morency2008_poroelastic_acoustic/DATA/Par_file b/EXAMPLES/reproducible_study/Morency2008_poroelastic_acoustic/DATA/Par_file index 2b77bf527..ecd9ac638 100644 --- a/EXAMPLES/reproducible_study/Morency2008_poroelastic_acoustic/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Morency2008_poroelastic_acoustic/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -335,6 +338,9 @@ nbregions = 2 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Morency2008_poroelastic_semi_infinite_homogeneous/DATA/Par_file b/EXAMPLES/reproducible_study/Morency2008_poroelastic_semi_infinite_homogeneous/DATA/Par_file index 2bc1fd2fd..4e21d23d8 100644 --- a/EXAMPLES/reproducible_study/Morency2008_poroelastic_semi_infinite_homogeneous/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Morency2008_poroelastic_semi_infinite_homogeneous/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 200 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Morency2020_electromagnetic_GPR_TM/DATA/Par_file b/EXAMPLES/reproducible_study/Morency2020_electromagnetic_GPR_TM/DATA/Par_file index 1a64ece9e..a93602bea 100644 --- a/EXAMPLES/reproducible_study/Morency2020_electromagnetic_GPR_TM/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Morency2020_electromagnetic_GPR_TM/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -329,6 +332,9 @@ nbregions = 9 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 300 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_132rec_checker b/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_132rec_checker index 6f1598767..719feb905 100644 --- a/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_132rec_checker +++ b/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_132rec_checker @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_onerec b/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_onerec index 70e9ae385..2b7c48a87 100644 --- a/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_onerec +++ b/EXAMPLES/reproducible_study/Tape2007/DATA/Par_file_Tape2007_onerec @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tape2007/REF_SEIS/Par_file b/EXAMPLES/reproducible_study/Tape2007/REF_SEIS/Par_file index 6f1598767..719feb905 100644 --- a/EXAMPLES/reproducible_study/Tape2007/REF_SEIS/Par_file +++ b/EXAMPLES/reproducible_study/Tape2007/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tape2007_kernel/DATA/Par_file b/EXAMPLES/reproducible_study/Tape2007_kernel/DATA/Par_file index bf99e4cfa..a75968678 100644 --- a/EXAMPLES/reproducible_study/Tape2007_kernel/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Tape2007_kernel/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file b/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file index 5414ad56d..adffa9cc3 100644 --- a/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file_Tromp2005_s100 b/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file_Tromp2005_s100 index e8c7651bf..49a97864f 100644 --- a/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file_Tromp2005_s100 +++ b/EXAMPLES/reproducible_study/Tromp2005/DATA/Par_file_Tromp2005_s100 @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tromp2005_kernel/DATA/Par_file b/EXAMPLES/reproducible_study/Tromp2005_kernel/DATA/Par_file index 98008e0f6..2acfbfecb 100644 --- a/EXAMPLES/reproducible_study/Tromp2005_kernel/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Tromp2005_kernel/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 400 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/DATA/Par_file b/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/DATA/Par_file index 2b270cdfa..03fe6ca7b 100644 --- a/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/DATA/Par_file +++ b/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/DATA/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -346,6 +349,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/REF_SEIS/Par_file b/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/REF_SEIS/Par_file index c36596f94..7f28aa978 100644 --- a/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/REF_SEIS/Par_file +++ b/EXAMPLES/reproducible_study/Tromp2010_noise_uniform/REF_SEIS/Par_file @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -329,6 +332,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 250 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/doc/USER_MANUAL/03_mesh_generation.tex b/doc/USER_MANUAL/03_mesh_generation.tex index d525b3d27..417c8f269 100644 --- a/doc/USER_MANUAL/03_mesh_generation.tex +++ b/doc/USER_MANUAL/03_mesh_generation.tex @@ -507,7 +507,11 @@ \section{Controlling the quality of an external mesh} \section{Controlling how the mesh samples the wave field} %------------------------------------------------------------------------------------------------% -To examine (using Gnuplot) how the mesh samples the wave field, type +To display mesh files, you can set the parameter \texttt{SAVE\_MESH\_FILES} in \texttt{DATA/Par\_file} to \texttt{.true.} +to visualize related files. This will save VTK files, as well as ASCII and/or Gnuplot files, +related to your simulation in folder \texttt{OUTPUT\_FILES}. + +For example, to examine (using Gnuplot) how the mesh samples the wave field, type % \begin{verbatim} gnuplot plot_points_per_wavelength_histogram.gnu diff --git a/setup/constants.h.in b/setup/constants.h.in index 853adccde..5f1293ec8 100644 --- a/setup/constants.h.in +++ b/setup/constants.h.in @@ -99,9 +99,6 @@ ! (for Marmousi2 modeling, dominant frequency must be 35 Hz) double precision, parameter :: F_ORMSBY = 35.0 -! outputs source time function to file - logical, parameter :: PRINT_SOURCE_TIME_FUNCTION = .true. - !!----------------------------------------------------------- !! !! poroelasticity @@ -226,9 +223,6 @@ ! relative mesh tolerance for fast global numbering double precision, parameter :: SMALLVALTOL = 1.d-10 -! outputs mesh files (partitioning) in VTK format - logical, parameter :: SAVE_MESHFILES_VTK_FORMAT = .true. - !!----------------------------------------------------------- !! !! add a random perturbation to the mesh (as in Figure 3.12 of the PhD thesis of Dimitri Komatitsch for instance). diff --git a/src/gpu/kernels/compute_coupling_acoustic_el_kernel.cu b/src/gpu/kernels/compute_coupling_acoustic_el_kernel.cu index ff96792bb..6eb5e08ba 100644 --- a/src/gpu/kernels/compute_coupling_acoustic_el_kernel.cu +++ b/src/gpu/kernels/compute_coupling_acoustic_el_kernel.cu @@ -65,11 +65,16 @@ __global__ void compute_coupling_acoustic_el_kernel(realw* displ, realw jacobianw; if (iface < num_coupling_ac_el_faces){ + // gets iglob index + // note: iglob is the same for displ(..) and potential_dot_dot(..) + // we take iglob from the elastic element side, since for PML the indexing requires the elastic element. + // however, the normal and jacobian weight are from the acoustic element side as in routine compute_coupling_acoustic_el(). + // "-1" from index values to convert from Fortran-> C indexing - ispec = coupling_ac_el_ispec[iface] - 1; + ispec = coupling_ac_el_ispec[iface*2+1] - 1; // ispec from elastic element - i = coupling_ac_el_ijk[INDEX3(NDIM,NGLLX,0,igll,iface)] - 1; - j = coupling_ac_el_ijk[INDEX3(NDIM,NGLLX,1,igll,iface)] - 1; + i = coupling_ac_el_ijk[INDEX4(NDIM,2,NGLLX,0,1,igll,iface)] - 1; // (i,j) from elastic element + j = coupling_ac_el_ijk[INDEX4(NDIM,2,NGLLX,1,1,igll,iface)] - 1; iglob = d_ibool[INDEX3_PADDED(NGLLX,NGLLX,i,j,ispec)] - 1; @@ -88,6 +93,7 @@ __global__ void compute_coupling_acoustic_el_kernel(realw* displ, // PML if (PML) { // PML element index + // takes elastic side since we access d_displ_elastic_old with offset_pml for local PML elements int ispec_pml = d_spec_to_pml[ispec] - 1; // checks if element is inside the PML if (ispec_pml >= 0) { diff --git a/src/gpu/kernels/compute_coupling_elastic_ac_kernel.cu b/src/gpu/kernels/compute_coupling_elastic_ac_kernel.cu index 4992214ca..a43254996 100644 --- a/src/gpu/kernels/compute_coupling_elastic_ac_kernel.cu +++ b/src/gpu/kernels/compute_coupling_elastic_ac_kernel.cu @@ -67,11 +67,15 @@ __global__ void compute_coupling_elastic_ac_kernel(realw* potential_dot_dot_acou realw jacobianw; if (iface < num_coupling_ac_el_faces){ + // gets iglob index + // note: iglob is the same for accel(..) and potential_dot_dot(..) + // we take iglob from the acoustic element side, since for PML the indexing requires the acoustic element. + // "-1" from index values to convert from Fortran-> C indexing - ispec = coupling_ac_el_ispec[iface] - 1; + ispec = coupling_ac_el_ispec[iface*2] - 1; // ispec from acoustic element - i = coupling_ac_el_ijk[INDEX3(NDIM,NGLLX,0,igll,iface)] - 1; - j = coupling_ac_el_ijk[INDEX3(NDIM,NGLLX,1,igll,iface)] - 1; + i = coupling_ac_el_ijk[INDEX4(NDIM,2,NGLLX,0,0,igll,iface)] - 1; // (i,j) from acoustic element + j = coupling_ac_el_ijk[INDEX4(NDIM,2,NGLLX,1,0,igll,iface)] - 1; iglob = d_ibool[INDEX3_PADDED(NGLLX,NGLLX,i,j,ispec)] - 1; @@ -96,6 +100,7 @@ __global__ void compute_coupling_elastic_ac_kernel(realw* potential_dot_dot_acou // PML if (PML) { // PML element index + // takes acoustic side since we access d_potential_old with offset_pml for local PML elements int ispec_pml = d_spec_to_pml[ispec] - 1; // checks if element is inside the PML if (ispec_pml >= 0) { diff --git a/src/gpu/prepare_mesh_constants_cuda.cu b/src/gpu/prepare_mesh_constants_cuda.cu index 2f500bf38..a6c82c55f 100644 --- a/src/gpu/prepare_mesh_constants_cuda.cu +++ b/src/gpu/prepare_mesh_constants_cuda.cu @@ -406,12 +406,10 @@ void FC_FUNC_(prepare_fields_acoustic_device, // coupling with elastic parts if (*ELASTIC_SIMULATION && *num_coupling_ac_el_faces > 0) { - copy_todevice_int((void**)&mp->d_coupling_ac_el_ispec,coupling_ac_el_ispec,(*num_coupling_ac_el_faces)); - copy_todevice_int((void**)&mp->d_coupling_ac_el_ijk,coupling_ac_el_ijk,2*NGLLX*(*num_coupling_ac_el_faces)); - copy_todevice_realw((void**)&mp->d_coupling_ac_el_normal,coupling_ac_el_normal, - 2*NGLLX*(*num_coupling_ac_el_faces)); - copy_todevice_realw((void**)&mp->d_coupling_ac_el_jacobian2Dw,coupling_ac_el_jacobian2Dw, - NGLLX*(*num_coupling_ac_el_faces)); + copy_todevice_int((void**)&mp->d_coupling_ac_el_ispec,coupling_ac_el_ispec,2*(*num_coupling_ac_el_faces)); + copy_todevice_int((void**)&mp->d_coupling_ac_el_ijk,coupling_ac_el_ijk,2*2*NGLLX*(*num_coupling_ac_el_faces)); + copy_todevice_realw((void**)&mp->d_coupling_ac_el_normal,coupling_ac_el_normal,2*NGLLX*(*num_coupling_ac_el_faces)); + copy_todevice_realw((void**)&mp->d_coupling_ac_el_jacobian2Dw,coupling_ac_el_jacobian2Dw,NGLLX*(*num_coupling_ac_el_faces)); } mp->ninterface_acoustic = *h_ninterface_acoustic; diff --git a/src/meshfem2D/save_databases.f90 b/src/meshfem2D/save_databases.f90 index 7e2c2d403..bbe830157 100644 --- a/src/meshfem2D/save_databases.f90 +++ b/src/meshfem2D/save_databases.f90 @@ -35,9 +35,9 @@ subroutine save_databases() ! generates the databases for the solver - use constants, only: IMAIN,IOUT,MAX_STRING_LEN,SAVE_MESHFILES_VTK_FORMAT,OUTPUT_FILES,myrank + use constants, only: IMAIN,IOUT,MAX_STRING_LEN,OUTPUT_FILES,myrank use part_unstruct_par, only: nspec,iproc - use shared_parameters, only: NPROC + use shared_parameters, only: NPROC,SAVE_MESH_FILES implicit none @@ -110,7 +110,7 @@ subroutine save_databases() enddo ! mesh file output for visualization - if (SAVE_MESHFILES_VTK_FORMAT) call save_databases_VTK_files() + if (SAVE_MESH_FILES) call save_databases_VTK_files() end subroutine save_databases @@ -728,9 +728,9 @@ subroutine save_databases_VTK_files() ! saves mesh files as VTK file - use constants, only: MAX_STRING_LEN,SAVE_MESHFILES_VTK_FORMAT,OUTPUT_FILES,IMAIN,myrank + use constants, only: MAX_STRING_LEN,OUTPUT_FILES,IMAIN,myrank use part_unstruct_par, only: part,elmnts,nodes_coords,nelmnts,nnodes - use shared_parameters, only: NGNOD,num_material,NPROC + use shared_parameters, only: NGNOD,num_material,NPROC,SAVE_MESH_FILES implicit none @@ -742,7 +742,7 @@ subroutine save_databases_VTK_files() character(len=MAX_STRING_LEN) :: filename ! checks if anything to do - if (.not. SAVE_MESHFILES_VTK_FORMAT) return + if (.not. SAVE_MESH_FILES) return ! user output if (myrank == 0) then diff --git a/src/shared/read_parameter_file.F90 b/src/shared/read_parameter_file.F90 index 3684c648b..0cde83fba 100644 --- a/src/shared/read_parameter_file.F90 +++ b/src/shared/read_parameter_file.F90 @@ -131,6 +131,7 @@ subroutine read_parameter_file(BROADCAST_AFTER_READ) call bcast_all_singlel(ACOUSTIC_FORCING) call bcast_all_singlei(noise_source_time_function_type) call bcast_all_singlel(write_moving_sources_database) + call bcast_all_singlel(PRINT_SOURCE_TIME_FUNCTION) ! receivers call bcast_all_string(seismotype) @@ -208,6 +209,7 @@ subroutine read_parameter_file(BROADCAST_AFTER_READ) ! display parameters call bcast_all_singlei(NTSTEP_BETWEEN_OUTPUT_INFO) + call bcast_all_singlel(SAVE_MESH_FILES) call bcast_all_singlel(output_grid_Gnuplot) call bcast_all_singlel(output_grid_ASCII) call bcast_all_singlel(OUTPUT_ENERGY) @@ -672,6 +674,13 @@ subroutine read_parameter_file_only() write(*,*) endif + ! (optional) print source time function to file + call read_value_logical_p(PRINT_SOURCE_TIME_FUNCTION, 'PRINT_SOURCE_TIME_FUNCTION') + if (err_occurred() /= 0) then + ! couldn't find entry + PRINT_SOURCE_TIME_FUNCTION = .false. + endif + !-------------------------------------------------------------------- ! ! receivers @@ -951,7 +960,6 @@ subroutine read_parameter_file_only() ! external mesh parameters if (read_external_mesh) then - ! read info about external mesh call read_value_string_p(mesh_file, 'mesh_file') if (err_occurred() /= 0) then @@ -1052,7 +1060,6 @@ subroutine read_parameter_file_only() endif else - !----------------- ! internal mesh parameters @@ -1158,18 +1165,31 @@ subroutine read_parameter_file_only() endif endif - call read_value_logical_p(output_grid_Gnuplot, 'output_grid_Gnuplot') + ! (optional) saves mesh files for visualization + call read_value_logical_p(SAVE_MESH_FILES, 'SAVE_MESH_FILES') if (err_occurred() /= 0) then - some_parameters_missing_from_Par_file = .true. - write(*,'(a)') 'output_grid_Gnuplot = .false.' - write(*,*) + ! couldn't find entry + SAVE_MESH_FILES = .false. endif - call read_value_logical_p(output_grid_ASCII, 'output_grid_ASCII') - if (err_occurred() /= 0) then - some_parameters_missing_from_Par_file = .true. - write(*,'(a)') 'output_grid_ASCII = .false.' - write(*,*) + ! reads in grid output parameters + if (SAVE_MESH_FILES) then + call read_value_logical_p(output_grid_Gnuplot, 'output_grid_Gnuplot') + if (err_occurred() /= 0) then + some_parameters_missing_from_Par_file = .true. + write(*,'(a)') 'output_grid_Gnuplot = .false.' + write(*,*) + endif + + call read_value_logical_p(output_grid_ASCII, 'output_grid_ASCII') + if (err_occurred() /= 0) then + some_parameters_missing_from_Par_file = .true. + write(*,'(a)') 'output_grid_ASCII = .false.' + write(*,*) + endif + else + output_grid_Gnuplot = .false. + output_grid_ASCII = .false. endif call read_value_logical_p(OUTPUT_ENERGY, 'OUTPUT_ENERGY') diff --git a/src/shared/shared_par.F90 b/src/shared/shared_par.F90 index 2a7caa864..f71d9ff67 100644 --- a/src/shared/shared_par.F90 +++ b/src/shared/shared_par.F90 @@ -181,6 +181,9 @@ module shared_input_parameters ! Flag for writing moving source databases or not logical :: write_moving_sources_database + ! outputs source time function to file + logical :: PRINT_SOURCE_TIME_FUNCTION = .false. + !#----------------------------------------------------------------------------- !# !# receivers @@ -315,8 +318,12 @@ module shared_input_parameters ! general information during the computation and for information of the stability behavior during the simulation integer :: NTSTEP_BETWEEN_OUTPUT_INFO + ! saves mesh files for visualization + logical :: SAVE_MESH_FILES = .false. + ! for later check of the grid - logical :: output_grid_Gnuplot,output_grid_ASCII + logical :: output_grid_Gnuplot = .false. + logical :: output_grid_ASCII = .false. ! for plotting the curve of energy logical :: OUTPUT_ENERGY diff --git a/src/specfem2D/check_grid.F90 b/src/specfem2D/check_grid.F90 index 9f030acd5..a028257e7 100644 --- a/src/specfem2D/check_grid.F90 +++ b/src/specfem2D/check_grid.F90 @@ -37,7 +37,7 @@ subroutine check_grid() use constants, only: IMAIN,HUGEVAL,TINYVAL,ZERO,myrank ! vtk output - use constants, only: SAVE_MESHFILES_VTK_FORMAT,OUTPUT_FILES + use constants, only: OUTPUT_FILES use specfem_par use specfem_par_movie @@ -111,7 +111,7 @@ subroutine check_grid() endif ! for VTK file output - if (SAVE_MESHFILES_VTK_FORMAT) then + if (SAVE_MESH_FILES) then allocate(tmp_store1(nspec), & tmp_store2(nspec), & xstore(nglob), & @@ -342,7 +342,7 @@ subroutine check_grid() pmax = max(pmax,p_elem) ! store for VTK file output - if (SAVE_MESHFILES_VTK_FORMAT) then + if (SAVE_MESH_FILES) then tmp_store1(ispec) = p_elem endif @@ -359,7 +359,7 @@ subroutine check_grid() dt_suggested = min(dt_suggested,dt_elem) ! store for VTK file output - if (SAVE_MESHFILES_VTK_FORMAT) then + if (SAVE_MESH_FILES) then tmp_store2(ispec) = dt_elem endif @@ -582,7 +582,7 @@ subroutine check_grid() endif ! VTK file output for visualization - if (SAVE_MESHFILES_VTK_FORMAT) then + if (SAVE_MESH_FILES) then if (myrank == 0) then write(IMAIN,*) 'mesh resolution output files:' endif @@ -813,22 +813,35 @@ subroutine check_grid_create_histogram(any_fluid_histo_glob,lambdaPmin_in_fluid_ scaling_factor = max_nb_of_points_per_wavelength - min_nb_of_points_per_wavelength if (ipass == 1) then - open(unit=14,file=trim(OUTPUT_FILES)//'points_per_wavelength_histogram_S_in_solid.txt',status='unknown') scaling_factor_S = scaling_factor + ! file output + if (SAVE_MESH_FILES) then + open(unit=14,file=trim(OUTPUT_FILES)//'points_per_wavelength_histogram_S_in_solid.txt',status='unknown') + endif else - open(unit=14,file=trim(OUTPUT_FILES)//'points_per_wavelength_histogram_P_in_fluid.txt',status='unknown') scaling_factor_P = scaling_factor + ! file output + if (SAVE_MESH_FILES) then + open(unit=14,file=trim(OUTPUT_FILES)//'points_per_wavelength_histogram_P_in_fluid.txt',status='unknown') + endif endif + do iclass = 0,NCLASSES-1 current_percent = 100.*dble(classes_wavelength_all(iclass))/dble(nspec_counted_all) total_percent = total_percent + current_percent + ! user output write(IMAIN,*) sngl(min_nb_of_points_per_wavelength + scaling_factor*iclass/dble(NCLASSES)),' - ', & sngl(min_nb_of_points_per_wavelength + scaling_factor*(iclass+1)/dble(NCLASSES)),classes_wavelength_all(iclass), & ' ',sngl(current_percent),' %' - write(14,*) 0.5*(sngl(min_nb_of_points_per_wavelength + scaling_factor*iclass/dble(NCLASSES)) + & - sngl(min_nb_of_points_per_wavelength + scaling_factor*(iclass+1)/dble(NCLASSES))),' ',sngl(current_percent) + ! file output + if (SAVE_MESH_FILES) then + write(14,*) 0.5*(sngl(min_nb_of_points_per_wavelength + scaling_factor*iclass/dble(NCLASSES)) + & + sngl(min_nb_of_points_per_wavelength + scaling_factor*(iclass+1)/dble(NCLASSES))),' ',sngl(current_percent) + endif enddo - close(14) + + ! file output + if (SAVE_MESH_FILES) close(14) if (total_percent < 99.9d0 .or. total_percent > 100.1d0) then write(IMAIN,*) 'total percentage = ',total_percent,' %' @@ -843,45 +856,44 @@ subroutine check_grid_create_histogram(any_fluid_histo_glob,lambdaPmin_in_fluid_ enddo ! end of the two passes on S wavelength data and P wavelength data ! create script for Gnuplot histogram file - if (myrank == 0) then - - open(unit=14,file=trim(OUTPUT_FILES)//'plot_points_per_wavelength_histogram.gnu',status='unknown') - write(14,*) 'set term wxt' - - if (nspec_counted_all_solid > 0) then - write(14,*) '#set term gif' - write(14,*) '#set output "points_per_wavelength_histogram_S_in_solid.gif"' - write(14,*) - write(14,*) 'set boxwidth ',real(scaling_factor_S/NCLASSES) - write(14,*) 'set xlabel "Range of min number of points per S wavelength in solid"' - write(14,*) 'set ylabel "Percentage of elements (%)"' - write(14,*) 'set loadpath "'//trim(OUTPUT_FILES)//'"' - write(14,*) 'plot "points_per_wavelength_histogram_S_in_solid.txt" with boxes' - write(14,*) 'pause -1 "hit any key..."' - endif - - if (nspec_counted_all_fluid > 0) then - write(14,*) '#set term gif' - write(14,*) '#set output "points_per_wavelength_histogram_P_in_fluid.gif"' - write(14,*) - write(14,*) 'set boxwidth ',real(scaling_factor_P/NCLASSES) - write(14,*) 'set xlabel "Range of min number of points per P wavelength in fluid"' - write(14,*) 'set ylabel "Percentage of elements (%)"' - write(14,*) 'set loadpath "'//trim(OUTPUT_FILES)//'"' - write(14,*) 'plot "points_per_wavelength_histogram_P_in_fluid.txt" with boxes' - write(14,*) 'pause -1 "hit any key..."' - endif - - close(14) + if (SAVE_MESH_FILES) then + if (myrank == 0) then + open(unit=14,file=trim(OUTPUT_FILES)//'plot_points_per_wavelength_histogram.gnu',status='unknown') + write(14,*) 'set term wxt' + if (nspec_counted_all_solid > 0) then + write(14,*) '#set term gif' + write(14,*) '#set output "points_per_wavelength_histogram_S_in_solid.gif"' + write(14,*) + write(14,*) 'set boxwidth ',real(scaling_factor_S/NCLASSES) + write(14,*) 'set xlabel "Range of min number of points per S wavelength in solid"' + write(14,*) 'set ylabel "Percentage of elements (%)"' + write(14,*) 'set loadpath "'//trim(OUTPUT_FILES)//'"' + write(14,*) 'plot "points_per_wavelength_histogram_S_in_solid.txt" with boxes' + write(14,*) 'pause -1 "hit any key..."' + endif + if (nspec_counted_all_fluid > 0) then + write(14,*) '#set term gif' + write(14,*) '#set output "points_per_wavelength_histogram_P_in_fluid.gif"' + write(14,*) + write(14,*) 'set boxwidth ',real(scaling_factor_P/NCLASSES) + write(14,*) 'set xlabel "Range of min number of points per P wavelength in fluid"' + write(14,*) 'set ylabel "Percentage of elements (%)"' + write(14,*) 'set loadpath "'//trim(OUTPUT_FILES)//'"' + write(14,*) 'plot "points_per_wavelength_histogram_P_in_fluid.txt" with boxes' + write(14,*) 'pause -1 "hit any key..."' + endif + close(14) + endif ! of if myrank == 0 + endif + ! user output + if (myrank == 0) then write(IMAIN,*) write(IMAIN,*) write(IMAIN,*) 'total number of elements in fluid and solid regions = ',nspec_all write(IMAIN,*) call flush_IMAIN() - - endif ! of if myrank == 0 - + endif end subroutine check_grid_create_histogram diff --git a/src/specfem2D/compute_coupling_acoustic_el.f90 b/src/specfem2D/compute_coupling_acoustic_el.f90 index ca9b8d586..cd6b4271b 100644 --- a/src/specfem2D/compute_coupling_acoustic_el.f90 +++ b/src/specfem2D/compute_coupling_acoustic_el.f90 @@ -191,12 +191,12 @@ subroutine compute_coupling_acoustic_el() endif if (iedge_acoustic == ITOP) then - xxi = + gammaz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zxi = - gammax(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xxi**2 + zxi**2) nx = - zxi / jacobian1D nz = + xxi / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then weight = jacobian1D * wxglj(i) * r_xiplus1(i,j) @@ -208,12 +208,12 @@ subroutine compute_coupling_acoustic_el() endif else if (iedge_acoustic == IBOTTOM) then - xxi = + gammaz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zxi = - gammax(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xxi**2 + zxi**2) nx = + zxi / jacobian1D nz = - xxi / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then weight = jacobian1D * wxglj(i) * r_xiplus1(i,j) @@ -225,12 +225,12 @@ subroutine compute_coupling_acoustic_el() endif else if (iedge_acoustic == ILEFT) then - xgamma = - xiz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zgamma = + xix(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xgamma**2 + zgamma**2) nx = - zgamma / jacobian1D nz = + xgamma / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then call stop_the_code('error: rotated element detected on the symmetry axis, this should not happen') @@ -242,12 +242,12 @@ subroutine compute_coupling_acoustic_el() endif else if (iedge_acoustic == IRIGHT) then - xgamma = - xiz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zgamma = + xix(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xgamma**2 + zgamma**2) nx = + zgamma / jacobian1D nz = - xgamma / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then call stop_the_code('error: rotated element detected on the symmetry axis, this should not happen') @@ -257,16 +257,15 @@ subroutine compute_coupling_acoustic_el() else weight = jacobian1D * wzgll(j) endif - endif ! compute dot product - displ_n = displ_x*nx + displ_z*nz + displ_n = displ_x * nx + displ_z * nz !! DK DK QUENTIN visco begin ici comme tu disais il faudrait coupler la composante tangentielle !! DK DK QUENTIN en plus de la composante normale je suppose if (.not. iglob_is_forced(iglob)) then - potential_dot_dot_acoustic(iglob) = potential_dot_dot_acoustic(iglob) + weight*displ_n + potential_dot_dot_acoustic(iglob) = potential_dot_dot_acoustic(iglob) + weight * displ_n if (ATTENUATION_VISCOACOUSTIC .and. .not. USE_A_STRONG_FORMULATION_FOR_E1 ) & dot_e1(iglob,:) = dot_e1(iglob,:) + weight*displ_n diff --git a/src/specfem2D/compute_coupling_viscoelastic_ac.f90 b/src/specfem2D/compute_coupling_viscoelastic_ac.f90 index cb067b630..c425a8b84 100644 --- a/src/specfem2D/compute_coupling_viscoelastic_ac.f90 +++ b/src/specfem2D/compute_coupling_viscoelastic_ac.f90 @@ -174,6 +174,7 @@ subroutine compute_coupling_viscoelastic_ac() jacobian1D = sqrt(xxi**2 + zxi**2) nx = - zxi / jacobian1D nz = + xxi / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then weight = jacobian1D * wxglj(i) * r_xiplus1(i,j) @@ -190,6 +191,7 @@ subroutine compute_coupling_viscoelastic_ac() jacobian1D = sqrt(xxi**2 + zxi**2) nx = + zxi / jacobian1D nz = - xxi / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then weight = jacobian1D * wxglj(i) * r_xiplus1(i,j) @@ -206,6 +208,7 @@ subroutine compute_coupling_viscoelastic_ac() jacobian1D = sqrt(xgamma**2 + zgamma**2) nx = - zgamma / jacobian1D nz = + xgamma / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then call stop_the_code('error: rotated element detected on the symmetry axis, this should not happen') @@ -222,6 +225,7 @@ subroutine compute_coupling_viscoelastic_ac() jacobian1D = sqrt(xgamma**2 + zgamma**2) nx = + zgamma / jacobian1D nz = - xgamma / jacobian1D + if (AXISYM) then if (is_on_the_axis(ispec_acoustic)) then call stop_the_code('error: rotated element detected on the symmetry axis, this should not happen') diff --git a/src/specfem2D/locate_receivers.F90 b/src/specfem2D/locate_receivers.F90 index 65ff02380..cfa35ed0f 100644 --- a/src/specfem2D/locate_receivers.F90 +++ b/src/specfem2D/locate_receivers.F90 @@ -52,7 +52,7 @@ subroutine locate_receivers(ibool,coord,nspec,nglob,xigll,zigll, & use specfem_par, only: AXISYM,is_on_the_axis,xiglj - use specfem_par, only: USE_TRICK_FOR_BETTER_PRESSURE,NUMBER_OF_SIMULTANEOUS_RUNS,SU_FORMAT + use specfem_par, only: USE_TRICK_FOR_BETTER_PRESSURE,NUMBER_OF_SIMULTANEOUS_RUNS,SU_FORMAT,SAVE_MESH_FILES implicit none @@ -467,7 +467,7 @@ subroutine locate_receivers(ibool,coord,nspec,nglob,xigll,zigll, & if (irec == 2) then write(IMAIN,*) write(IMAIN,*) ".. skipping station outputs .." - write(IMAIN,*) "(see output_list_stations.txt for full list)" + if (SAVE_MESH_FILES) write(IMAIN,*) "(see output_list_stations.txt for full list)" write(IMAIN,*) endif show_station_output = .false. @@ -510,15 +510,17 @@ subroutine locate_receivers(ibool,coord,nspec,nglob,xigll,zigll, & write(IMAIN,*) 'maximum error in location of all the receivers: ',sngl(final_distance_max),' m' ! write the locations of stations, so that we can load them and write them to SU headers later - open(unit=IOUT,file=trim(OUTPUT_FILES)//'/output_list_stations.txt',status='unknown',action='write',iostat=ier) - if (ier /= 0) & - call exit_mpi(myrank,'error opening file '//trim(OUTPUT_FILES)//'/output_list_stations.txt') - ! writes station infos - do irec = 1,nrec - write(IOUT,'(a32,a8,2f24.12)') station_name(irec),network_name(irec),st_xval(irec),st_zval(irec) - enddo - ! closes output file - close(IOUT) + if (SAVE_MESH_FILES) then + open(unit=IOUT,file=trim(OUTPUT_FILES)//'/output_list_stations.txt',status='unknown',action='write',iostat=ier) + if (ier /= 0) & + call exit_mpi(myrank,'error opening file '//trim(OUTPUT_FILES)//'/output_list_stations.txt') + ! writes station infos + do irec = 1,nrec + write(IOUT,'(a32,a8,2f24.12)') station_name(irec),network_name(irec),st_xval(irec),st_zval(irec) + enddo + ! closes output file + close(IOUT) + endif write(IMAIN,*) write(IMAIN,*) 'end of receiver detection' diff --git a/src/specfem2D/noise_tomography.f90 b/src/specfem2D/noise_tomography.f90 index d61c4576f..9cd06ab50 100644 --- a/src/specfem2D/noise_tomography.f90 +++ b/src/specfem2D/noise_tomography.f90 @@ -389,9 +389,9 @@ subroutine compute_arrays_source_noise() ! ! ---------------------------------------------------------------------------------- - use constants, only: CUSTOM_REAL,NGLLX,NGLLZ,NGLJ,IIN,IOUT,IMAIN,OUTPUT_FILES,PRINT_SOURCE_TIME_FUNCTION + use constants, only: CUSTOM_REAL,NGLLX,NGLLZ,NGLJ,IIN,IOUT,IMAIN,OUTPUT_FILES - use shared_parameters, only: noise_source_time_function_type + use shared_parameters, only: noise_source_time_function_type,PRINT_SOURCE_TIME_FUNCTION use specfem_par, only: AXISYM,is_on_the_axis,xiglj,P_SV,NSTEP,DT, & xigll,zigll,myrank diff --git a/src/specfem2D/prepare_gpu.f90 b/src/specfem2D/prepare_gpu.f90 index 502c4cd38..91b8b1b0b 100644 --- a/src/specfem2D/prepare_gpu.f90 +++ b/src/specfem2D/prepare_gpu.f90 @@ -370,11 +370,13 @@ subroutine init_host_to_dev_variable() implicit none ! local parameters - integer :: i_spec_free,ipoint1D,i,j,ispec,i_source,i_source_local,ispec_PML,ielem + integer :: i_spec_free,ispec,i_source,i_source_local,ispec_PML,ielem + integer :: i,j,ii,jj,ipoin1D integer :: ispec_acoustic,ispec_elastic,iedge_acoustic,iedge_elastic integer :: inum,ier real(kind=CUSTOM_REAL) :: zxi,xgamma,jacobian1D real(kind=CUSTOM_REAL) :: xxi,zgamma + real(kind=CUSTOM_REAL) :: nx,nz,weight double precision :: kappa_x,kappa_z,d_x,d_z,alpha_x,alpha_z,beta_x,beta_z !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! @@ -605,70 +607,89 @@ subroutine init_host_to_dev_variable() write(IMAIN,*) ' number of coupled fluid-solid edges = ',num_fluid_solid_edges call flush_IMAIN() endif - allocate(coupling_ac_el_ispec(num_fluid_solid_edges)) - allocate(coupling_ac_el_ij(2,NGLLX,num_fluid_solid_edges)) - allocate(coupling_ac_el_normal(2,NGLLX,num_fluid_solid_edges)) - allocate(coupling_ac_el_jacobian1Dw(NGLLX,num_fluid_solid_edges)) - coupling_ac_el_ispec(:) = 0 - coupling_ac_el_ij(:,:,:) = 0 + allocate(coupling_ac_el_ispec(2,num_fluid_solid_edges), & + coupling_ac_el_ij(2,2,NGLLX,num_fluid_solid_edges), & + coupling_ac_el_normal(2,NGLLX,num_fluid_solid_edges), & + coupling_ac_el_jacobian1Dw(NGLLX,num_fluid_solid_edges),stat=ier) + if (ier /= 0) stop 'Error allocating coupling_ac_el arrays' + coupling_ac_el_ispec(:,:) = 0 + coupling_ac_el_ij(:,:,:,:) = 0 coupling_ac_el_normal(:,:,:) = 0.0_CUSTOM_REAL coupling_ac_el_jacobian1Dw(:,:) = 0.00_CUSTOM_REAL + + ! loop on all the coupling edges do inum = 1,num_fluid_solid_edges ! get the edge of the acoustic element ispec_acoustic = fluid_solid_acoustic_ispec(inum) iedge_acoustic = fluid_solid_acoustic_iedge(inum) - coupling_ac_el_ispec(inum) = ispec_acoustic - ! get the corresponding edge of the elastic element ispec_elastic = fluid_solid_elastic_ispec(inum) iedge_elastic = fluid_solid_elastic_iedge(inum) + ! note: we store both, the acoustic and elastic element for the GPU routine + ! since PML coupling will require the local offset of the acoustic and elastic element + coupling_ac_el_ispec(1,inum) = ispec_acoustic + coupling_ac_el_ispec(2,inum) = ispec_elastic + ! implement 1D coupling along the edge - do ipoint1D = 1,NGLLX + do ipoin1D = 1,NGLLX + ! get point values for the acoustic side + i = ivalue(ipoin1D,iedge_acoustic) + j = jvalue(ipoin1D,iedge_acoustic) + + ! stores acoustic element (*,1,igll) + ! (needed for accessing acoustic side in elastic_ac coupling w/ PML) + coupling_ac_el_ij(1,1,ipoin1D,inum) = i + coupling_ac_el_ij(2,1,ipoin1D,inum) = j + ! get point values for the elastic side, which matches our side in the inverse direction - i = ivalue(ipoint1D,iedge_acoustic) - j = jvalue(ipoint1D,iedge_acoustic) - - coupling_ac_el_ij(1,ipoint1D,inum) = i - coupling_ac_el_ij(2,ipoint1D,inum) = j + ii = ivalue_inverse(ipoin1D,iedge_elastic) + jj = jvalue_inverse(ipoin1D,iedge_elastic) + + ! stores elastic element (*,2,igll) + ! (needed for accessing elastic side in acoustic_el coupling w/ PML) + coupling_ac_el_ij(1,2,ipoin1D,inum) = ii + coupling_ac_el_ij(2,2,ipoin1D,inum) = jj + ! determines normal and jacobian weights on interface (using acoustic element) if (iedge_acoustic == ITOP) then xxi = + gammaz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zxi = - gammax(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xxi**2 + zxi**2) - - coupling_ac_el_normal(1,ipoint1D,inum) = - zxi / jacobian1D - coupling_ac_el_normal(2,ipoint1D,inum) = + xxi / jacobian1D - coupling_ac_el_jacobian1Dw(ipoint1D,inum) = jacobian1D * wxgll(i) + nx = - zxi / jacobian1D + nz = + xxi / jacobian1D + weight = jacobian1D * wxgll(i) else if (iedge_acoustic == IBOTTOM) then xxi = + gammaz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zxi = - gammax(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xxi**2 + zxi**2) - - coupling_ac_el_normal(1,ipoint1D,inum) = + zxi / jacobian1D - coupling_ac_el_normal(2,ipoint1D,inum) = - xxi / jacobian1D - coupling_ac_el_jacobian1Dw(ipoint1D,inum) = jacobian1D * wxgll(i) + nx = + zxi / jacobian1D + nz = - xxi / jacobian1D + weight = jacobian1D * wxgll(i) else if (iedge_acoustic == ILEFT) then xgamma = - xiz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zgamma = + xix(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xgamma**2 + zgamma**2) - - coupling_ac_el_normal(1,ipoint1D,inum) = - zgamma / jacobian1D - coupling_ac_el_normal(2,ipoint1D,inum) = + xgamma / jacobian1D - coupling_ac_el_jacobian1Dw(ipoint1D,inum) = jacobian1D * wzgll(j) + nx = - zgamma / jacobian1D + nz = + xgamma / jacobian1D + weight = jacobian1D * wzgll(j) else if (iedge_acoustic == IRIGHT) then xgamma = - xiz(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) zgamma = + xix(i,j,ispec_acoustic) * jacobian(i,j,ispec_acoustic) jacobian1D = sqrt(xgamma**2 + zgamma**2) - - coupling_ac_el_normal(1,ipoint1D,inum) = + zgamma / jacobian1D - coupling_ac_el_normal(2,ipoint1D,inum) = - xgamma / jacobian1D - coupling_ac_el_jacobian1Dw(ipoint1D,inum) = jacobian1D * wzgll(j) + nx = + zgamma / jacobian1D + nz = - xgamma / jacobian1D + weight = jacobian1D * wzgll(j) endif + + ! stores for GPU + coupling_ac_el_normal(1,ipoin1D,inum) = nx + coupling_ac_el_normal(2,ipoin1D,inum) = nz + coupling_ac_el_jacobian1Dw(ipoin1D,inum) = weight enddo enddo diff --git a/src/specfem2D/prepare_source_time_function.f90 b/src/specfem2D/prepare_source_time_function.f90 index 88430a878..0f53de4c7 100644 --- a/src/specfem2D/prepare_source_time_function.f90 +++ b/src/specfem2D/prepare_source_time_function.f90 @@ -36,14 +36,14 @@ subroutine prepare_source_time_function() ! prepares source_time_function array use constants, only: CUSTOM_REAL,IMAIN,ZERO,ONE,TWO,HALF,PI,QUARTER, & - SOURCE_DECAY_MIMIC_TRIANGLE,PRINT_SOURCE_TIME_FUNCTION, & + SOURCE_DECAY_MIMIC_TRIANGLE, & C_LDDRK,C_RK4,ALPHA_SYMPLECTIC use specfem_par, only: NSTEP, NSOURCES, source_time_function, & time_function_type, burst_band_width, f0_source,tshift_src, & factor, t0, DT, SOURCE_IS_MOVING, & time_stepping_scheme, NSTAGE_TIME_SCHEME, islice_selected_source, & - USE_TRICK_FOR_BETTER_PRESSURE, myrank, initialfield + USE_TRICK_FOR_BETTER_PRESSURE, myrank, initialfield, PRINT_SOURCE_TIME_FUNCTION implicit none diff --git a/src/specfem2D/setup_mesh.F90 b/src/specfem2D/setup_mesh.F90 index 91f284e1e..7bc7c74ee 100644 --- a/src/specfem2D/setup_mesh.F90 +++ b/src/specfem2D/setup_mesh.F90 @@ -313,22 +313,25 @@ subroutine setup_mesh_properties() write(IMAIN,*) endif - ! saves the grid of points in a file - if (output_grid_ASCII .and. myrank == 0) then - write(IMAIN,*) - write(IMAIN,*) 'Saving the grid in an ASCII text file...' - write(IMAIN,*) - open(unit=55,file=trim(OUTPUT_FILES)//'ASCII_dump_of_grid_points.txt',status='unknown') - write(55,*) nglob - do n = 1,nglob - write(55,*) (coord(i,n), i = 1,NDIM) - enddo - close(55) - endif + ! mesh file output for visualization + if (SAVE_MESH_FILES) then + ! saves the grid of points in a file + if (output_grid_ASCII .and. myrank == 0) then + write(IMAIN,*) + write(IMAIN,*) 'Saving the grid in an ASCII text file...' + write(IMAIN,*) + open(unit=55,file=trim(OUTPUT_FILES)//'ASCII_dump_of_grid_points.txt',status='unknown') + write(55,*) nglob + do n = 1,nglob + write(55,*) (coord(i,n), i = 1,NDIM) + enddo + close(55) + endif - ! plots the GLL mesh in a Gnuplot file - if (output_grid_Gnuplot .and. myrank == 0) then - call plot_gll() + ! plots the GLL mesh in a Gnuplot file + if (output_grid_Gnuplot .and. myrank == 0) then + call plot_gll() + endif endif ! synchronizes all processes @@ -552,7 +555,7 @@ subroutine setup_mesh_material_properties() use constants, only: IMAIN,FOUR_THIRDS,TWO_THIRDS,HUGEVAL ! vtk output - use constants, only: SAVE_MESHFILES_VTK_FORMAT,OUTPUT_FILES + use constants, only: OUTPUT_FILES use specfem_par @@ -1222,7 +1225,7 @@ subroutine setup_mesh_material_properties() endif ! VTK output - if (SAVE_MESHFILES_VTK_FORMAT) then + if (SAVE_MESH_FILES) then allocate(tmp_store(NGLLX,NGLLZ,nspec), & xstore(nglob), & zstore(nglob),stat=ier) diff --git a/src/specfem2D/specfem2D_par.f90 b/src/specfem2D/specfem2D_par.f90 index 0bb13ad5f..ecefa0fab 100644 --- a/src/specfem2D/specfem2D_par.f90 +++ b/src/specfem2D/specfem2D_par.f90 @@ -856,8 +856,8 @@ module specfem_par_gpu real(kind=CUSTOM_REAL), dimension(:,:), allocatable :: source_time_function_loc ! coupling - integer, dimension(:), allocatable :: coupling_ac_el_ispec - integer, dimension(:,:,:), allocatable :: coupling_ac_el_ij + integer, dimension(:,:), allocatable :: coupling_ac_el_ispec + integer, dimension(:,:,:,:), allocatable :: coupling_ac_el_ij real(kind=CUSTOM_REAL), dimension(:,:,:), allocatable :: coupling_ac_el_normal real(kind=CUSTOM_REAL), dimension(:,:), allocatable :: coupling_ac_el_jacobian1Dw diff --git a/utils/CPML/Par_file_to_use_with_this_timing_routine_HOWTO b/utils/CPML/Par_file_to_use_with_this_timing_routine_HOWTO index 73f6c0658..bc5b63fe1 100644 --- a/utils/CPML/Par_file_to_use_with_this_timing_routine_HOWTO +++ b/utils/CPML/Par_file_to_use_with_this_timing_routine_HOWTO @@ -142,6 +142,9 @@ noise_source_time_function_type = 4 # This is only useful for GPU version (for now) write_moving_sources_database = .false. +# print source time function +PRINT_SOURCE_TIME_FUNCTION = .true. + #----------------------------------------------------------- # # Receivers @@ -321,6 +324,9 @@ nbregions = 1 # then set below the different # (every how many time steps we display information about the simulation. costly, do not use a very small value) NTSTEP_BETWEEN_OUTPUT_INFO = 500 +# save mesh files (VTK, ASCII or Gnuplot) to check the mesh +SAVE_MESH_FILES = .true. + # meshing output output_grid_Gnuplot = .false. # generate a GNUPLOT file containing the grid, and a script to plot it output_grid_ASCII = .false. # dump the grid in an ASCII text file consisting of a set of X,Y,Z points or not diff --git a/utils/cubit2specfem2d/run_cubit_to_specfem.py b/utils/cubit2specfem2d/run_cubit_to_specfem.py index 42909f6e9..90a593b20 100755 --- a/utils/cubit2specfem2d/run_cubit_to_specfem.py +++ b/utils/cubit2specfem2d/run_cubit_to_specfem.py @@ -33,7 +33,7 @@ # adds path to scripts (if not setup yet) sys.path.append('../../utils/cubit2specfem2d/') -## This is boundary_definition.py +## This is boundary_definition.py # extracts the bounding edges and defines them into blocks import boundary_definition @@ -45,7 +45,7 @@ ## Define material properties for model cubit.cmd('#### DEFINE MATERIAL PROPERTIES #######################') -#cubit.cmd('set duplicate block elements on') # allow for multiple occurrences of entities in different blocks +#cubit.cmd('set duplicate block elements on') # allow for multiple occurrences of entities in different blocks cubit.cmd('block 1 face in volume all') cubit.cmd('block 1 element type QUAD4') diff --git a/utils/scripts/clean_listings_specfem.py b/utils/scripts/clean_listings_specfem.py index b7e201413..87658f086 100755 --- a/utils/scripts/clean_listings_specfem.py +++ b/utils/scripts/clean_listings_specfem.py @@ -27,7 +27,7 @@ fortran_file_extensions = ['.fh', '.f90', '.F90', '.fh.in'] # Define the list of file extensions to be processed as general formatting -general_file_extensions = ['.bash', '.c', '.cpp','.csh','.cu','.h','.h.in','.pl','.tex','.txt','.sh','.rb', '.md', '.log'] +general_file_extensions = ['.bash','.c','.cpp','.csh','.cu','.h','.h.in','.pl','.py','.tex','.txt','.sh','.rb','.md','.log'] # Define the list of directories to be excluded (these are mostly submodules included in the source repositories) exclude_dirs = ['.git', 'm4', './utils/ADJOINT_TOMOGRAPHY_TOOLS/flexwin', './src/inverse_problem_for_source/pyCMT3D'] @@ -150,7 +150,7 @@ (r'restaure', 'restore'), (r'memmory', 'memory'), (r'convolution formation', 'convolution formulation'), - (r'fortran', 'Fortran'), + (r' fortran', ' Fortran'), (r'adress', 'address'), (r'gFortran', 'gfortran'), (r' usefull ', ' useful '),