# Comparing ray and FD seismograms in 2-D model UNCONFORMITY
# ==========================================================
# Input files required
 #chk.pl: "data/u2d/" "u2d-mod.dat"
 #chk.pl: "data/u2d/" "u2d-crt.dat"
 #chk.pl: "data/u2d/" "u2d-rpa.dat"
 #chk.pl: "data/u2d/" "u2d-wri.dat"
 #chk.pl: "data/u2d/" "u2d-src.dat"
 #chk.pl: "data/u2d/" "u2d-rec.dat"
 #chk.pl: "data/u2d/" "u2d-hil.dat"
 #chk.pl: "forms/"    "calcops.rgb"
 #chk.pl: "crt/"      "sourcex.dat"

# Model UNCONFORMITY (Cormier and Mellen 1984)
  MODEL='u2d-mod.dat'

# Source and receivers
  SRC='u2d-src.dat'  REC='u2d-rec.dat'
  SOURCE='sourcex.dat' # explosive source

# Source time function (line source)
  KSIG=3   SIGW=2  # Kuepper signal with 2 local maxima
  SIGF=10.         # reference frequency
  SIGA=1.          # maximum amplitude
  DER=0.5          # halfth derivative for the point source

# Data to control seismogram plotting (program SP)
  KODESP=3  SPCHRH=0.23
  SPTMIN=0.300  SPTMAX=1.000   SPTLEN=11.20  SPTDIV=7  SPTSUB=1
  SPXMIN=0.136  SPXMAX=-1.241  SPXLEN=13.77  SPXDIV=9  SPXSUB=3
  NORMSP=1  SPAMP=-15.00  # amplitude scaling for point source in 3-D
  SPHILI='u2d-hil.dat'  SPHIWI=0.51

# Hypocentral distance where the point and line sources have comparable
# amplitudes (for amplitude power scaling roughly converting line
# source to point source)
  SPDIST=0.07472   # SPDIST=1/(2*pi*VP), VP=2.13

# Ray synthetic seismograms (point source)
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Data for ray tracing
  DCRT='u2d-crt.dat'
  CODE='u2d-crt.dat'
  RPAR='u2d-rpa.dat'
  WRIT='u2d-wri.dat'
  CRTLOG='u2d-log.out'
  INIPAR=2  # ray parameters: geographic-like spherical coordinates

# No attenuation for comparison with FD
  TIMUL=0

# Data describing the filtration of the source time function
  FMIN=0.  FLOW=1.  FHIGH=55.  FMAX=60. # (cosine filter)

# Time step and time interval for the Fast Fourier Transform
  DT=0.001  NFFT=1024

# GSE file with synthetic seismograms
  SS='u2d-ss.gse'

# Data to control optional plotting of program SS
  SIGPLOT='u2d-sig.ps'  MPTS=640

# Programs to execute
  crt:     'u2d-fd.h' /       # two-point ray tracing
  green:   'u2d-fd.h' /       # Green function
  greenss: 'u2d-fd.h' /       # response function
  ss:      'u2d-fd.h' /       # synthetic seismograms

# FD synthetic seismograms (line source)
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Grid dimensions, FD time steps, snapshots
  N1=316     N3=646     NTFD=2501     N4=101
  D1=0.003   D3=-.003   DTFD=0.0004   D4=0.010
  O1=0.315   O3=0.786                 O4=0.000

# GSE file with synthetic seismograms
  SS='u2d-fd.gse'

# Form of files with effective elastic parameters and snapshots
  FORM='formatted'

# Files with snapshots (not generated by default)
 #SNAP1='u2d-fd1.out'
 #SNAP3='u2d-fd3.out'

# Files with effective elastic parameters
  A11='a11.out'  B11='b11.out'  C11='c11.out'
  A13='a13.out'  B13='b13.out'  C13='c13.out'
  A31='a31.out'  B31='b31.out'  C31='c31.out'
  A33='a33.out'  B33='b33.out'  C33='c33.out'
  DEN='den.out'

# Programs to execute
  modfd:   'u2d-fd.h' /         # gridded elastic parameters
  fd2d:    'u2d-fd.h' /         # FD synthetic seismograms

# FD synthetic seismograms on a larger grid to test boundary conditions
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Increasing the box by 20*D1=0.060 at all 4 sides
  N1=356     N3=686
  O1=0.255   O3=0.846

# GSE file with synthetic seismograms
  SS='u2d-fda.gse'

# No snapshots for this test
  SNAP1=' '  SNAP3=' '

# Programs to execute
 #modfd:   'u2d-fd.h' /         # gridded elastic parameters
 #fd2d:    'u2d-fd.h' /         # FD synthetic seismograms
# Do not forget to increase default value of MRAM in ram.inc!

# Plotting the seismograms
# ~~~~~~~~~~~~~~~~~~~~~~~~
  SS=' '
  SS='u2d-fd.gse'   KOLOR=4   SPOWER=-.5   # FD seismograms (blue)
 #SS1='u2d-fda.gse' KOLOR1=3  SPOWER1=-.5  # test FD seismograms (green)
  SS2='u2d-ss.gse'  KOLOR2=2  SPOWER2=0.0  # ray-theory seismograms (red)
  SP1='u2d-1.ps'  SP2=' '  SP3='u2d-3.ps'
  sp:      'u2d-fd.h' /         # seismogram plotting

