Skip to content

Commit

Permalink
Merge pull request #21 from IvanaEscobar/init_fixed
Browse files Browse the repository at this point in the history
Init fixed for SSP
  • Loading branch information
IvanaEscobar authored Sep 17, 2024
2 parents a94d6c1 + ea1f5a5 commit de6aa14
Show file tree
Hide file tree
Showing 77 changed files with 3,198 additions and 2,804 deletions.
21 changes: 11 additions & 10 deletions inc/IHOP.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
! IHOP parameters
! ===============
!-- COMMON /IHOP_PARAMS_L/ IHOP logical-type parameters:
! writeDelay :: true if delay is a desired output
! writeDelay :: true if delay is a desired output
! useSSPFile :: true if *.ssp is used instead MITgcm SSP

LOGICAL writeDelay
Expand All @@ -32,7 +32,7 @@

!-- COMMON /IHOP_PARAMS_C/ IHOP Character-type parameters:
! IHOP_fileroot :: File name for reading in an environment
! IHOP_title :: Title name for writing into output files
! IHOP_title :: Title name for writing into output files
! IHOP_interpfile :: File name for reading NetCDF inputs
! IHOP_topopt :: SSP interpolation, top boundary type
! IHOP_botopt :: bottom boundary type
Expand Down Expand Up @@ -77,10 +77,10 @@
! IHOP_dumpfreq :: frequency of output dump to run directory
! IHOP_freq :: frequency (Hz)
! IHOP_depth :: depth of bottom (m)
! IHOP_bcsound :: bottom sound speed (m/s)
! IHOP_bcsoundshear :: shear bottom sound speed (m/s)
! IHOP_bcsoundI :: IMAG bottom sound speed (m/s)
! IHOP_bcsoundshearI :: IMAG shear bottom sound speed (m/s)
! IHOP_bcsound :: bottom sound speed (m/s)
! IHOP_bcsoundshear :: shear bottom sound speed (m/s)
! IHOP_bcsoundI :: IMAG bottom sound speed (m/s)
! IHOP_bcsoundshearI :: IMAG shear bottom sound speed (m/s)
! IHOP_brho :: bottom density (kg/m^3)
! IHOP_sd :: source depth (m)
! IHOP_rd :: receiver depth (m)
Expand All @@ -92,9 +92,9 @@
_RL IHOP_freq
_RL IHOP_depth
_RL IHOP_bcsound
_RL IHOP_bcsoundshear
_RL IHOP_bcsoundshear
_RL IHOP_bcsoundI
_RL IHOP_bcsoundshearI
_RL IHOP_bcsoundshearI
_RL IHOP_brho
_RL IHOP_sd (nsd)
_RL IHOP_rd (nrd)
Expand All @@ -105,20 +105,21 @@
_RS ihop_xc ( IHOP_MAX_NC_SIZE, IHOP_MAX_NC_SIZE )
_RS ihop_yc ( IHOP_MAX_NC_SIZE, IHOP_MAX_NC_SIZE )
_RL ihop_ranges ( IHOP_MAX_NC_SIZE )
_RL ihop_sumweights ( IHOP_MAX_NC_SIZE, IHOP_MAX_NC_SIZE )

COMMON /IHOP_PARAMS_R/ &
& IHOP_dumpfreq, &
& IHOP_freq, IHOP_depth, IHOP_bcsound, IHOP_bcsoundshear, &
& ihop_brho, IHOP_bcsoundI, IHOP_bcsoundshearI, &
& IHOP_sd, IHOP_rd, IHOP_rr, IHOP_alpha, IHOP_step, &
& ihop_yc, ihop_xc, ihop_idw_weights, ihop_ranges
& ihop_yc, ihop_xc, ihop_idw_weights, ihop_ranges, ihop_sumweights


