dynspg_flt.F90 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429
  1. MODULE dynspg_flt
  2. !!======================================================================
  3. !! *** MODULE dynspg_flt ***
  4. !! Ocean dynamics: surface pressure gradient trend
  5. !!======================================================================
  6. !! History OPA ! 1998-05 (G. Roullet) free surface
  7. !! ! 1998-10 (G. Madec, M. Imbard) release 8.2
  8. !! NEMO O.1 ! 2002-08 (G. Madec) F90: Free form and module
  9. !! - ! 2002-11 (C. Talandier, A-M Treguier) Open boundaries
  10. !! 1.0 ! 2004-08 (C. Talandier) New trends organization
  11. !! - ! 2005-11 (V. Garnier) Surface pressure gradient organization
  12. !! 2.0 ! 2006-07 (S. Masson) distributed restart using iom
  13. !! - ! 2006-08 (J.Chanut, A.Sellar) Calls to BDY routines.
  14. !! 3.2 ! 2009-03 (G. Madec, M. Leclair, R. Benshila) introduce sshwzv module
  15. !! 3.7 ! 2014-04 (F. Roquet, G. Madec) add some trends diag
  16. !!----------------------------------------------------------------------
  17. #if defined key_dynspg_flt || defined key_esopa
  18. !!----------------------------------------------------------------------
  19. !! 'key_dynspg_flt' filtered free surface
  20. !!----------------------------------------------------------------------
  21. !! dyn_spg_flt : update the momentum trend with the surface pressure gradient in the filtered free surface case
  22. !! flt_rst : read/write the time-splitting restart fields in the ocean restart file
  23. !!----------------------------------------------------------------------
  24. USE oce ! ocean dynamics and tracers
  25. USE dom_oce ! ocean space and time domain
  26. USE zdf_oce ! ocean vertical physics
  27. USE sbc_oce ! surface boundary condition: ocean
  28. USE bdy_oce ! Lateral open boundary condition
  29. USE sol_oce ! ocean elliptic solver
  30. USE phycst ! physical constants
  31. USE domvvl ! variable volume
  32. USE dynadv ! advection
  33. USE solmat ! matrix construction for elliptic solvers
  34. USE solpcg ! preconditionned conjugate gradient solver
  35. USE solsor ! Successive Over-relaxation solver
  36. USE bdydyn ! ocean open boundary condition on dynamics
  37. USE bdyvol ! ocean open boundary condition (bdy_vol routine)
  38. USE cla ! cross land advection
  39. USE trd_oce ! trends: ocean variables
  40. USE trddyn ! trend manager: dynamics
  41. !
  42. USE in_out_manager ! I/O manager
  43. USE lib_mpp ! distributed memory computing library
  44. USE wrk_nemo ! Memory Allocation
  45. USE lbclnk ! ocean lateral boundary conditions (or mpp link)
  46. USE prtctl ! Print control
  47. USE iom
  48. USE lib_fortran
  49. USE timing ! Timing
  50. #if defined key_agrif
  51. USE agrif_opa_interp
  52. #endif
  53. IMPLICIT NONE
  54. PRIVATE
  55. PUBLIC dyn_spg_flt ! routine called by step.F90
  56. PUBLIC flt_rst ! routine called by istate.F90
  57. !! * Substitutions
  58. # include "domzgr_substitute.h90"
  59. # include "vectopt_loop_substitute.h90"
  60. !!----------------------------------------------------------------------
  61. !! NEMO/OPA 3.3 , NEMO Consortium (2010)
  62. !! $Id: dynspg_flt.F90 4990 2014-12-15 16:42:49Z timgraham $
  63. !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt)
  64. !!----------------------------------------------------------------------
  65. CONTAINS
  66. SUBROUTINE dyn_spg_flt( kt, kindic )
  67. !!----------------------------------------------------------------------
  68. !! *** routine dyn_spg_flt ***
  69. !!
  70. !! ** Purpose : Compute the now trend due to the surface pressure
  71. !! gradient in case of filtered free surface formulation and add
  72. !! it to the general trend of momentum equation.
  73. !!
  74. !! ** Method : Filtered free surface formulation. The surface
  75. !! pressure gradient is given by:
  76. !! spgu = 1/rau0 d/dx(ps) = 1/e1u di( sshn + btda )
  77. !! spgv = 1/rau0 d/dy(ps) = 1/e2v dj( sshn + btda )
  78. !! where sshn is the free surface elevation and btda is the after
  79. !! time derivative of the free surface elevation
  80. !! -1- evaluate the surface presure trend (including the addi-
  81. !! tional force) in three steps:
  82. !! a- compute the right hand side of the elliptic equation:
  83. !! gcb = 1/(e1t e2t) [ di(e2u spgu) + dj(e1v spgv) ]
  84. !! where (spgu,spgv) are given by:
  85. !! spgu = vertical sum[ e3u (ub+ 2 rdt ua ) ]
  86. !! - grav 2 rdt hu /e1u di[sshn + (emp-rnf)]
  87. !! spgv = vertical sum[ e3v (vb+ 2 rdt va) ]
  88. !! - grav 2 rdt hv /e2v dj[sshn + (emp-rnf)]
  89. !! and define the first guess from previous computation :
  90. !! zbtd = btda
  91. !! btda = 2 zbtd - btdb
  92. !! btdb = zbtd
  93. !! b- compute the relative accuracy to be reached by the
  94. !! iterative solver
  95. !! c- apply the solver by a call to sol... routine
  96. !! -2- compute and add the free surface pressure gradient inclu-
  97. !! ding the additional force used to stabilize the equation.
  98. !!
  99. !! ** Action : - Update (ua,va) with the surf. pressure gradient trend
  100. !!
  101. !! References : Roullet and Madec, JGR, 2000.
  102. !!---------------------------------------------------------------------
  103. INTEGER, INTENT(in ) :: kt ! ocean time-step index
  104. INTEGER, INTENT( out) :: kindic ! solver convergence flag (<0 if not converge)
  105. !
  106. INTEGER :: ji, jj, jk ! dummy loop indices
  107. REAL(wp) :: z2dt, z2dtg, zgcb, zbtd, ztdgu, ztdgv ! local scalars
  108. REAL(wp), POINTER, DIMENSION(:,:,:) :: ztrdu, ztrdv
  109. REAL(wp), POINTER, DIMENSION(:,:) :: zpw
  110. !!----------------------------------------------------------------------
  111. !
  112. IF( nn_timing == 1 ) CALL timing_start('dyn_spg_flt')
  113. !
  114. IF( kt == nit000 ) THEN
  115. IF(lwp) WRITE(numout,*)
  116. IF(lwp) WRITE(numout,*) 'dyn_spg_flt : surface pressure gradient trend'
  117. IF(lwp) WRITE(numout,*) '~~~~~~~~~~~ (free surface constant volume case)'
  118. ! set to zero free surface specific arrays
  119. spgu(:,:) = 0._wp ! surface pressure gradient (i-direction)
  120. spgv(:,:) = 0._wp ! surface pressure gradient (j-direction)
  121. ! read filtered free surface arrays in restart file
  122. ! when using agrif, sshn, gcx have to be read in istate
  123. IF(.NOT. lk_agrif) CALL flt_rst( nit000, 'READ' ) ! read or initialize the following fields:
  124. ! ! gcx, gcxb
  125. ENDIF
  126. ! Local constant initialization
  127. z2dt = 2. * rdt ! time step: leap-frog
  128. IF( neuler == 0 .AND. kt == nit000 ) z2dt = rdt ! time step: Euler if restart from rest
  129. IF( neuler == 0 .AND. kt == nit000+1 ) CALL sol_mat( kt )
  130. z2dtg = grav * z2dt
  131. ! Evaluate the masked next velocity (effect of the additional force not included)
  132. ! ---------------------------------
  133. IF( lk_vvl ) THEN ! variable volume (surface pressure gradient already included in dyn_hpg)
  134. !
  135. IF( ln_dynadv_vec ) THEN ! vector form : applied on velocity
  136. DO jk = 1, jpkm1
  137. DO jj = 2, jpjm1
  138. DO ji = fs_2, fs_jpim1 ! vector opt.
  139. ua(ji,jj,jk) = ( ub(ji,jj,jk) + z2dt * ua(ji,jj,jk) ) * umask(ji,jj,jk)
  140. va(ji,jj,jk) = ( vb(ji,jj,jk) + z2dt * va(ji,jj,jk) ) * vmask(ji,jj,jk)
  141. END DO
  142. END DO
  143. END DO
  144. !
  145. ELSE ! flux form : applied on thickness weighted velocity
  146. DO jk = 1, jpkm1
  147. DO jj = 2, jpjm1
  148. DO ji = fs_2, fs_jpim1 ! vector opt.
  149. ua(ji,jj,jk) = ( ub(ji,jj,jk) * fse3u_b(ji,jj,jk) &
  150. & + z2dt * ua(ji,jj,jk) * fse3u_n(ji,jj,jk) ) &
  151. & / fse3u_a(ji,jj,jk) * umask(ji,jj,jk)
  152. va(ji,jj,jk) = ( vb(ji,jj,jk) * fse3v_b(ji,jj,jk) &
  153. & + z2dt * va(ji,jj,jk) * fse3v_n(ji,jj,jk) ) &
  154. & / fse3v_a(ji,jj,jk) * vmask(ji,jj,jk)
  155. END DO
  156. END DO
  157. END DO
  158. !
  159. ENDIF
  160. IF( l_trddyn ) THEN ! Put here so code doesn't crash when doing KE trend but needs to be done properly
  161. CALL wrk_alloc( jpi, jpj, jpk, ztrdu, ztrdv )
  162. ENDIF
  163. !
  164. ELSE ! fixed volume (add the surface pressure gradient + unweighted time stepping)
  165. !
  166. DO jj = 2, jpjm1 ! Surface pressure gradient (now)
  167. DO ji = fs_2, fs_jpim1 ! vector opt.
  168. spgu(ji,jj) = - grav * ( sshn(ji+1,jj) - sshn(ji,jj) ) / e1u(ji,jj)
  169. spgv(ji,jj) = - grav * ( sshn(ji,jj+1) - sshn(ji,jj) ) / e2v(ji,jj)
  170. END DO
  171. END DO
  172. DO jk = 1, jpkm1 ! unweighted time stepping
  173. DO jj = 2, jpjm1
  174. DO ji = fs_2, fs_jpim1 ! vector opt.
  175. ua(ji,jj,jk) = ( ub(ji,jj,jk) + z2dt * ( ua(ji,jj,jk) + spgu(ji,jj) ) ) * umask(ji,jj,jk)
  176. va(ji,jj,jk) = ( vb(ji,jj,jk) + z2dt * ( va(ji,jj,jk) + spgv(ji,jj) ) ) * vmask(ji,jj,jk)
  177. END DO
  178. END DO
  179. END DO
  180. !
  181. IF( l_trddyn ) THEN ! temporary save of spg trends
  182. CALL wrk_alloc( jpi, jpj, jpk, ztrdu, ztrdv )
  183. DO jk = 1, jpkm1 ! unweighted time stepping
  184. DO jj = 2, jpjm1
  185. DO ji = fs_2, fs_jpim1 ! vector opt.
  186. ztrdu(ji,jj,jk) = spgu(ji,jj) * umask(ji,jj,jk)
  187. ztrdv(ji,jj,jk) = spgv(ji,jj) * vmask(ji,jj,jk)
  188. END DO
  189. END DO
  190. END DO
  191. CALL trd_dyn( ztrdu, ztrdv, jpdyn_spgexp, kt )
  192. ENDIF
  193. !
  194. ENDIF
  195. #if defined key_bdy
  196. IF( lk_bdy ) CALL bdy_dyn( kt ) ! Update velocities on each open boundary
  197. IF( lk_bdy ) CALL bdy_vol( kt ) ! Correction of the barotropic component velocity to control the volume of the system
  198. #endif
  199. #if defined key_agrif
  200. CALL Agrif_dyn( kt ) ! Update velocities on each coarse/fine interfaces
  201. #endif
  202. IF( nn_cla == 1 .AND. cp_cfg == 'orca' .AND. jp_cfg == 2 ) CALL cla_dynspg( kt ) ! Cross Land Advection (update (ua,va))
  203. ! compute the next vertically averaged velocity (effect of the additional force not included)
  204. ! ---------------------------------------------
  205. DO jj = 2, jpjm1
  206. DO ji = fs_2, fs_jpim1 ! vector opt.
  207. spgu(ji,jj) = fse3u_a(ji,jj,1) * ua(ji,jj,1)
  208. spgv(ji,jj) = fse3v_a(ji,jj,1) * va(ji,jj,1)
  209. END DO
  210. END DO
  211. DO jk = 2, jpkm1 ! vertical sum
  212. DO jj = 2, jpjm1
  213. DO ji = fs_2, fs_jpim1 ! vector opt.
  214. spgu(ji,jj) = spgu(ji,jj) + fse3u_a(ji,jj,jk) * ua(ji,jj,jk)
  215. spgv(ji,jj) = spgv(ji,jj) + fse3v_a(ji,jj,jk) * va(ji,jj,jk)
  216. END DO
  217. END DO
  218. END DO
  219. DO jj = 2, jpjm1 ! transport: multiplied by the horizontal scale factor
  220. DO ji = fs_2, fs_jpim1 ! vector opt.
  221. spgu(ji,jj) = spgu(ji,jj) * e2u(ji,jj)
  222. spgv(ji,jj) = spgv(ji,jj) * e1v(ji,jj)
  223. END DO
  224. END DO
  225. CALL lbc_lnk( spgu, 'U', -1. ) ! lateral boundary conditions
  226. CALL lbc_lnk( spgv, 'V', -1. )
  227. IF( lk_vvl ) CALL sol_mat( kt ) ! build the matrix at kt (vvl case only)
  228. ! Right hand side of the elliptic equation and first guess
  229. ! --------------------------------------------------------
  230. DO jj = 2, jpjm1
  231. DO ji = fs_2, fs_jpim1 ! vector opt.
  232. ! Divergence of the after vertically averaged velocity
  233. zgcb = spgu(ji,jj) - spgu(ji-1,jj) &
  234. + spgv(ji,jj) - spgv(ji,jj-1)
  235. gcb(ji,jj) = gcdprc(ji,jj) * zgcb
  236. ! First guess of the after barotropic transport divergence
  237. zbtd = gcx(ji,jj)
  238. gcx (ji,jj) = 2. * zbtd - gcxb(ji,jj)
  239. gcxb(ji,jj) = zbtd
  240. END DO
  241. END DO
  242. ! applied the lateral boundary conditions
  243. IF( nn_solv == 2 .AND. MAX( jpr2di, jpr2dj ) > 0 ) CALL lbc_lnk_e( gcb, c_solver_pt, 1., jpr2di, jpr2dj )
  244. #if defined key_agrif
  245. IF( .NOT. AGRIF_ROOT() ) THEN
  246. ! add contribution of gradient of after barotropic transport divergence
  247. IF( nbondi == -1 .OR. nbondi == 2 ) gcb(3 ,:) = &
  248. & gcb(3 ,:) - z2dtg * z2dt * laplacu(2 ,:) * gcdprc(3 ,:) * hu(2 ,:) * e2u(2 ,:)
  249. IF( nbondi == 1 .OR. nbondi == 2 ) gcb(nlci-2,:) = &
  250. & gcb(nlci-2,:) + z2dtg * z2dt * laplacu(nlci-2,:) * gcdprc(nlci-2,:) * hu(nlci-2,:) * e2u(nlci-2,:)
  251. IF( nbondj == -1 .OR. nbondj == 2 ) gcb(: ,3) = &
  252. & gcb(:,3 ) - z2dtg * z2dt * laplacv(:,2 ) * gcdprc(:,3 ) * hv(:,2 ) * e1v(:,2 )
  253. IF( nbondj == 1 .OR. nbondj == 2 ) gcb(:,nlcj-2) = &
  254. & gcb(:,nlcj-2) + z2dtg * z2dt * laplacv(:,nlcj-2) * gcdprc(:,nlcj-2) * hv(:,nlcj-2) * e1v(:,nlcj-2)
  255. ENDIF
  256. #endif
  257. ! Relative precision (computation on one processor)
  258. ! ------------------
  259. rnorme =0.e0
  260. rnorme = GLOB_SUM( gcb(1:jpi,1:jpj) * gcdmat(1:jpi,1:jpj) * gcb(1:jpi,1:jpj) * bmask(:,:) )
  261. epsr = eps * eps * rnorme
  262. ncut = 0
  263. ! if rnorme is 0, the solution is 0, the solver is not called
  264. IF( rnorme == 0._wp ) THEN
  265. gcx(:,:) = 0._wp
  266. res = 0._wp
  267. niter = 0
  268. ncut = 999
  269. ENDIF
  270. ! Evaluate the next transport divergence
  271. ! --------------------------------------
  272. ! Iterarive solver for the elliptic equation (except IF sol.=0)
  273. ! (output in gcx with boundary conditions applied)
  274. kindic = 0
  275. IF( ncut == 0 ) THEN
  276. IF ( nn_solv == 1 ) THEN ; CALL sol_pcg( kindic ) ! diagonal preconditioned conjuguate gradient
  277. ELSEIF( nn_solv == 2 ) THEN ; CALL sol_sor( kindic ) ! successive-over-relaxation
  278. ENDIF
  279. ENDIF
  280. ! Transport divergence gradient multiplied by z2dt
  281. ! --------------------------------------------====
  282. DO jj = 2, jpjm1
  283. DO ji = fs_2, fs_jpim1 ! vector opt.
  284. ! trend of Transport divergence gradient
  285. ztdgu = z2dtg * (gcx(ji+1,jj ) - gcx(ji,jj) ) / e1u(ji,jj)
  286. ztdgv = z2dtg * (gcx(ji ,jj+1) - gcx(ji,jj) ) / e2v(ji,jj)
  287. ! multiplied by z2dt
  288. #if defined key_bdy
  289. IF(lk_bdy) THEN
  290. ! caution : grad D = 0 along open boundaries
  291. spgu(ji,jj) = z2dt * ztdgu * bdyumask(ji,jj)
  292. spgv(ji,jj) = z2dt * ztdgv * bdyvmask(ji,jj)
  293. ELSE
  294. spgu(ji,jj) = z2dt * ztdgu
  295. spgv(ji,jj) = z2dt * ztdgv
  296. ENDIF
  297. #else
  298. spgu(ji,jj) = z2dt * ztdgu
  299. spgv(ji,jj) = z2dt * ztdgv
  300. #endif
  301. END DO
  302. END DO
  303. #if defined key_agrif
  304. IF( .NOT. Agrif_Root() ) THEN
  305. ! caution : grad D (fine) = grad D (coarse) at coarse/fine interface
  306. IF( nbondi == -1 .OR. nbondi == 2 ) spgu(2 ,:) = z2dtg * z2dt * laplacu(2 ,:) * umask(2 ,:,1)
  307. IF( nbondi == 1 .OR. nbondi == 2 ) spgu(nlci-2,:) = z2dtg * z2dt * laplacu(nlci-2,:) * umask(nlci-2,:,1)
  308. IF( nbondj == -1 .OR. nbondj == 2 ) spgv(:,2 ) = z2dtg * z2dt * laplacv(:,2 ) * vmask(: ,2,1)
  309. IF( nbondj == 1 .OR. nbondj == 2 ) spgv(:,nlcj-2) = z2dtg * z2dt * laplacv(:,nlcj-2) * vmask(:,nlcj-2,1)
  310. ENDIF
  311. #endif
  312. IF( l_trddyn ) THEN
  313. ztrdu(:,:,:) = ua(:,:,:) ! save the after velocity before the filtered SPG
  314. ztrdv(:,:,:) = va(:,:,:)
  315. !
  316. CALL wrk_alloc( jpi, jpj, zpw )
  317. !
  318. zpw(:,:) = - z2dt * gcx(:,:)
  319. CALL iom_put( "ssh_flt" , zpw ) ! output equivalent ssh modification due to implicit filter
  320. !
  321. ! ! save surface pressure flux: -pw at z=0
  322. zpw(:,:) = - rau0 * grav * sshn(:,:) * wn(:,:,1) * tmask(:,:,1)
  323. CALL iom_put( "pw0_exp" , zpw )
  324. zpw(:,:) = wn(:,:,1)
  325. CALL iom_put( "w0" , zpw )
  326. zpw(:,:) = rau0 * z2dtg * gcx(:,:) * wn(:,:,1) * tmask(:,:,1)
  327. CALL iom_put( "pw0_flt" , zpw )
  328. !
  329. CALL wrk_dealloc( jpi, jpj, zpw )
  330. !
  331. ENDIF
  332. ! Add the trends multiplied by z2dt to the after velocity
  333. ! -------------------------------------------------------
  334. ! ( c a u t i o n : (ua,va) here are the after velocity not the
  335. ! trend, the leap-frog time stepping will not
  336. ! be done in dynnxt.F90 routine)
  337. DO jk = 1, jpkm1
  338. DO jj = 2, jpjm1
  339. DO ji = fs_2, fs_jpim1 ! vector opt.
  340. ua(ji,jj,jk) = ( ua(ji,jj,jk) + spgu(ji,jj) ) * umask(ji,jj,jk)
  341. va(ji,jj,jk) = ( va(ji,jj,jk) + spgv(ji,jj) ) * vmask(ji,jj,jk)
  342. END DO
  343. END DO
  344. END DO
  345. IF( l_trddyn ) THEN ! save the explicit SPG trends for further diagnostics
  346. ztrdu(:,:,:) = ( ua(:,:,:) - ztrdu(:,:,:) ) / z2dt
  347. ztrdv(:,:,:) = ( va(:,:,:) - ztrdv(:,:,:) ) / z2dt
  348. CALL trd_dyn( ztrdu, ztrdv, jpdyn_spgflt, kt )
  349. !
  350. CALL wrk_dealloc( jpi, jpj, jpk, ztrdu, ztrdv )
  351. ENDIF
  352. IF( lrst_oce ) CALL flt_rst( kt, 'WRITE' ) ! write filtered free surface arrays in restart file
  353. !
  354. IF( nn_timing == 1 ) CALL timing_stop('dyn_spg_flt')
  355. !
  356. END SUBROUTINE dyn_spg_flt
  357. SUBROUTINE flt_rst( kt, cdrw )
  358. !!---------------------------------------------------------------------
  359. !! *** ROUTINE ts_rst ***
  360. !!
  361. !! ** Purpose : Read or write filtered free surface arrays in restart file
  362. !!----------------------------------------------------------------------
  363. INTEGER , INTENT(in) :: kt ! ocean time-step
  364. CHARACTER(len=*), INTENT(in) :: cdrw ! "READ"/"WRITE" flag
  365. !!----------------------------------------------------------------------
  366. !
  367. IF( TRIM(cdrw) == 'READ' ) THEN
  368. IF( iom_varid( numror, 'gcx', ldstop = .FALSE. ) > 0 ) THEN
  369. ! Caution : extra-hallow
  370. ! gcx and gcxb are defined as: DIMENSION(1-jpr2di:jpi+jpr2di,1-jpr2dj:jpj+jpr2dj)
  371. CALL iom_get( numror, jpdom_autoglo, 'gcx' , gcx (1:jpi,1:jpj) )
  372. CALL iom_get( numror, jpdom_autoglo, 'gcxb', gcxb(1:jpi,1:jpj) )
  373. IF( neuler == 0 ) gcxb(:,:) = gcx (:,:)
  374. ELSE
  375. gcx (:,:) = 0.e0
  376. gcxb(:,:) = 0.e0
  377. ENDIF
  378. ELSEIF( TRIM(cdrw) == 'WRITE' ) THEN
  379. ! Caution : extra-hallow
  380. ! gcx and gcxb are defined as: DIMENSION(1-jpr2di:jpi+jpr2di,1-jpr2dj:jpj+jpr2dj)
  381. CALL iom_rstput( kt, nitrst, numrow, 'gcx' , gcx (1:jpi,1:jpj) )
  382. CALL iom_rstput( kt, nitrst, numrow, 'gcxb', gcxb(1:jpi,1:jpj) )
  383. ENDIF
  384. !
  385. END SUBROUTINE flt_rst
  386. #else
  387. !!----------------------------------------------------------------------
  388. !! Default case : Empty module No standart free surface cst volume
  389. !!----------------------------------------------------------------------
  390. CONTAINS
  391. SUBROUTINE dyn_spg_flt( kt, kindic ) ! Empty routine
  392. WRITE(*,*) 'dyn_spg_flt: You should not have seen this print! error?', kt, kindic
  393. END SUBROUTINE dyn_spg_flt
  394. SUBROUTINE flt_rst ( kt, cdrw ) ! Empty routine
  395. INTEGER , INTENT(in) :: kt ! ocean time-step
  396. CHARACTER(len=*), INTENT(in) :: cdrw ! "READ"/"WRITE" flag
  397. WRITE(*,*) 'flt_rst: You should not have seen this print! error?', kt, cdrw
  398. END SUBROUTINE flt_rst
  399. #endif
  400. !!======================================================================
  401. END MODULE dynspg_flt