[cig-commits] r13338 - in seismo/2D/SPECFEM2D/branches/BIOT: . DATA

cmorency at geodynamics.org cmorency at geodynamics.org
Tue Nov 18 16:11:19 PST 2008


Author: cmorency
Date: 2008-11-18 16:11:18 -0800 (Tue, 18 Nov 2008)
New Revision: 13338

Modified:
   seismo/2D/SPECFEM2D/branches/BIOT/DATA/Par_file
   seismo/2D/SPECFEM2D/branches/BIOT/DATA/STATIONS
   seismo/2D/SPECFEM2D/branches/BIOT/meshfem2D.F90
   seismo/2D/SPECFEM2D/branches/BIOT/specfem2D.F90
Log:
Bug fixed - Unstructured meshes correctly read now - Thanks Hejun.


Modified: seismo/2D/SPECFEM2D/branches/BIOT/DATA/Par_file
===================================================================
--- seismo/2D/SPECFEM2D/branches/BIOT/DATA/Par_file	2008-11-18 23:56:37 UTC (rev 13337)
+++ seismo/2D/SPECFEM2D/branches/BIOT/DATA/Par_file	2008-11-19 00:11:18 UTC (rev 13338)
@@ -1,7 +1,7 @@
 
 # title of job, and file that contains interface data
-title                           = Forward calculation (P phase)
-interfacesfile                  = interfaces.dat
+title                           = Test for 2 layers: acoustic/poroelastic
+interfacesfile                  = interfaces_acoustic.dat
 
 # data concerning mesh, when generated using third-party app (more info in README)
 read_external_mesh              = .false.
@@ -18,8 +18,8 @@
                                                  
 # geometry of the model (origin lower-left corner = 0,0) and mesh description
 xmin                            = 0.d0           # abscissa of left side of the model
-xmax                            = 800.d0        # abscissa of right side of the model
-nx                              = 100             # number of elements along X
+xmax                            = 4800.d0        # abscissa of right side of the model
+nx                              = 260             # number of elements along X
 ngnod                           = 9              # number of control nodes per element (4 or 9)
 initialfield                    = .false.        # use a plane wave as source or not
 add_Bielak_conditions           = .false.        # add Bielak conditions or not if initial plane wave
@@ -32,22 +32,22 @@
 absorbing_conditions            = .true.	 # absorbing boundary active or not
 absorbbottom                    = .true.
 absorbright                     = .true.
-absorbtop                       = .true.
+absorbtop                       = .false.
 absorbleft                      = .true.
 
 # time step parameters
-nt                              = 3000           # total number of time steps
-deltat                          = 2d-4         # duration of a time step
+nt                              = 5000           # total number of time steps
+deltat                          = 3d-4         # duration of a time step
 isolver                         = 1              # type of simulation 1=forward 2=adjoint + kernels
 
 # source parameters
 source_surf                     = .false.        # source inside the medium or at the surface
-xs                              = 300.          # source location x in meters
-zs                              = 400.          # source location z in meters
+xs                              = 1600.          # source location x in meters
+zs                              = 2900.          # source location z in meters
 source_type                     = 1              # elastic force or acoustic pressure = 1 or moment tensor = 2
 time_function_type              = 1              # Ricker = 1, first derivative = 2, Gaussian = 3, Dirac = 4, Heaviside = 5
-f0                              = 20.0           # dominant source frequency (Hz) if not Dirac or Heaviside
-angleforce                      = -90.             # angle of the source (for a force only)
+f0                              = 15.0           # dominant source frequency (Hz) if not Dirac or Heaviside
+angleforce                      = 0.             # angle of the source (for a force only)
 Mxx                             = 1.             # Mxx component (for a moment tensor source only)
 Mzz                             = 1.             # Mzz component (for a moment tensor source only)
 Mxz                             = 0.             # Mxz component (for a moment tensor source only)
@@ -60,24 +60,32 @@
 f0_attenuation                  = 5.196152422706633      # (Hz) relevant only if source is a Dirac or a Heaviside, else it is f0
 
 # receiver line parameters for seismograms
-seismotype                      = 1              # record 1=displ 2=veloc 3=accel 4=pressure
-save_forward                    = .true.        # save the last frame 
+seismotype                      = 4              # record 1=displ 2=veloc 3=accel 4=pressure
+save_forward                    = .false.        # save the last frame 
 generate_STATIONS               = .true.         # creates a STATION file in ./DATA
-nreceiverlines                  = 1              # number of receiver lines
+nreceiverlines                  = 2              # number of receiver lines
 anglerec                        = 0.d0           # angle to rotate components at receivers
 
 # first receiver line
 nrec                            = 1             # number of receivers
