New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
dom_oce.F90 in trunk/NEMO/OPA_SRC/DOM – NEMO

source: trunk/NEMO/OPA_SRC/DOM/dom_oce.F90 @ 392

Last change on this file since 392 was 392, checked in by opalod, 18 years ago

RB:nemo_v1_update_038: first integration of Agrif :

  • add agrif to dynspg_flt_jki.F90
  • cosmetic change of key_AGRIF in key_agrif
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 9.9 KB
Line 
1MODULE dom_oce
2   !!----------------------------------------------------------------------
3   !!                       ***  MODULE dom_oce  ***
4   !!       
5   !! ** Purpose :   Define in memory all the ocean space domain variables
6   !!----------------------------------------------------------------------
7   !!  OPA 9.0 , LOCEAN-IPSL (2005)
8   !! $Header$
9   !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt
10   !!----------------------------------------------------------------------
11   !! * Modules used
12   USE par_oce      ! ocean parameters
13
14   IMPLICIT NONE
15   PUBLIC           ! allows the acces to par_oce when dom_oce is used
16   !                ! exception to coding rules... to be suppressed ???
17
18   !!----------------------------------------------------------------------
19   !! space domain parameters
20   !! -----------------------
21   LOGICAL, PUBLIC ::   &   !:
22      lzoom      =  .FALSE. ,   &  !: zoom flag
23      lzoom_e    =  .FALSE. ,   &  !: East  zoom type flag
24      lzoom_w    =  .FALSE. ,   &  !: West  zoom type flag
25      lzoom_s    =  .FALSE. ,   &  !: South zoom type flag
26      lzoom_n    =  .FALSE. ,   &  !: North zoom type flag
27      lzoom_arct =  .FALSE. ,   &  !: ORCA    arctic zoom flag
28      lzoom_anta =  .FALSE.        !: ORCA antarctic zoom flag
29
30   INTEGER, PUBLIC ::           & !!: namdom : space domain (bathymetry, mesh)
31      ntopo   =  0 ,            &  !: = 0/1 ,compute/read the bathymetry file
32      ngrid   =  0 ,            &  !: = 0/1, compute/read the horizontal mesh file
33      nmsh    =  0                 !: = 1 create a mesh-mask file
34
35   INTEGER, PUBLIC ::         &   !:
36      ! domain parameters linked to mpp
37      nperio,          &  !: type of lateral boundary condition
38      nimpp, njmpp,    &  !: i- & j-indexes for mpp-subdomain left bottom
39      nreci, nrecj,    &  !: overlap region in i and j
40      nproc,           &  !: number for local processor
41      narea,           &  !: number for local area
42      nbondi, nbondj,  &  !: mark of i- and j-direction local boundaries
43      npolj,           &  !: north fold mark (0, 3 or 4)
44      nlci, nlcj,      &  !: i- & j-dimensions of the local subdomain
45      nldi, nlei,      &  !: first and last indoor i- and j-indexes
46      nldj, nlej,      &  !:
47      noea, nowe,      &  !: index of the local neighboring processors in
48      noso, nono,      &  !: east, west, south and north directions
49      npne, npnw,      &  !: index of north east and north west processor
50      npse, npsw,      &  !: index of south east and south west processor
51      nbne, nbnw,      &  !: logical of north east & north west processor
52      nbse, nbsw,      &  !: logical of south east & south west processor
53      nidom
54
55   INTEGER, PUBLIC, DIMENSION(jpi) ::   &   !:
56      mig                 !: local  ==> global  domain i-indice
57   INTEGER, PUBLIC, DIMENSION(jpj) ::   &   !:
58      mjg                 !: local  ==> global  domain j-indice
59   INTEGER, PUBLIC, DIMENSION( jpidta ) ::   &  !:  !!bug ==> other solution?
60      mi0, mi1            !: global ==> local domain i-indice
61      !                   !  (mi0=1 and mi1=0 if the global indice is not in the local domain)
62   INTEGER, PUBLIC, DIMENSION( jpjdta ) ::   &  !:
63      mj0, mj1            !: global ==> local domain j-indice
64      !                   ! (mi0=1 and mi1=0 if the global indice is not in the local domain)
65
66   INTEGER, PUBLIC, DIMENSION(jpnij) ::   &  !:
67      nimppt, njmppt,  &  !: i-, j-indexes for each processor
68      ibonit, ibonjt,  &  !: i-, j- processor neighbour existence
69      nlcit, nlcjt,    &  !: dimensions of every subdomain
70      nldit, nldjt,    &  !: first, last indoor index for each i-domain
71      nleit, nlejt        !: first, last indoor index for each j-domain
72
73   !!----------------------------------------------------------------------
74   !! horizontal curvilinear coordinate and scale factors
75   !! ---------------------------------------------------------------------
76
77   REAL(wp), PUBLIC, DIMENSION(jpi,jpj) ::   &  !:
78      glamt, glamu,    &  !: longitude of t-, u-, v- and f-points (degre)
79      glamv, glamf,    &  !:
80      gphit, gphiu,    &  !: latitude  of t-, u-, v- and f-points (degre)
81      gphiv, gphif,    &  !:
82      e1t, e2t,        &  !: horizontal scale factors at t-point (m)
83      e1u, e2u,        &  !: horizontal scale factors at u-point (m)
84      e1v, e2v,        &  !: horizontal scale factors at v-point (m)
85      e1f, e2f,        &  !: horizontal scale factors at f-point (m)
86      ff                  !: coriolis factor (2.*omega*sin(yphi) ) (s-1)
87
88   !!----------------------------------------------------------------------
89   !! vertical coordinate and scale factors
90   !! --------------------------------------
91
92   REAL(wp), PUBLIC ::   & !!: * namelist namdom *
93      e3zps_min = 5.0,   &  !: miminum thickness for partial steps (meters)
94      e3zps_rat = 0.1       !: minimum thickness ration for partial steps
95
96   !! z-coordinate (default option) (also used in the other cases
97   !! -----------------------------  as reference z-coordinate)
98   REAL(wp), PUBLIC, DIMENSION(jpk) ::   &  !:
99      gdept, gdepw,    &  !: reference depth of t- and w-points (m)
100      e3t, e3w            !: reference vertical scale factors at T- and W-pts (m)
101
102#if defined key_partial_steps
103   !! Partial steps ('key_partial_steps')
104   !! -----------------------------------
105   LOGICAL, PUBLIC, PARAMETER ::   lk_zps = .TRUE.   !: partial steps flag
106   LOGICAL, PUBLIC, PARAMETER ::   lk_sco = .FALSE.  !: s-coordinate flag
107   LOGICAL, PUBLIC, PARAMETER ::   lk_zco = .FALSE.  !: z-coordinate flag
108   REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) ::   &  !:
109      gdep3w,                 &  !: ???
110      gdept_ps, gdepw_ps,     &  !: depth of t- and w-points (m)
111      e3t_ps, e3u_ps, e3v_ps, &  !: vertical scale factors at t-, u-, w-,
112      e3w_ps, e3f_ps,         &  !: w- and f- points (m)
113      e3uw_ps, e3vw_ps           !: uw- and vw- points (m)
114
115   REAL(wp), PUBLIC, DIMENSION(jpi,jpj) ::   &  !:
116      hdept, hdepw, e3tp, e3wp   !: ???
117
118#elif defined key_s_coord
119   !! s-coordinate ('key_s_coord')
120   !! ----------------------------
121   LOGICAL, PUBLIC, PARAMETER ::   lk_zps = .FALSE.   !: partial steps flag
122   LOGICAL, PUBLIC, PARAMETER ::   lk_sco = .TRUE.    !: s-coordinate flag
123   LOGICAL, PUBLIC, PARAMETER ::   lk_zco = .FALSE.   !: z-coordinate flag
124   REAL(wp), PUBLIC, DIMENSION(jpi,jpj) ::   &   !:
125      hbatt, hbatu,    &  !: ocean depth at the vertical of  t-, u-, v-
126      hbatv, hbatf        !: and f-point (m)
127
128   REAL(wp), PUBLIC, DIMENSION(jpk) ::   &   !:
129      gsigt, gsigw ,   &  !: model level depth coefficient at t-, w-levels
130      gsi3w,           &  !: model level depth coefficient at w-level
131                          !  defined as the sum of e3w scale factors
132      esigt, esigw        !: vertical scale factor coef. at t-, w-levels
133
134#else
135   !! z-coordinate (Default option)
136   !! -----------------------------
137   LOGICAL, PUBLIC, PARAMETER ::   lk_zps = .FALSE.   !: partial steps flag
138   LOGICAL, PUBLIC, PARAMETER ::   lk_sco = .FALSE.   !: s-coordinate flag
139   LOGICAL, PUBLIC, PARAMETER ::   lk_zco = .TRUE.    !: s-coordinate flag
140#endif
141   !!----------------------------------------------------------------------
142   !! masks, bathymetry
143   !! -----------------
144
145   INTEGER , PUBLIC, DIMENSION(jpi,jpj) ::   &   !:
146      mbathy     !: number of ocean level (=0, 1, ... , jpk-1)
147
148   REAL(wp), PUBLIC, DIMENSION(jpi,jpj) ::   &   !:
149      bathy  ,         &  !: ocean depth (meters)
150      tmask_i             !: interior domain T-point mask
151
152   REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) ::   &   !:
153      tmask, umask,    &  !: land/ocean mask at T-, U-, V- and F-points
154      vmask, fmask        !:
155
156   REAL(wp), PUBLIC, DIMENSION(jpi,jpj) ::   &   !:
157      bmask               !: land/ocean mask of barotropic stream function
158
159   REAL(wp), PUBLIC, DIMENSION(jpiglo) ::   &   !:
160      tpol, fpol          !: north fold mask (nperio= 3 or 4)
161
162#if defined key_noslip_accurate
163   INTEGER, PUBLIC, DIMENSION(4,jpk) ::   &   !:
164      npcoa               !: ???
165   INTEGER, PUBLIC, DIMENSION(2*(jpi+jpj),4,jpk) ::   &   !:
166      nicoa,           &  !: ???
167      njcoa               !: ???
168
169#endif
170
171   !!----------------------------------------------------------------------
172   !! time domain
173   !!----------------------------------------------------------------------
174   INTEGER, PUBLIC ::    & !!: * Namelist * ???
175      nacc   = 0 ,       &  !: = 0/1 use of the acceleration of convergence technique
176      neuler                !: restart euler forward option (0=Euler)
177
178
179   REAL(wp), PUBLIC ::       & !!: * Namelist ??? *
180      rdt    = 3600._wp ,    &  !: time step for the dynamics (and tracer if nacc=0)
181      rdtmin = 3600._wp ,    &  !: minimum time step on tracers
182      rdtmax = 3600._wp ,    &  !: maximum time step on tracers
183      rdth   =  800._wp ,    &  !: depth variation of tracer step
184      rdtbt  =   90._wp ,    &  !: barotropic time step for the dynamics (lk_dynspg_ts=T)
185      atfp   = 0.1_wp   ,    &  !: asselin time filter parameter
186      atfp1                     !: asselin time filter coeff. (atfp1= 1-2*atfp)
187
188   REAL(wp), PUBLIC, DIMENSION(jpk) ::   &  !:
189      rdttra                    !: vertical profile of tracer time step
190
191   !!----------------------------------------------------------------------
192   !! cross land advection
193   !!----------------------------------------------------------------------
194
195   INTEGER, PUBLIC ::       & !!: namelist ???
196      n_cla                    !: flag (0/1) for cross land advection to
197      !                        ! parameterize exchanges through straits
198
199#if defined key_agrif
200   !!----------------------------------------------------------------------
201   !! agrif sponge layer
202   !!----------------------------------------------------------------------
203      LOGICAL :: spongedoneT = .FALSE.
204      REAL(wp), DIMENSION(jpi,jpj) :: zspe1ur, zspe2vr ,zspbtr2
205   !!----------------------------------------------------------------------
206#endif
207
208END MODULE dom_oce
Note: See TracBrowser for help on using the repository browser.