#ifdef IHOP_3D_STATE
!C IHOP 3-dim. fields
_RL ihop_ssp(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
COMMON /IHOP_STATE_3D/ &
& ihop_ssp
& ihop_ssp
#endif /* IHOP_3D_STATE */

#ifdef IHOP_2D_STATE
Expand Down
16 changes: 8 additions & 8 deletions inc/IHOP_COST.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

COMMON /ihop_cost_l/ ihopDoNcOutput

! IHOP cost integer parameters
! IHOP cost integer parameters
! ObsNo* :: No. of observations in a single ihop obs file, iOBS
! ihopObs_ind_glob* :: MITgcm global index of each obs datum

Expand All @@ -28,25 +28,25 @@
COMMON /ihop_cost_i/ &
& ObsNo, ObsNo_tiled, &
& ihopObs_ind_glob, ihopObs_ind_glob_tiled, &
& fidfwd_obs, fidadj_obs, fidglobal, fidadglobal,
& fidfwd_obs, fidadj_obs, fidglobal, fidadglobal,
& fiddata_obs, &
& ihopObs_i_tiled, ihopObs_j_tiled, ihopObs_k_tiled, &
& ihopObs_sample1_ind

! IHOP buffers
_RL ihop_data_buff(1000)
_RL ihop_uncert_buff(1000)
INTEGER ihop_minind_buff
INTEGER ihop_maxind_buff
INTEGER ihop_curfile_buff

COMMON /IHOP_BUFF_R/ ihop_data_buff, ihop_uncert_buff
COMMON /IHOP_BUFF_I/ &
& ihop_minind_buff, ihop_maxind_buff, ihop_curfile_buff

! IHOP cost real parameters
! objf_ihop :: ihop travel times
! num_ihop :: number of observations
! num_ihop :: number of observations
! mult_ihop :: multiplier applied to all cost terms
! ihopObs_time :: obs. start time

Expand All @@ -58,7 +58,7 @@
_RL ihopObs_lat(NFILESMAX_IHOP,NOBSMAX_IHOP,nsx,nsy)
_RL ihopObs_depth(NFILESMAX_IHOP,NOBSMAX_IHOP,nsx,nsy)
_RL ihopObs_uncert(NFILESMAX_IHOP,NOBSMAX_IHOP,nsx,nsy)
_RL ihopObs_modmask
_RL ihopObs_modmask
_RL ihopObs_modmask_tiled(nsx,nsy)
COMMON /IHOP_COST_R/ &
& objf_ihop, &
Expand All @@ -70,7 +70,7 @@

! IHOP cost filenames
! ihopObsDir :: directory where ihop observations are found
! ihopObsFile :: file name for ihop observations
! ihopObsFile :: file name for ihop observations

CHARACTER*(MAX_LEN_FNAM) ihopObsDir
CHARACTER*(MAX_LEN_FNAM) ihopObsFiles(NFILESMAX_IHOP)
Expand Down
14 changes: 7 additions & 7 deletions inc/IHOP_SIZE.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
INTEGER nts
#ifdef IHOP_MULTIPLE_TIMES
PARAMETER ( nts=10 )
#else
#else
PARAMETER ( nts=1 )
#endif

Expand All @@ -32,38 +32,38 @@
INTEGER nsd
#ifdef IHOP_MULTIPLE_SOURCES
PARAMETER ( nsd=10 )
#else
#else
PARAMETER ( nsd=1 )
#endif

! Number of Receivers:
! ================================
INTEGER nrd
INTEGER nrr
#ifdef IHOP_MULTIPLE_RECEIVER_DEPTHS
PARAMETER ( nrd=30 )
#else
#else
PARAMETER ( nrd=1 )
#endif

#ifdef IHOP_MULTIPLE_RECEIVER_RANGES
PARAMETER ( nrr=30 )
#else
#else
PARAMETER ( nrr=1 )
#endif

! Number of interpolation points:
! ================================
INTEGER IHOP_MAX_NC_SIZE
PARAMETER ( IHOP_MAX_NC_SIZE = 10 )
! INTEGER IHOP_NPTS_RANGE
! INTEGER IHOP_NPTS_RANGE
! PARAMETER( IHOP_NPTS_RANGE = 6 )
! INTEGER IHOP_IDW_NPTS
! PARAMETER( IHOP_IDW_NPTS = 4 )



! Cost function sizes
! Cost function sizes
! ================================
! NFILESMAX_ihop :: maximum number of input files
! NOBSMAX_ihop :: maximum number of observations per file per tile
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DXC_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DXC_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DXC_MACROS.h
!C | DXC_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DXF_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DXF_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DXF_MACROS.h
!C | DXF_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DXG_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DXG_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DXG_MACROS.h
!C | DXG_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DXV_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DXV_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DXV_MACROS.h
!C | DXV_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DYC_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DYC_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DYC_MACROS.h
!C | DYC_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DYF_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DYF_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DYF_MACROS.h
!C | DYF_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DYG_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DYG_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DYG_MACROS.h
!C | DYG_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/DYU_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include DYU_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | DYU_MACROS.h
!C | DYU_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/FCORI_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include FCORI_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | FCORI_MACROS.h
!C | FCORI_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/HFACC_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include HFACC_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | HFACC_MACROS.h
!C | HFACC_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/HFACS_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include HFACS_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | HFACS_MACROS.h
!C | HFACS_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
8 changes: 4 additions & 4 deletions mitgcm_code/HFACW_MACROS.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
!C include HFACW_MACROS.h
!C !DESCRIPTION: \bv
!C *==========================================================*
!C | HFACW_MACROS.h
!C | HFACW_MACROS.h
!C *==========================================================*
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C | These macros are used to reduce memory requirement and/or
!C | memory references when variables are fixed along a given
!C | axis or axes.
!C *==========================================================*
!C \ev
!CEOP
Expand Down
Loading

0 comments on commit de6aa14

Please sign in to comment.