-xdeb                            = 500.           # first receiver x in meters
-zdeb                            = 400.          # first receiver z in meters
+xdeb                            = 2000.           # first receiver x in meters
+zdeb                            = 2933.33          # first receiver z in meters
 xfin                            = 3700.          # last receiver x in meters (ignored if onlyone receiver)
 zfin                            = 2200.          # last receiver z in meters (ignored if onlyone receiver)
 enreg_surf                      = .false.         # receivers inside the medium or at the surface
 
+# second receiver line
+nrec                            = 1             # number of receivers
+xdeb                            = 2000.           # first receiver x in meters
+zdeb                            = 1866.67          # first receiver z in meters
+xfin                            = 3777.          # last receiver x in meters (ignored if onlyone receiver)
+zfin                            = 1866.67          # last receiver z in meters (ignored if onlyone receiver)
+enreg_surf                      = .false.         # receivers inside the medium or at the surface
+
 # display parameters
-NTSTEP_BETWEEN_OUTPUT_INFO      = 400            # display frequency in time steps
-output_postscript_snapshot      = .false.         # output Postscript snapshot of the results
-output_color_image              = .true.         # output color image of the results
+NTSTEP_BETWEEN_OUTPUT_INFO      = 200            # display frequency in time steps
+output_postscript_snapshot      = .true.         # output Postscript snapshot of the results
+output_color_image              = .false.         # output color image of the results
 imagetype                       = 1              # display 1=displ 2=veloc 3=accel 4=pressure
 cutsnaps                        = 1.             # minimum amplitude in % for snapshots
 meshvect                        = .true.         # display mesh on vector plots or not
@@ -90,12 +98,14 @@
 gnuplot                         = .false.        # generate a GNUPLOT file for the grid
 outputgrid                      = .false.        # save the grid in a text file or not
 
-# models
-nbmodels                        = 1              # nb of different models
-# define models as (model_number,1,rho_s,rho_f,phi,tort,permxx,permxz,permzz,kappa_s,kappa_f,kappa_fr,mu_s,eta_f,mu_fr) or (Anisotropic: to be defined - in the code already, just need to modify the Par_file)
+# velocity and density models
+nbmodels                        = 2              # nb of different models
+# define models as (model_number,1,rho_s,rho_f,phi,tort,permx,permz,kappa_s,kappa_f,kappa_fr,mu_s,eta_f,mu_fr) or (Anisotropic: to be defined)
 # set the porosity phi to 1 to make a given model acoustic, and to 0 to make it elastic
 # the mesh can contain acoustic, elastic and poroelastic models simultaneously
-1 1 2650.d0 880.d0 1.0d0 2.0 1d-11 0.d0 1d-11 12.2d9 2.5d9 9.6d9 5.1d9 0.0d-3 5.1d9
+1 1 2500.d0 1020.d0 0.4d0 2.0 1d-11 0.d0 1d-11 1.60554d10 2.295d9 1.0d10 9.63342d9 0.0d-4 9.63342d9
+2 1 2650.d0 1020.d0 1.10d0 2.0 1d-11 0.d0 1d-11 1.60554d10 2.295d9 0.0d9 0.0d9 0.0d-3 0.0d9
 # define the different regions of the model in the (nx,nz) spectral element mesh
-nbregions                       = 1              # nb of regions and model number for each
-1 100 1 80 1
+nbregions                       = 2              # nb of regions and model number for each
+1 260 1 110 1
+1 260 111 220 2

Modified: seismo/2D/SPECFEM2D/branches/BIOT/DATA/STATIONS
===================================================================
--- seismo/2D/SPECFEM2D/branches/BIOT/DATA/STATIONS	2008-11-18 23:56:37 UTC (rev 13337)
+++ seismo/2D/SPECFEM2D/branches/BIOT/DATA/STATIONS	2008-11-19 00:11:18 UTC (rev 13338)
@@ -1 +1,2 @@
-S0001    AA          500.0000000          400.0000000       0.0         0.0
+S0001    AA         2000.0000000         2933.3300000       0.0         0.0
+S0002    AA         2000.0000000         1866.6700000       0.0         0.0

Modified: seismo/2D/SPECFEM2D/branches/BIOT/meshfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/branches/BIOT/meshfem2D.F90	2008-11-18 23:56:37 UTC (rev 13337)
+++ seismo/2D/SPECFEM2D/branches/BIOT/meshfem2D.F90	2008-11-19 00:11:18 UTC (rev 13338)
@@ -1232,8 +1232,8 @@
      write(15,*) 'nelemabs nelem_acoustic_surface num_fluid_solid_edges num_fluid_poro_edges num_solid_poro_edges'
      write(15,*) nelemabs_loc,nelem_acoustic_surface_loc,nedges_coupled_loc,nedges_acporo_coupled_loc,nedges_elporo_coupled_loc
 
