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.
Changeset 13662 for NEMO/branches/2019/dev_r11842_SI3-10_EAP/src/OCE/step.F90 – NEMO

Ignore:
Timestamp:
2020-10-22T20:49:56+02:00 (4 years ago)
Author:
clem
Message:

update to almost r4.0.4

Location:
NEMO/branches/2019/dev_r11842_SI3-10_EAP
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11842_SI3-10_EAP

    • Property svn:externals
      •  

        old new  
        1 ^/utils/build/arch@HEAD       arch 
        2 ^/utils/build/makenemo@HEAD   makenemo 
        3 ^/utils/build/mk@HEAD         mk 
        4 ^/utils/tools@HEAD            tools 
        5 ^/vendors/AGRIF/dev@HEAD      ext/AGRIF 
        6 ^/vendors/FCM@HEAD            ext/FCM 
        7 ^/vendors/IOIPSL@HEAD         ext/IOIPSL 
         1^/utils/build/arch@12130      arch 
         2^/utils/build/makenemo@12191  makenemo 
         3^/utils/build/mk@11662        mk 
         4^/utils/tools_r4.0-HEAD@12672 tools 
         5^/vendors/AGRIF/dev@10586     ext/AGRIF 
         6^/vendors/FCM@10134           ext/FCM 
         7^/vendors/IOIPSL@9655         ext/IOIPSL 
         8 
         9# SETTE mapping (inactive) 
         10#^/utils/CI/sette@12135        sette 
  • NEMO/branches/2019/dev_r11842_SI3-10_EAP/src/OCE/step.F90

    r11536 r13662  
    7676      !!---------------------------------------------------------------------- 
    7777      INTEGER ::   ji, jj, jk   ! dummy loop indice 
    78       INTEGER ::   indic        ! error indicator if < 0 
    7978!!gm kcall can be removed, I guess 
    8079      INTEGER ::   kcall        ! optional integer argument (dom_vvl_sf_nxt) 
    8180      !! --------------------------------------------------------------------- 
    8281#if defined key_agrif 
     82      IF( nstop > 0 ) RETURN   ! avoid to go further if an error was detected during previous time step (child grid) 
    8383      kstp = nit000 + Agrif_Nb_Step() 
    8484      IF( lk_agrif_debug ) THEN 
     
    9797      ! update I/O and calendar  
    9898      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    99                              indic = 0                ! reset to no error condition 
    100                               
    10199      IF( kstp == nit000 ) THEN                       ! initialize IOM context (must be done after nemo_init for AGRIF+XIOS+OASIS) 
    102100                             CALL iom_init(      cxios_context          )  ! for model grid (including passible AGRIF zoom) 
     
    154152      IF( l_ldftra_time .OR. l_ldfeiv_time )   CALL ldf_tra( kstp )       !       and/or eiv coeff. 
    155153      IF( l_ldfdyn_time                    )   CALL ldf_dyn( kstp )       ! eddy viscosity coeff.  
    156  
    157154      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    158155      !  Ocean dynamics : hdiv, ssh, e3, u, v, w 
     
    188185         IF(.NOT.ln_linssh) CALL dom_vvl_sf_nxt( kstp, kcall=2 )  ! after vertical scale factors (update depth average component) 
    189186      ENDIF 
    190                          CALL dyn_zdf       ( kstp )  ! vertical diffusion 
    191  
    192       IF( ln_dynspg_ts ) THEN                          
     187                            CALL dyn_zdf    ( kstp )  ! vertical diffusion 
     188      IF( ln_dynspg_ts ) THEN                         ! vertical scale factors and vertical velocity need to be updated 
    193189                            CALL wzv        ( kstp )              ! now cross-level velocity  
    194190         IF( ln_zad_Aimp )  CALL wAimp      ( kstp )  ! Adaptive-implicit vertical advection partitioning 
    195191      ENDIF 
     192       
    196193 
    197194      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     
    205202      IF( ln_floats  )   CALL flo_stp ( kstp )        ! drifting Floats 
    206203      IF( ln_diacfl  )   CALL dia_cfl ( kstp )        ! Courant number diagnostics 
    207       IF( lk_diahth  )   CALL dia_hth ( kstp )        ! Thermocline depth (20 degres isotherm depth) 
     204                         CALL dia_hth ( kstp )        ! Thermocline depth (20 degres isotherm depth) 
    208205      IF( ln_diadct  )   CALL dia_dct ( kstp )        ! Transports 
    209206                         CALL dia_ar5 ( kstp )        ! ar5 diag 
     207      IF( ln_diaptr  )   CALL dia_ptr                 ! Poleward adv/ldf TRansports diagnostics 
    210208      IF( ln_diaharm )   CALL dia_harm( kstp )        ! Tidal harmonic analysis 
    211209                         CALL dia_wri ( kstp )        ! ocean model: outputs 
     
    243241                         CALL tra_ldf       ( kstp )  ! lateral mixing 
    244242 
    245 !!gm : why CALL to dia_ptr has been moved here??? (use trends info?) 
    246       IF( ln_diaptr  )   CALL dia_ptr                 ! Poleward adv/ldf TRansports diagnostics 
    247 !!gm 
    248243                         CALL tra_zdf       ( kstp )  ! vertical mixing and after tracer fields 
    249244      IF( ln_zdfnpc  )   CALL tra_npc       ( kstp )  ! update after fields by non-penetrative convection 
     
    283278#if defined key_agrif 
    284279      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    285       ! AGRIF 
     280      ! AGRIF recursive integration 
    286281      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<       
    287282                         CALL Agrif_Integrate_ChildGrids( stp )  ! allows to finish all the Child Grids before updating 
    288  
    289                          IF( Agrif_NbStepint() == 0 ) CALL Agrif_update_all( ) ! Update all components 
    290 #endif 
     283#endif 
     284      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     285      ! Control 
     286      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
     287                         CALL stp_ctl      ( kstp ) 
     288                          
     289#if defined key_agrif 
     290      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     291      ! AGRIF update 
     292      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<       
     293      IF( Agrif_NbStepint() == 0 .AND. nstop == 0 ) THEN 
     294                         CALL Agrif_update_all( )                  ! Update all components 
     295      ENDIF 
     296#endif 
     297 
    291298      IF( ln_diaobs  )   CALL dia_obs      ( kstp )      ! obs-minus-model (assimilation) diagnostics (call after dynamics update) 
    292299 
    293300      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    294       ! Control 
    295       !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    296                          CALL stp_ctl      ( kstp, indic ) 
    297                           
     301      ! File manipulation at the end of the first time step 
     302      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<                          
    298303      IF( kstp == nit000 ) THEN                          ! 1st time step only 
    299304                                        CALL iom_close( numror )   ! close input  ocean restart file 
     
    306311      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 
    307312!!gm why lk_oasis and not lk_cpl ???? 
    308       IF( lk_oasis   )   CALL sbc_cpl_snd( kstp )     ! coupled mode : field exchanges 
     313      IF( lk_oasis .AND. nstop == 0 )   CALL sbc_cpl_snd( kstp )     ! coupled mode : field exchanges 
    309314      ! 
    310315#if defined key_iomput 
    311       IF( kstp == nitend .OR. indic < 0 ) THEN  
    312                       CALL iom_context_finalize(      cxios_context          ) ! needed for XIOS+AGRIF 
    313                       IF(lrxios) CALL iom_context_finalize(      crxios_context          ) 
     316      !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     317      ! Finalize contextes if end of simulation or error detected 
     318      !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<                          
     319      IF( kstp == nitend .OR. nstop > 0 ) THEN  
     320                      CALL iom_context_finalize(       cxios_context         ) ! needed for XIOS+AGRIF 
     321         IF( lrxios ) CALL iom_context_finalize(      crxios_context         ) 
    314322         IF( ln_crs ) CALL iom_context_finalize( trim(cxios_context)//"_crs" ) !  
    315323      ENDIF 
     
    319327      ! 
    320328   END SUBROUTINE stp 
    321     
     329   ! 
    322330   !!====================================================================== 
    323331END MODULE step 
Note: See TracChangeset for help on using the changeset viewer.