[cig-commits] [commit] devel, master: Make SAC type conversion explicit. (3a2cf6a)
cig_noreply at geodynamics.org
cig_noreply at geodynamics.org
Thu Nov 6 08:20:04 PST 2014
Repository : https://github.com/geodynamics/specfem3d_globe
On branches: devel,master
Link : https://github.com/geodynamics/specfem3d_globe/compare/bc58e579b3b0838a0968725a076f5904845437ca...be63f20cbb6f462104e949894dbe205d2398cd7f
>---------------------------------------------------------------
commit 3a2cf6a12481448435f38c28b459ba5bbb597a38
Author: Elliott Sales de Andrade <esalesde at physics.utoronto.ca>
Date: Sat May 31 04:24:49 2014 -0400
Make SAC type conversion explicit.
SAC uses 4-byte floats in its binary format.
>---------------------------------------------------------------
3a2cf6a12481448435f38c28b459ba5bbb597a38
src/specfem3D/write_output_SAC.f90 | 44 +++++++++++++++++++-------------------
1 file changed, 22 insertions(+), 22 deletions(-)
diff --git a/src/specfem3D/write_output_SAC.f90 b/src/specfem3D/write_output_SAC.f90
index 56a950d..f194085 100644
--- a/src/specfem3D/write_output_SAC.f90
+++ b/src/specfem3D/write_output_SAC.f90
@@ -155,7 +155,7 @@
INTERNAL = -12345.00 ! SAC internal variables, always left undefined
BYSAC = -12345.00 ! values calculated by SAC from other variables
!
- DELTA = DT ! [REQUIRED]
+ DELTA = sngl(DT) ! [REQUIRED]
DEPMIN = BYSAC
DEPMAX = BYSAC
DEPMEN = BYSAC
@@ -171,47 +171,47 @@
A = undef !###
!station values:
- STLA = stlat(irec)
- STLO = stlon(irec)
- STEL = stele(irec)
- STDP = stbur(irec)
+ STLA = sngl(stlat(irec))
+ STLO = sngl(stlon(irec))
+ STEL = sngl(stele(irec))
+ STDP = sngl(stbur(irec))
!event values (hypocenter):
! note: this writes out the CMT location, which might be different
! to the event location given in the first, PDE line
- EVLA = cmt_lat
- EVLO = cmt_lon
+ EVLA = sngl(cmt_lat)
+ EVLO = sngl(cmt_lon)
EVEL = undef !not defined
- EVDP = cmt_depth
+ EVDP = sngl(cmt_depth)
! by Ebru
! SAC headers will have new format
- USER0 = cmt_hdur !half duration from CMT file if not changed to t0=0.d0 (point source)
+ USER0 = sngl(cmt_hdur) !half duration from CMT file if not changed to t0=0.d0 (point source)
! USER1 and USER2 slots are used for the shortest and longest periods at which
! simulations are accurate, respectively.
shortest_period = (256/NEX_XI)*(ANGULAR_WIDTH_XI_IN_DEGREES/90)*17
- USER1 = shortest_period
+ USER1 = sngl(shortest_period)
USER2 = 500.0d0
USER3 = undef
USER4 = undef
! we remove any PDE information, since the simulation could also start
! with a "pure" CMT solution, without having any PDE info
!
- !USER1 = t_shift !time shift between PDE and CMT solutions
+ !USER1 = sngl(t_shift) !time shift between PDE and CMT solutions
!PDE location values (different from CMT location, usually):
- !USER2 = depth !PDE depth
- !USER3 = elat !PDE event latitude
- !USER4 = elon !PDE event longitude
+ !USER2 = sngl(depth) !PDE depth
+ !USER3 = sngl(elat) !PDE event latitude
+ !USER4 = sngl(elon) !PDE event longitude
!
!cmt location values (different from hypocenter location, usually):
- ! USER0 = cmt_lat
- ! USER1 = cmt_lon
- !USER0 = elat
- !USER1 = elon
- !USER2 = depth
- !USER3 = cmt_hdur !half duration from CMT if not changed to t0=0.d0 (point source)
+ ! USER0 = sngl(cmt_lat)
+ ! USER1 = sngl(cmt_lon)
+ !USER0 = sngl(elat)
+ !USER1 = sngl(elon)
+ !USER2 = sngl(depth)
+ !USER3 = sngl(cmt_hdur) !half duration from CMT if not changed to t0=0.d0 (point source)
! just to avoid compiler warning
value1 = elat
@@ -226,8 +226,8 @@
!
! it's confusing, and as a result, we will omit it.
! by Ebru
- MAG = undef
- IMAGTYP= undef
+ MAG = undef
+ IMAGTYP = int(undef)
!MAG = mb !
!IMAGTYP= 52 ! 52 = Mb? 55 = Mw!
More information about the CIG-COMMITS
mailing list