Changeset 6140 for trunk/NEMOGCM/NEMO/OPA_SRC/step.F90
- Timestamp:
- 2015-12-21T12:35:23+01:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/NEMOGCM/NEMO/OPA_SRC/step.F90
r5930 r6140 2 2 !!====================================================================== 3 3 !! *** MODULE step *** 4 !! Time-stepping 4 !! Time-stepping : manager of the ocean, tracer and ice time stepping 5 5 !!====================================================================== 6 6 !! History : OPA ! 1991-03 (G. Madec) Original code … … 35 35 !!---------------------------------------------------------------------- 36 36 USE step_oce ! time stepping definition modules 37 USE iom 37 ! 38 USE iom ! xIOs server 38 39 39 40 IMPLICIT NONE … … 42 43 PUBLIC stp ! called by nemogcm.F90 43 44 44 !! * Substitutions45 # include "domzgr_substitute.h90"46 !!gm # include "zdfddm_substitute.h90"47 45 !!---------------------------------------------------------------------- 48 46 !! NEMO/OPA 3.7 , NEMO Consortium (2015) … … 166 164 167 165 IF( ln_zps .AND. ln_isfcav) & 168 & CALL zps_hde_isf( kstp, jpts, tsb, gtsu, gtsv, gtui, gtvi, & ! Partial steps for top cell (ISF) 169 & rhd, gru , grv , aru , arv , gzu , gzv , ge3ru , ge3rv , & 170 & grui, grvi, arui, arvi, gzui, gzvi, ge3rui, ge3rvi ) ! of t, s, rd at the first ocean level 171 166 & CALL zps_hde_isf( kstp, jpts, tsb, gtsu, gtsv, gtui, gtvi, & ! Partial steps for top cell (ISF) 167 & rhd, gru , grv , grui, grvi ) ! of t, s, rd at the first ocean level 172 168 IF( ln_traldf_triad ) THEN 173 169 CALL ldf_slp_triad( kstp ) ! before slope for triad operator … … 183 179 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 184 180 185 CALL ssh_nxt ( kstp ) ! after ssh (includes call to div_hor) 186 IF( lk_vvl ) CALL dom_vvl_sf_nxt( kstp ) ! after vertical scale factors 187 CALL wzv ( kstp ) ! now cross-level velocity 188 181 CALL ssh_nxt ( kstp ) ! after ssh (includes call to div_hor) 182 IF(.NOT.ln_linssh ) CALL dom_vvl_sf_nxt( kstp ) ! after vertical scale factors 183 CALL wzv ( kstp ) ! now cross-level velocity 189 184 !!gm : why also here ???? 190 IF( ln_sto_eos) CALL sto_pts( tsn ) ! Random T/S fluctuations185 IF( ln_sto_eos ) CALL sto_pts( tsn ) ! Random T/S fluctuations 191 186 !!gm 192 CALL eos ( tsn, rhd, rhop, fsdept_n(:,:,:) )! now in situ density for hpg computation193 187 CALL eos ( tsn, rhd, rhop, gdept_n(:,:,:) ) ! now in situ density for hpg computation 188 194 189 !!jc: fs simplification 195 !!jc: lines below are useless if l k_vvl=T. Keep them here (which maintains a bug if lk_vvl=Fand ln_zps=T, cf ticket #1636)190 !!jc: lines below are useless if ln_linssh=F. Keep them here (which maintains a bug if ln_linssh=T and ln_zps=T, cf ticket #1636) 196 191 !! but ensures reproductible results 197 192 !! with previous versions using split-explicit free surface 198 IF( ln_zps .AND. .NOT. ln_isfcav) & ! Partial steps: bottom before horizontal gradient 199 & CALL zps_hde ( kstp, jpts, tsn, gtsu, gtsv, & ! of t, s, rd at the last ocean level 200 & rhd, gru , grv ) 201 IF( ln_zps .AND. ln_isfcav) & ! Partial steps: top & bottom before horizontal gradient 202 & CALL zps_hde_isf( kstp, jpts, tsn, gtsu, gtsv, gtui, gtvi, & 203 & rhd, gru , grv , aru , arv , gzu , gzv , ge3ru , ge3rv , & 204 & grui, grvi, arui, arvi, gzui, gzvi, ge3rui, ge3rvi ) 193 IF( ln_zps .AND. .NOT. ln_isfcav ) & 194 & CALL zps_hde ( kstp, jpts, tsn, gtsu, gtsv, & ! Partial steps: before horizontal gradient 195 & rhd, gru , grv ) ! of t, s, rd at the last ocean level 196 IF( ln_zps .AND. ln_isfcav ) & 197 & CALL zps_hde_isf( kstp, jpts, tsn, gtsu, gtsv, gtui, gtvi, & ! Partial steps for top cell (ISF) 198 & rhd, gru , grv , grui, grvi ) ! of t, s, rd at the first ocean level 205 199 !!jc: fs simplification 206 200 … … 224 218 IF( ln_dynspg_ts ) THEN ! vertical scale factors and vertical velocity need to be updated 225 219 CALL div_hor ( kstp ) ! Horizontal divergence (2nd call in time-split case) 226 IF( lk_vvl )CALL dom_vvl_sf_nxt( kstp, kcall=2 ) ! after vertical scale factors (update depth average component)220 IF(.NOT.ln_linssh) CALL dom_vvl_sf_nxt( kstp, kcall=2 ) ! after vertical scale factors (update depth average component) 227 221 CALL wzv ( kstp ) ! now cross-level velocity 228 222 ENDIF … … 232 226 233 227 !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 234 ! diagnostics and outputs 235 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 236 IF( lk_floats ) CALL flo_stp ( kstp ) ! drifting Floats 237 IF( lk_diahth ) CALL dia_hth ( kstp ) ! Thermocline depth (20 degres isotherm depth) 238 IF(.NOT.ln_cpl ) CALL dia_fwb ( kstp ) ! Fresh water budget diagnostics 239 IF( lk_diadct ) CALL dia_dct ( kstp ) ! Transports 240 IF( lk_diaar5 ) CALL dia_ar5 ( kstp ) ! ar5 diag 241 IF( lk_diaharm ) CALL dia_harm ( kstp ) ! Tidal harmonic analysis 242 CALL dia_wri ( kstp ) ! ocean model: outputs 228 ! cool skin 229 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 230 IF ( ln_diurnal ) CALL stp_diurnal( kstp ) 231 232 !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 233 ! diagnostics and outputs (ua, va, tsa used as workspace) 234 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 235 IF( lk_floats ) CALL flo_stp( kstp ) ! drifting Floats 236 IF( nn_diacfl == 1 ) CALL dia_cfl( kstp ) ! Courant number diagnostics 237 IF( lk_diahth ) CALL dia_hth( kstp ) ! Thermocline depth (20 degres isotherm depth) 238 IF(.NOT.ln_cpl ) CALL dia_fwb( kstp ) ! Fresh water budget diagnostics 239 IF( lk_diadct ) CALL dia_dct( kstp ) ! Transports 240 IF( lk_diaar5 ) CALL dia_ar5( kstp ) ! ar5 diag 241 IF( lk_diaharm ) CALL dia_harm( kstp ) ! Tidal harmonic analysis 242 CALL dia_wri( kstp ) ! ocean model: outputs 243 243 ! 244 244 IF( ln_crs ) CALL crs_fld ( kstp ) ! ocean model: online field coarsening & output 245 245 246 246 #if defined key_top 247 247 !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> … … 293 293 !! place. 294 294 !! 295 !!jc2: dynnxt must be the latest call. fse3t_b are indeed updated in that routine295 !!jc2: dynnxt must be the latest call. e3t_b are indeed updated in that routine 296 296 CALL tra_nxt ( kstp ) ! finalize (bcs) tracer fields at next time step and swap 297 297 CALL dyn_nxt ( kstp ) ! finalize (bcs) velocities at next time step and swap 298 298 CALL ssh_swp ( kstp ) ! swap of sea surface height 299 IF( lk_vvl )CALL dom_vvl_sf_swp( kstp ) ! swap of vertical scale factors299 IF(.NOT.ln_linssh) CALL dom_vvl_sf_swp( kstp ) ! swap of vertical scale factors 300 300 ! 301 301 … … 313 313 CALL Agrif_Integrate_ChildGrids( stp ) 314 314 315 IF ( Agrif_NbStepint().EQ.0 ) THEN! AGRIF Update316 !!jc in fact update i useless at last time step, but do it for global diagnostics315 IF( Agrif_NbStepint() == 0 ) THEN ! AGRIF Update 316 !!jc in fact update is useless at last time step, but do it for global diagnostics 317 317 CALL Agrif_Update_Tra() ! Update active tracers 318 318 CALL Agrif_Update_Dyn() ! Update momentum 319 319 ENDIF 320 320 #endif 321 IF( ln_diahsb ) CALL dia_hsb ( kstp )! - ML - global conservation diagnostics322 IF( l k_diaobs ) CALL dia_obs ( kstp )! obs-minus-model (assimilation) diagnostics (call after dynamics update)321 IF( ln_diahsb ) CALL dia_hsb( kstp ) ! - ML - global conservation diagnostics 322 IF( ln_diaobs ) CALL dia_obs( kstp ) ! obs-minus-model (assimilation) diagnostics (call after dynamics update) 323 323 324 324 !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> … … 326 326 !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 327 327 CALL stp_ctl ( kstp, indic ) 328 IF( indic < 0 ) 328 IF( indic < 0 ) THEN 329 329 CALL ctl_stop( 'step: indic < 0' ) 330 330 CALL dia_wri_state( 'output.abort', kstp ) 331 331 ENDIF 332 IF( kstp == nit000 ) 332 IF( kstp == nit000 ) THEN 333 333 CALL iom_close( numror ) ! close input ocean restart file 334 334 IF(lwm) CALL FLUSH ( numond ) ! flush output namelist oce … … 353 353 ! 354 354 END SUBROUTINE stp 355 356 !!====================================================================== 355 357 356 END MODULE step
Note: See TracChangeset
for help on using the changeset viewer.