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.
stpctl.F90 in branches/UKMO/2015_CO6_CO5_zenv_wr_direct_dwl_temp/NEMOGCM/NEMO/OFF_SRC – NEMO

source: branches/UKMO/2015_CO6_CO5_zenv_wr_direct_dwl_temp/NEMOGCM/NEMO/OFF_SRC/stpctl.F90 @ 5418

Last change on this file since 5418 was 5418, checked in by deazer, 9 years ago

Removed SVN KEYWORDS ready for adding code changes before fcm merges

File size: 2.8 KB
Line 
1MODULE stpctl
2   !!======================================================================
3   !!                       ***  MODULE  stpctl  ***
4   !! Ocean run control :  Off-line case, only save the time step in numstp
5   !!======================================================================
6   !! History :  OPA  ! 1991-03  (G. Madec) Original code
7   !!            6.0  ! 1992-06  (M. Imbard)
8   !!            8.0  ! 1997-06  (A.M. Treguier)
9   !!   NEMO     1.0  ! 2002-06  (G. Madec)  F90: Free form and module
10   !!            2.0  ! 2009-07  (G. Madec)  Add statistic for time-spliting
11   !!----------------------------------------------------------------------
12
13   !!----------------------------------------------------------------------
14   !!   stp_ctl      : Control the run
15   !!----------------------------------------------------------------------
16   USE oce             ! ocean dynamics and tracers variables
17   USE dom_oce         ! ocean space and time domain variables
18   USE in_out_manager  ! I/O manager
19   USE lbclnk          ! ocean lateral boundary conditions (or mpp link)
20   USE lib_mpp         ! distributed memory computing
21
22   IMPLICIT NONE
23   PRIVATE
24
25   PUBLIC   stp_ctl    ! routine called by opa.F90
26   
27   !!----------------------------------------------------------------------
28   !! NEMO/OFF 3.3 , NEMO Consortium (2010)
29   !! $Id$
30   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
31   !!----------------------------------------------------------------------
32CONTAINS
33
34   SUBROUTINE stp_ctl( kt, kindic )
35      !!----------------------------------------------------------------------
36      !!                    ***  ROUTINE stp_ctl  ***
37      !!                     
38      !! ** Purpose :   Control the run
39      !!
40      !! ** Method  : - Save the time step in numstp
41      !!
42      !! ** Actions :   'time.step' file containing the last ocean time-step
43      !!----------------------------------------------------------------------
44      INTEGER, INTENT(in   ) ::   kt      ! ocean time-step index
45      INTEGER, INTENT(inout) ::   kindic  ! indicator of solver convergence
46      !!----------------------------------------------------------------------
47      !
48      IF( kt == nit000 .AND. lwp ) THEN
49         WRITE(numout,*)
50         WRITE(numout,*) 'stp_ctl : time-stepping control'
51         WRITE(numout,*) '~~~~~~~'
52         ! open time.step file
53         CALL ctl_opn( numstp, 'time.step', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea )
54      ENDIF
55      !
56      IF(lwp) WRITE ( numstp, '(1x, i8)' )   kt      !* save the current time step in numstp
57      IF(lwp) REWIND( numstp )                       !  --------------------------
58      !
59   END SUBROUTINE stp_ctl
60
61   !!======================================================================
62END MODULE stpctl
Note: See TracBrowser for help on using the repository browser.