-     write(15,*) 'nxread, nzread'
-     write(15,*) nxread,nzread
+!     write(15,*) 'nxread, nzread'
+!     write(15,*) nxread,nzread
 
      write(15,*) 'Material sets Isotropic (Anisotropic: to be defined)'
      do i=1,nb_materials

Modified: seismo/2D/SPECFEM2D/branches/BIOT/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/branches/BIOT/specfem2D.F90	2008-11-18 23:56:37 UTC (rev 13337)
+++ seismo/2D/SPECFEM2D/branches/BIOT/specfem2D.F90	2008-11-19 00:11:18 UTC (rev 13338)
@@ -253,7 +253,8 @@
   double precision :: cutsnaps,sizemax_arrows,anglerec,xirec,gammarec
 
 ! for absorbing and acoustic free surface conditions
-  integer :: ispec_acoustic_surface,inum,numabsread,nxread,nzread
+  integer :: ispec_acoustic_surface,inum,numabsread
+!,nxread,nzread
   logical :: codeabsread(4)
   real(kind=CUSTOM_REAL) :: nx,nz,weight,xxi,zgamma
 
@@ -645,8 +646,8 @@
   read(IIN,*) numat,ngnod,nspec,pointsdisp,plot_lowerleft_corner_only
   read(IIN,"(a80)") datlin
   read(IIN,*) nelemabs,nelem_acoustic_surface,num_fluid_solid_edges,num_fluid_poro_edges,num_solid_poro_edges
-  read(IIN,"(a80)") datlin
-  read(IIN,*) nxread,nzread
+!  read(IIN,"(a80)") datlin
+!  read(IIN,*) nxread,nzread
 !
 !---- allocate arrays
 !
@@ -689,25 +690,26 @@
   allocate(numabs(nelemabs))
   allocate(codeabs(4,nelemabs))
 
-  allocate(ibegin_bottom(nxread))
-  allocate(iend_bottom(nxread))
-  allocate(ibegin_top(nxread))
-  allocate(iend_top(nxread))
+!  allocate(ibegin_bottom(nxread))
+  allocate(ibegin_bottom(nelemabs))
+  allocate(iend_bottom(nelemabs))
+  allocate(ibegin_top(nelemabs))
+  allocate(iend_top(nelemabs))
 
-  allocate(jbegin_left(nzread))
-  allocate(jend_left(nzread))
-  allocate(jbegin_right(nzread))
-  allocate(jend_right(nzread))
+  allocate(jbegin_left(nelemabs))
+  allocate(jend_left(nelemabs))
+  allocate(jbegin_right(nelemabs))
+  allocate(jend_right(nelemabs))
 
-  allocate(ibegin_bottom_poro(nxread))
-  allocate(iend_bottom_poro(nxread))
-  allocate(ibegin_top_poro(nxread))
-  allocate(iend_top_poro(nxread))
+  allocate(ibegin_bottom_poro(nelemabs))
+  allocate(iend_bottom_poro(nelemabs))
+  allocate(ibegin_top_poro(nelemabs))
+  allocate(iend_top_poro(nelemabs))
 
-  allocate(jbegin_left_poro(nzread))
-  allocate(jend_left_poro(nzread))
-  allocate(jbegin_right_poro(nzread))
-  allocate(jend_right_poro(nzread))
+  allocate(jbegin_left_poro(nelemabs))
+  allocate(jend_left_poro(nelemabs))
+  allocate(jbegin_right_poro(nelemabs))
+  allocate(jend_right_poro(nelemabs))
 
 !
 !---- print element group main parameters
@@ -846,10 +848,10 @@
     nspec_xmax = ZERO
     nspec_zmin = ZERO
     nspec_zmax = ZERO
-    allocate(ib_xmin(nzread))
-    allocate(ib_xmax(nzread))
-    allocate(ib_zmin(nxread))
-    allocate(ib_zmax(nxread))
+    allocate(ib_xmin(nelemabs))
+    allocate(ib_xmax(nelemabs))
+    allocate(ib_zmin(nelemabs))
+    allocate(ib_zmax(nelemabs))
     do inum = 1,nelemabs
        if (codeabs(IBOTTOM,inum)) then
          nspec_zmin = nspec_zmin + 1



More information about the CIG-COMMITS mailing list