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 @ 340

Last change on this file since 340 was 334, checked in by opalod, 19 years ago

nemo_v1_update_022 : CE + RB + CT : add print control possibility

  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 3.1 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 trcsms           ! passive tracers sources and sinks
15   USE prtctl_trc          ! Print control for debbuging
16   USE trcdia
17   USE trcrst
18
19   IMPLICIT NONE
20   PRIVATE
21
22   !! * Routine accessibility
23   PUBLIC trc_stp           ! called by step
24   !!----------------------------------------------------------------------
25   !!   OPA 9.0 , LODYC-IPSL (2003)
26   !!----------------------------------------------------------------------
27
28CONTAINS
29
30   SUBROUTINE trc_stp( kt, kindic )
31      !!-------------------------------------------------------------------
32      !!                     ***  ROUTINE trc_stp  ***
33      !!                     
34      !! ** Purpose : Time loop of opa for passive tracer
35      !!
36      !! ** Method  :
37      !!              Compute the passive tracers trends
38      !!              Update the passive tracers
39      !!
40      !! History :
41      !!   9.0  !  04-03  (C. Ethe)  Original
42      !!-------------------------------------------------------------------
43      !! * Arguments
44      INTEGER, INTENT( in ) ::  kt  ! ocean time-step index
45      INTEGER, INTENT( in ) ::  kindic
46      CHARACTER (len=25) :: charout
47
48      IF( kt == nit000 )    CALL trc_dia( kt, kindic )     ! diagnostics init.
49
50      ! this ROUTINE is called only every ndttrc time step
51      IF( MOD( kt , ndttrc ) /= 0 ) RETURN
52
53      ! tracers: sink and source
54      IF(ln_ctl) THEN
55         WRITE(charout,FMT="('kt =', I4,'  d/m/y =',I2,I2,I4)") kt, nday, nmonth, nyear
56         CALL prt_ctl_trc_info(charout)
57      ENDIF
58
59
60      CALL trc_sms( kt )
61
62      IF(ln_ctl)   THEN  ! print mean trends (used for debugging)
63         WRITE(charout, FMT="('sms')")
64         CALL prt_ctl_trc_info(charout)
65         CALL prt_ctl_trc(tab4d=tra, mask=tmask, clinfo=ctrcnm)
66      ENDIF
67 
68
69      ! transport of passive tracers
70
71      CALL trc_trp( kt )
72
73      CALL trc_wri( kt )            ! outputs
74
75      CALL trc_dia( kt, kindic )     ! diagnostics
76
77
78   END SUBROUTINE trc_stp
79
80#else
81   !!----------------------------------------------------------------------
82   !!   Default key                                     NO passive tracers
83   !!----------------------------------------------------------------------
84CONTAINS
85   SUBROUTINE trc_stp( kt )        ! Empty routine
86      INTEGER, INTENT(in) :: kt
87      WRITE(*,*) 'trc_stp: You should not have seen this print! error?', kt
88   END SUBROUTINE trc_stp
89#endif
90
91   !!======================================================================
92END MODULE trcstp
Note: See TracBrowser for help on using the repository browser.