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.
step.F90 in branches/2011/DEV_r2739_STFC_dCSE/NEMOGCM/NEMO/OPA_SRC – NEMO

source: branches/2011/DEV_r2739_STFC_dCSE/NEMOGCM/NEMO/OPA_SRC/step.F90 @ 3837

Last change on this file since 3837 was 3837, checked in by trackstand2, 11 years ago

Merge of finiss

  • Property svn:keywords set to Id
File size: 21.1 KB
RevLine 
[3]1MODULE step
2   !!======================================================================
3   !!                       ***  MODULE step  ***
4   !! Time-stepping    : manager of the ocean, tracer and ice time stepping
5   !!======================================================================
[1438]6   !! History :  OPA  !  1991-03  (G. Madec)  Original code
[1492]7   !!             -   !  1991-11  (G. Madec)
8   !!             -   !  1992-06  (M. Imbard)  add a first output record
9   !!             -   !  1996-04  (G. Madec)  introduction of dynspg
10   !!             -   !  1996-04  (M.A. Foujols)  introduction of passive tracer
[1438]11   !!            8.0  !  1997-06  (G. Madec)  new architecture of call
12   !!            8.2  !  1997-06  (G. Madec, M. Imbard, G. Roullet)  free surface
13   !!             -   !  1999-02  (G. Madec, N. Grima)  hpg implicit
14   !!             -   !  2000-07  (J-M Molines, M. Imbard)  Open Bondary Conditions
15   !!   NEMO     1.0  !  2002-06  (G. Madec)  free form, suppress macro-tasking
16   !!             -   !  2004-08  (C. Talandier) New trends organization
[1492]17   !!             -   !  2005-01  (C. Ethe) Add the KPP closure scheme
18   !!             -   !  2005-11  (G. Madec)  Reorganisation of tra and dyn calls
19   !!             -   !  2006-01  (L. Debreu, C. Mazauric)  Agrif implementation
20   !!             -   !  2006-07  (S. Masson)  restart using iom
[1438]21   !!            3.2  !  2009-02  (G. Madec, R. Benshila)  reintroduicing z*-coordinate
[1533]22   !!             -   !  2009-06  (S. Masson, G. Madec)  TKE restart compatible with key_cpl
[2528]23   !!            3.3  !  2010-05  (K. Mogensen, A. Weaver, M. Martin, D. Lea) Assimilation interface
24   !!             -   !  2010-10  (C. Ethe, G. Madec) reorganisation of initialisation phase + merge TRC-TRA
[3187]25   !!                 !  2011-05  (S. Pickles) dCSE NEMO optimisations - z index first
[3]26   !!----------------------------------------------------------------------
[888]27
28   !!----------------------------------------------------------------------
[2528]29   !!   stp             : OPA system time-stepping
[3]30   !!----------------------------------------------------------------------
[2528]31   USE step_oce         ! time stepping definition modules
[1594]32#if defined key_top
[2528]33   USE trcstp           ! passive tracer time-stepping      (trc_stp routine)
[1594]34#endif
[392]35#if defined key_agrif
[389]36   USE agrif_opa_sponge ! Momemtum and tracers sponges
37#endif
[2528]38   USE asminc           ! assimilation increments    (tra_asm_inc, dyn_asm_inc routines)
[3432]39   USE timing, ONLY: timing_start, timing_stop, timing_reset, timing_disable
[3837]40   USE arpdebugging, ONLY: dump_array
[3]41   IMPLICIT NONE
42   PRIVATE
43
[2528]44   PUBLIC   stp   ! called by opa.F90
[3]45
[3187]46   !! * Control permutation of array indices
47   !! DCSE_NEMO: warning! dom_oce and zdf_oce public variables are made available
48   !! through the use of step_oce
49#  include "dom_oce_ftrans.h90"
50#  include "zdf_oce_ftrans.h90"
51
[3]52   !! * Substitutions
53#  include "domzgr_substitute.h90"
54#  include "zdfddm_substitute.h90"
55   !!----------------------------------------------------------------------
[2528]56   !! NEMO/OPA 3.3 , NEMO Consortium (2010)
[888]57   !! $Id$
[2528]58   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
[3]59   !!----------------------------------------------------------------------
60CONTAINS
61
[508]62#if defined key_agrif
63   SUBROUTINE stp( )
[1438]64      INTEGER             ::   kstp   ! ocean time-step index
[508]65#else
[467]66   SUBROUTINE stp( kstp )
[1438]67      INTEGER, INTENT(in) ::   kstp   ! ocean time-step index
[467]68#endif
69      !!----------------------------------------------------------------------
[3]70      !!                     ***  ROUTINE stp  ***
71      !!                     
72      !! ** Purpose : - Time stepping of OPA (momentum and active tracer eqs.)
73      !!              - Time stepping of LIM (dynamic and thermodynamic eqs.)
74      !!              - Tme stepping  of TRC (passive tracer eqs.)
75      !!
76      !! ** Method  : -1- Update forcings and data 
77      !!              -2- Update ocean physics
78      !!              -3- Compute the t and s trends
79      !!              -4- Update t and s
80      !!              -5- Compute the momentum trends
81      !!              -6- Update the horizontal velocity
82      !!              -7- Compute the diagnostics variables (rd,N2, div,cur,w)
83      !!              -8- Outputs and diagnostics
84      !!----------------------------------------------------------------------
[888]85      INTEGER ::   jk       ! dummy loop indice
[3]86      INTEGER ::   indic    ! error indicator if < 0
[3187]87#if defined key_z_first
88      INTEGER ::   ji, jj   ! dummy loop indices
89#endif
[3]90      !! ---------------------------------------------------------------------
[3432]91                         CALL timing_start('Step') 
[3]92
[392]93#if defined key_agrif
[389]94      kstp = nit000 + Agrif_Nb_Step()
[2715]95!      IF ( Agrif_Root() .and. lwp) Write(*,*) '---'
96!      IF (lwp) Write(*,*) 'Grid Number',Agrif_Fixed(),' time step ',kstp
[1793]97# if defined key_iomput
[2528]98      IF( Agrif_Nbstepint() == 0 )   CALL iom_swap
[1793]99# endif   
[389]100#endif   
[2528]101                             indic = 0                ! reset to no error condition
[1725]102      IF( kstp /= nit000 )   CALL day( kstp )         ! Calendar (day was already called at nit000 in day_init)
[2528]103                             CALL iom_setkt( kstp )   ! say to iom that we are at time step kstp
[3]104
105      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[888]106      ! Update data, open boundaries, surface boundary condition (including sea-ice)
[3]107      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]108                         CALL timing_start('Boundaries') 
[3]109      IF( lk_dtatem  )   CALL dta_tem( kstp )         ! update 3D temperature data
[888]110      IF( lk_dtasal  )   CALL dta_sal( kstp )         ! update 3D salinity data
111                         CALL sbc    ( kstp )         ! Sea Boundary Condition (including sea-ice)
[35]112      IF( lk_obc     )   CALL obc_dta( kstp )         ! update dynamic and tracer data at open boundaries
[3]113      IF( lk_obc     )   CALL obc_rad( kstp )         ! compute phase velocities at open boundaries
[2528]114      IF( lk_bdy     )   CALL bdy_dta_frs( kstp )     ! update dynamic and tracer data for FRS conditions (BDY)
[3432]115                         ! ARP - no 'section' arg here so the time taken
116                         ! in this region (which can involve IO) is
117                         ! subtracted from the time
118                         ! taken to do the whole step.
119                         CALL timing_stop('Boundaries') 
[911]120
[1438]121      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]122      !  Ocean dynamics : ssh, wn, hdiv, rot                                 !
[1438]123      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]124                         CALL timing_start('Ocean Dyn.') 
[1492]125                         CALL ssh_wzv( kstp )         ! after ssh & vertical velocity
[3432]126                         CALL timing_stop('Ocean Dyn.','section') 
[3]127
128      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]129      ! Ocean physics update                (ua, va, ta, sa used as workspace)
[3]130      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]131                         CALL timing_start('Ocean Phys.') 
[2528]132                         CALL bn2( tsb, rn2b )        ! before Brunt-Vaisala frequency
133                         CALL bn2( tsn, rn2  )        ! now    Brunt-Vaisala frequency
[3432]134                         CALL timing_stop('Ocean Phys.','section') 
[1492]135      !
[3432]136      !  VERTICAL PHYSICS 
137                         CALL timing_start('Vert. Phys.') 
[1662]138                         CALL zdf_bfr( kstp )         ! bottom friction
[2528]139                         
[1492]140      !                                               ! Vertical eddy viscosity and diffusivity coefficients
[2528]141      IF( lk_zdfric  )   CALL zdf_ric( kstp )            ! Richardson number dependent Kz
142      IF( lk_zdftke  )   CALL zdf_tke( kstp )            ! TKE closure scheme for Kz
143      IF( lk_zdfgls  )   CALL zdf_gls( kstp )            ! GLS closure scheme for Kz
144      IF( lk_zdfkpp  )   CALL zdf_kpp( kstp )            ! KPP closure scheme for Kz
145      IF( lk_zdfcst  )   THEN                            ! Constant Kz (reset avt, avm[uv] to the background value)
[1537]146         avt (:,:,:) = rn_avt0 * tmask(:,:,:)
147         avmu(:,:,:) = rn_avm0 * umask(:,:,:)
148         avmv(:,:,:) = rn_avm0 * vmask(:,:,:)
[677]149      ENDIF
[1492]150      IF( ln_rnf_mouth ) THEN                         ! increase diffusivity at rivers mouths
[3187]151#if defined key_z_first
152         DO ji = 1, jpi
153            DO jj = 1, jpj
154               DO jk = 2, nkrnf 
155                  avt(ji,jj,jk) = avt(ji,jj,jk) + 2.e0 * rn_avt_rnf * rnfmsk(ji,jj) * tmask(ji,jj,jk)
156               END DO
157            END DO
158         END DO
159#else
160         DO jk = 2, nkrnf
161            avt(:,:,jk) = avt(:,:,jk) + 2.e0 * rn_avt_rnf * rnfmsk(:,:) * tmask(:,:,jk)
162         END DO
163#endif
[3]164      ENDIF
[1492]165      IF( ln_zdfevd  )   CALL zdf_evd( kstp )         ! enhanced vertical eddy diffusivity
[3]166
[1492]167      IF( lk_zdftmx  )   CALL zdf_tmx( kstp )         ! tidal vertical mixing
[3]168
[888]169      IF( lk_zdfddm .AND. .NOT. lk_zdfkpp )   &
[1492]170         &               CALL zdf_ddm( kstp )         ! double diffusive mixing
[2528]171         
[1492]172                         CALL zdf_mxl( kstp )         ! mixed layer depth
[3]173
[2528]174                                                      ! write TKE or GLS information in the restart file
[1531]175      IF( lrst_oce .AND. lk_zdftke )   CALL tke_rst( kstp, 'WRITE' )
[2528]176      IF( lrst_oce .AND. lk_zdfgls )   CALL gls_rst( kstp, 'WRITE' )
[3432]177
178                         CALL timing_stop('Vert. Phys.','section') 
[1492]179      !
180      !  LATERAL  PHYSICS
181      !
[3432]182                         CALL timing_start('Lateral Phys.') 
183      !
[1492]184      IF( lk_ldfslp ) THEN                            ! slope of lateral mixing
[2528]185                         CALL eos( tsb, rhd )                ! before in situ density
186         IF( ln_zps )    CALL zps_hde( kstp, jpts, tsb, gtsu, gtsv,  &    ! Partial steps: before horizontal gradient
187            &                                      rhd, gru , grv  )      ! of t, s, rd at the last ocean level
188         IF( ln_traldf_grif ) THEN                           ! before slope for Griffies operator
189                         CALL ldf_slp_grif( kstp )
190         ELSE
191                         CALL ldf_slp( kstp, rhd, rn2b )     ! before slope for Madec operator
192         ENDIF
[1481]193      ENDIF
[3]194#if defined key_traldf_c2d
[1492]195      IF( lk_traldf_eiv )   CALL ldf_eiv( kstp )      ! eddy induced velocity coefficient
[2528]196#endif
[3432]197                         CALL timing_stop('Lateral Phys.','section') 
[3]198
[1482]199      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]200      ! diagnostics and outputs             (ua, va, ta, sa used as workspace)
[1482]201      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]202                         CALL timing_start('Diagnostics') 
[1492]203      IF( lk_floats  )   CALL flo_stp( kstp )         ! drifting Floats
204      IF( lk_diahth  )   CALL dia_hth( kstp )         ! Thermocline depth (20 degres isotherm depth)
205      IF( lk_diafwb  )   CALL dia_fwb( kstp )         ! Fresh water budget diagnostics
206      IF( ln_diaptr  )   CALL dia_ptr( kstp )         ! Poleward TRansports diagnostics
[1756]207      IF( lk_diaar5  )   CALL dia_ar5( kstp )         ! ar5 diag
[1635]208                         CALL dia_wri( kstp )         ! ocean model: outputs
[3432]209                         CALL timing_stop('Diagnostics','section') 
[1482]210
[923]211#if defined key_top
[3]212      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
213      ! Passive Tracer Model
214      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[1492]215                         CALL trc_stp( kstp )         ! time-stepping
[3]216#endif
217
218      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]219      ! Active tracers                              (ua, va used as workspace)
[3]220      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]221                             CALL timing_start('Active tracers') 
222
[2528]223                             tsa(:,:,:,:) = 0.e0            ! set tracer trends to zero
[3]224
[2528]225      IF(  ln_asmiau .AND. &
226         & ln_trainc     )   CALL tra_asm_inc( kstp )       ! apply tracer assimilation increment
[467]227                             CALL tra_sbc    ( kstp )       ! surface boundary condition
228      IF( ln_traqsr      )   CALL tra_qsr    ( kstp )       ! penetrative solar radiation qsr
[2528]229      IF( ln_trabbc      )   CALL tra_bbc    ( kstp )       ! bottom heat flux
230      IF( lk_trabbl      )   CALL tra_bbl    ( kstp )       ! advective (and/or diffusive) bottom boundary layer scheme
[467]231      IF( lk_tradmp      )   CALL tra_dmp    ( kstp )       ! internal damping trends
232                             CALL tra_adv    ( kstp )       ! horizontal & vertical advection
[2528]233      IF( lk_zdfkpp      )   CALL tra_kpp    ( kstp )       ! KPP non-local tracer fluxes
[467]234                             CALL tra_ldf    ( kstp )       ! lateral mixing
[392]235#if defined key_agrif
[2528]236                             CALL tra_unswap
[782]237      IF(.NOT. Agrif_Root()) CALL Agrif_Sponge_tra          ! tracers sponge
[2528]238                             CALL tra_swap
[389]239#endif
[1111]240                             CALL tra_zdf    ( kstp )       ! vertical mixing and after tracer fields
[1239]241
[1492]242      IF( ln_dynhpg_imp  ) THEN                             ! semi-implicit hpg (time stepping then eos)
[2528]243         IF( ln_zdfnpc   )   CALL tra_npc( kstp )                ! update after fields by non-penetrative convection
244                             CALL tra_nxt( kstp )                ! tracer fields at next time step
245                             CALL eos    ( tsa, rhd, rhop )      ! Time-filtered in situ density for hpg computation
246         IF( ln_zps      )   CALL zps_hde( kstp, jpts, tsa, gtsu, gtsv,  &    ! zps: time filtered hor. derivative
247            &                                          rhd, gru , grv  )      ! of t, s, rd at the last ocean level
[1492]248         
249      ELSE                                                  ! centered hpg  (eos then time stepping)
[2528]250                             CALL eos    ( tsn, rhd, rhop )      ! now in situ density for hpg computation
251         IF( ln_zps      )   CALL zps_hde( kstp, jpts, tsn, gtsu, gtsv,  &    ! zps: now hor. derivative
252            &                                          rhd, gru , grv  )      ! of t, s, rd at the last ocean level
253         IF( ln_zdfnpc   )   CALL tra_npc( kstp )                ! update after fields by non-penetrative convection
254                             CALL tra_nxt( kstp )                ! tracer fields at next time step
[1239]255      ENDIF
[2528]256                             CALL tra_unswap                ! udate T & S 3D arrays  (to be suppressed)
[3432]257                             CALL timing_stop('Active tracers','section') 
[1481]258
[3]259      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]260      ! Dynamics                                    (ta, sa used as workspace)
[3]261      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]262                               CALL timing_start('Dynamics') 
263
[1492]264                               ua(:,:,:) = 0.e0             ! set dynamics trends to zero
[75]265                               va(:,:,:) = 0.e0
[3]266
[2528]267      IF(  ln_asmiau .AND. &
268         & ln_dyninc       )   CALL dyn_asm_inc( kstp )     ! apply dynamics assimilation increment
[3837]269                               !CALL dump_array(kstp,'un_pre_adv',un(:,:,27), &
270                               !                withHalos=.TRUE.)
271
[3432]272                               !CALL timing_start('dyn_adv')
[1492]273                               CALL dyn_adv( kstp )         ! advection (vector or flux form)
[3432]274                               !CALL timing_stop('dyn_adv','section')
275
[3837]276                               !CALL dump_array(kstp,'ua_pre_vor',ua(:,:,27), &
277                               !                withHalos=.TRUE.)
278
[3432]279                               !CALL timing_start('dyn_vor')
[1492]280                               CALL dyn_vor( kstp )         ! vorticity term including Coriolis
[3432]281                               !CALL timing_stop('dyn_vor','section')
282
[3837]283                               !CALL dump_array(kstp,'ua_pre_ldf',ua(:,:,27), &
284                               !                withHalos=.TRUE.)
285
[3432]286                               !CALL timing_start('dyn_ldf')
[1492]287                               CALL dyn_ldf( kstp )         ! lateral mixing
[3432]288                               !CALL timing_stop('dyn_ldf','section')
289
[392]290#if defined key_agrif
[1492]291      IF(.NOT. Agrif_Root())   CALL Agrif_Sponge_dyn        ! momemtum sponge
[389]292#endif
[3837]293                               !CALL dump_array(kstp,'ua_pre_hpg',ua(:,:,27), &
294                               !                withHalos=.TRUE.)
295
[3432]296                               !CALL timing_start('dyn_hpg')
[1492]297                               CALL dyn_hpg( kstp )         ! horizontal gradient of Hydrostatic pressure
[3432]298                               !CALL timing_stop('dyn_hpg','section')
299
[3837]300                               !CALL dump_array(kstp,'ua_pre_bfr',ua(:,:,27), &
301                               !                withHalos=.TRUE.)
302
[3432]303                               !CALL timing_start('dyn_bfr')
[2528]304                               CALL dyn_bfr( kstp )         ! bottom friction   
[3432]305                               !CALL timing_stop('dyn_bfr','section')
[3837]306                               
307                               !CALL dump_array(kstp,'ua_pre_zdf',ua(:,:,27), &
308                               !                withHalos=.TRUE.)
[3432]309
310                               !CALL timing_start('dyn_zdf')
[1492]311                               CALL dyn_zdf( kstp )         ! vertical diffusion
[3432]312                               !CALL timing_stop('dyn_zdf','section')
[3837]313                               
314                               !CALL dump_array(kstp,'ua_pre_spg',ua(:,:,27), &
315                               !                withHalos=.TRUE.)
[3432]316
317                               !CALL timing_start('dyn_spg')
[1492]318                               CALL dyn_spg( kstp, indic )  ! surface pressure gradient
[3432]319                               !CALL timing_stop('dyn_spg','section')
[3837]320                               !CALL dump_array(kstp,'ua_spg',ua(:,:,27), &
321                               !                withHalos=.TRUE.)
[3432]322
323                               !CALL timing_start('dyn_nxt')
[1492]324                               CALL dyn_nxt( kstp )         ! lateral velocity at next time step
[3432]325                               !CALL timing_stop('dyn_nxt','section')
[3]326
[3837]327                               !CALL timing_stop('dyn_nxt','section')
328
[3432]329                               !CALL timing_start('ssh_nxt')
[1492]330                               CALL ssh_nxt( kstp )         ! sea surface height at next time step
[3432]331                               !CALL timing_stop('ssh_nxt','section')
[593]332
[2528]333      IF( ln_diahsb        )   CALL dia_hsb( kstp )         ! - ML - global conservation diagnostics
[3187]334      IF( lk_diaobs  )         CALL dia_obs( kstp )         ! obs-minus-model (assimilation) diagnostics
335                               !                            ! (call after dynamics update)
[3432]336                               CALL timing_stop('Dynamics','section') 
[2528]337
[3]338      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[888]339      ! Control and restarts
[3]340      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[3432]341                               CALL timing_start('Control') 
342
[1492]343                               CALL stp_ctl( kstp, indic )
344      IF( indic < 0        )   THEN
345                               CALL ctl_stop( 'step: indic < 0' )
346                               CALL dia_wri_state( 'output.abort', kstp )
[1482]347      ENDIF
[1492]348      IF( kstp == nit000   )   CALL iom_close( numror )     ! close input  ocean restart file
349      IF( lrst_oce         )   CALL rst_write    ( kstp )   ! write output ocean restart file
350      IF( lk_obc           )   CALL obc_rst_write( kstp )   ! write open boundary restart file
[3432]351                               ! ARP - no 'section' arg here so the time taken
352                               ! in this region (which can involve IO) is
353                               ! subtracted from the time
354                               ! taken to do the whole step.
355                               CALL timing_stop('Control') 
[508]356      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[1492]357      ! Trends                              (ua, va, ta, sa used as workspace)
[508]358      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[1492]359      IF( nstop == 0 ) THEN                         
360         IF( lk_trddyn     )   CALL trd_dwr( kstp )         ! trends: dynamics
361         IF( lk_trdtra     )   CALL trd_twr( kstp )         ! trends: active tracers
362         IF( lk_trdmld     )   CALL trd_mld( kstp )         ! trends: Mixed-layer
363         IF( lk_trdvor     )   CALL trd_vor( kstp )         ! trends: vorticity budget
[75]364      ENDIF
[3]365
[75]366      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
367      ! Coupled mode
368      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
[1492]369      IF( lk_cpl           )   CALL sbc_cpl_snd( kstp )     ! coupled mode : field exchanges
[508]370      !
[3432]371                               CALL timing_stop('Step', 'section') 
372
[1481]373      !
[3432]374      IF( kstp == nit000   )   CALL timing_reset            ! Exclude first step from timing
375      IF( kstp == (nitend-2) ) CALL timing_disable()        ! Turn off timing two steps from end to avoid the IO
376      !
377
[3]378   END SUBROUTINE stp
379
380   !!======================================================================
381END MODULE step
Note: See TracBrowser for help on using the repository browser.