MODULE trcstp !!====================================================================== !! *** MODULE trcstp *** !! Time-stepping : time loop of opa for passive tracer !!====================================================================== #if defined key_top !!---------------------------------------------------------------------- !! trc_stp : passive tracer system time-stepping !!---------------------------------------------------------------------- !! * Modules used USE oce_trc ! ocean dynamics and active tracers variables USE trc USE trctrp ! passive tracers transport USE trcsms ! passive tracers sources and sinks USE prtctl_trc ! Print control for debbuging USE trcdia USE trcwri USE trcrst USE trdmod_trc_oce USE trdmld_trc USE iom USE in_out_manager IMPLICIT NONE PRIVATE !! * Routine accessibility PUBLIC trc_stp ! called by step !!---------------------------------------------------------------------- !! TOP 1.0 , LOCEAN-IPSL (2005) !! $Id: trcstp.F90 1285 2009-02-03 13:38:51Z cetlod $ !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt !!---------------------------------------------------------------------- CONTAINS SUBROUTINE trc_stp( kt ) !!------------------------------------------------------------------- !! *** ROUTINE trc_stp *** !! !! ** Purpose : Time loop of opa for passive tracer !! !! ** Method : !! Compute the passive tracers trends !! Update the passive tracers !! !! History : !! 9.0 ! 04-03 (C. Ethe) Original !!------------------------------------------------------------------- !! * Arguments INTEGER, INTENT( in ) :: kt ! ocean time-step index CHARACTER (len=25) :: charout ! this ROUTINE is called only every nn_dttrc time step IF( MOD( kt , nn_dttrc ) /= 0 ) RETURN IF(ln_ctl) THEN WRITE(charout,FMT="('kt =', I4,' d/m/y =',I2,I2,I4)") kt, nday, nmonth, nyear CALL prt_ctl_trc_info(charout) ENDIF tra(:,:,:,:) = 0. IF( kt == nittrc000 .AND. lk_trdmld_trc ) & & CALL trd_mld_trc_init ! trends: Mixed-layer CALL trc_rst_opn( kt ) ! Open tracer restart file CALL trc_sms( kt ) ! tracers: sink and source CALL trc_trp( kt ) ! transport of passive tracers IF( kt == nittrc000 ) CALL iom_close( numrtr ) ! close input passive tracers restart file IF( lrst_trc ) CALL trc_rst_wri( kt ) ! write tracer restart file IF( lk_iomput ) THEN CALL trc_wri( kt ) ! output of passive tracers ELSE CALL trc_dia( kt ) ! diagnostics ENDIF IF( lk_trdmld_trc ) CALL trd_mld_trc( kt ) ! trends: Mixed-layer END SUBROUTINE trc_stp #else !!---------------------------------------------------------------------- !! Default key NO passive tracers !!---------------------------------------------------------------------- CONTAINS SUBROUTINE trc_stp( kt ) ! Empty routine INTEGER, INTENT(in) :: kt WRITE(*,*) 'trc_stp: You should not have seen this print! error?', kt END SUBROUTINE trc_stp #endif !!====================================================================== END MODULE trcstp