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.
trcstp.F90 in trunk/NEMO/TOP_SRC/TRP – NEMO

source: trunk/NEMO/TOP_SRC/TRP/trcstp.F90 @ 433

Last change on this file since 433 was 433, checked in by opalod, 18 years ago

nemo_v1_update_044 : CT : update the passive tracers TOP component and the standard GYRE configuration

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 3.6 KB
Line 
1MODULE trcstp
2   !!======================================================================
3   !!                       ***  MODULE trcstp  ***
4   !! Time-stepping    : time loop of opa for passive tracer
5   !!======================================================================
6#if defined key_passivetrc
7   !!----------------------------------------------------------------------
8   !!   trc_stp      : passive tracer system time-stepping
9   !!----------------------------------------------------------------------
10   !! * Modules used
11   USE oce_trc          ! ocean dynamics and active tracers variables
12   USE trc              ! ocean passive tracers variables
13   USE trctrp           ! passive tracers transport
14   USE trctrp1d         ! passive tracers transport 1D configuration
15   USE trcsms           ! passive tracers sources and sinks
16   USE prtctl_trc       ! Print control for debbuging
17   USE trcdia
18   USE trcdit
19   USE trcrst
20   USE ini1d
21
22   IMPLICIT NONE
23   PRIVATE
24
25   !! * Routine accessibility
26   PUBLIC trc_stp           ! called by step
27   !!----------------------------------------------------------------------
28   !!   TOP 1.0 , LOCEAN-IPSL (2005)
29   !! $Header$
30   !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt
31   !!----------------------------------------------------------------------
32
33CONTAINS
34
35   SUBROUTINE trc_stp( kt, kindic )
36      !!-------------------------------------------------------------------
37      !!                     ***  ROUTINE trc_stp  ***
38      !!                     
39      !! ** Purpose : Time loop of opa for passive tracer
40      !!
41      !! ** Method  :
42      !!              Compute the passive tracers trends
43      !!              Update the passive tracers
44      !!
45      !! History :
46      !!   9.0  !  04-03  (C. Ethe)  Original
47      !!-------------------------------------------------------------------
48      !! * Arguments
49      INTEGER, INTENT( in ) ::  kt  ! ocean time-step index
50      INTEGER, INTENT( in ) ::  kindic
51      CHARACTER (len=25) :: charout
52
53      ! this ROUTINE is called only every ndttrc time step
54      IF( MOD( kt , ndttrc ) /= 0 ) RETURN
55
56      ! tracers: sink and source
57      IF(ln_ctl) THEN
58         WRITE(charout,FMT="('kt =', I4,'  d/m/y =',I2,I2,I4)") kt, nday, nmonth, nyear
59         CALL prt_ctl_trc_info(charout)
60      ENDIF
61
62
63      CALL trc_sms( kt )
64
65      IF(ln_ctl)   THEN  ! print mean trends (used for debugging)
66         WRITE(charout, FMT="('SMS')")
67         CALL prt_ctl_trc_info(charout)
68         CALL prt_ctl_trc(tab4d=tra, mask=tmask, clinfo=ctrcnm)
69      ENDIF
70
71      ! transport of passive tracers
72      IF( lk_cfg_1d  )  THEN
73         CALL trc_trp_1d( kt )   
74      ELSE
75         CALL trc_trp( kt )
76      ENDIF
77
78
79      IF(ln_ctl)   THEN  ! print mean trends (used for debugging)
80         WRITE(charout, FMT="('TRP')")
81         CALL prt_ctl_trc_info(charout)
82         CALL prt_ctl_trc(tab4d=tra, mask=tmask, clinfo=ctrcnm)
83      ENDIF
84
85      CALL trc_wri( kt )            ! outputs
86
87      CALL trc_dia( kt, kindic )     ! diagnostics
88
89
90   END SUBROUTINE trc_stp
91
92#else
93   !!----------------------------------------------------------------------
94   !!   Default key                                     NO passive tracers
95   !!----------------------------------------------------------------------
96CONTAINS
97   SUBROUTINE trc_stp( kt )        ! Empty routine
98      INTEGER, INTENT(in) :: kt
99      WRITE(*,*) 'trc_stp: You should not have seen this print! error?', kt
100   END SUBROUTINE trc_stp
101#endif
102
103   !!======================================================================
104END MODULE trcstp
Note: See TracBrowser for help on using the repository browser.