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 2528 for trunk/NEMOGCM/NEMO/OFF_SRC/stpctl.F90 – NEMO

Ignore:
Timestamp:
2010-12-27T18:33:53+01:00 (13 years ago)
Author:
rblod
Message:

Update NEMOGCM from branch nemo_v3_3_beta

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMOGCM/NEMO/OFF_SRC/stpctl.F90

    • Property svn:eol-style deleted
    r1152 r2528  
    11MODULE stpctl 
    2    !!============================================================================== 
     2   !!====================================================================== 
    33   !!                       ***  MODULE  stpctl  *** 
    4    !! Ocean run control :  gross check of the ocean time stepping 
    5    !!============================================================================== 
     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   !!---------------------------------------------------------------------- 
    612 
    713   !!---------------------------------------------------------------------- 
    814   !!   stp_ctl      : Control the run 
    915   !!---------------------------------------------------------------------- 
    10    !! * Modules used 
    1116   USE oce             ! ocean dynamics and tracers variables 
    1217   USE dom_oce         ! ocean space and time domain variables  
     
    1823   PRIVATE 
    1924 
    20    !! * Accessibility 
    21    PUBLIC stp_ctl           ! routine called by step.F90 
     25   PUBLIC   stp_ctl    ! routine called by opa.F90 
     26    
    2227   !!---------------------------------------------------------------------- 
    23  
     28   !! NEMO/OFF 3.3 , NEMO Consortium (2010) 
     29   !! $Id$ 
     30   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt) 
     31   !!---------------------------------------------------------------------- 
    2432CONTAINS 
    2533 
    26    SUBROUTINE stp_ctl( kt ) 
     34   SUBROUTINE stp_ctl( kt, kindic ) 
    2735      !!---------------------------------------------------------------------- 
    2836      !!                    ***  ROUTINE stp_ctl  *** 
     
    3139      !! 
    3240      !! ** Method  : - Save the time step in numstp 
    33       !!              - Print it each 50 time steps 
    34       !!              - Print solver statistics in numsol  
    35       !!              - Stop the run IF problem for the solver ( indec < 0 ) 
    3641      !! 
    37       !! History : 
    38       !!        !  91-03  () 
    39       !!        !  91-11  (G. Madec) 
    40       !!        !  92-06  (M. Imbard) 
    41       !!        !  97-06  (A.M. Treguier) 
    42       !!   8.5  !  02-06  (G. Madec)  F90: Free form and module 
     42      !! ** Actions :   'time.step' file containing the last ocean time-step 
    4343      !!---------------------------------------------------------------------- 
    44       !! * Arguments 
    45       INTEGER, INTENT( in ) ::   kt         ! ocean time-step index 
    46  
     44      INTEGER, INTENT(in   ) ::   kt      ! ocean time-step index 
     45      INTEGER, INTENT(inout) ::   kindic  ! indicator of solver convergence 
    4746      !!---------------------------------------------------------------------- 
    48       !!   OPA 9.0 , LOCEAN-IPSL  (2005) 
    49       !!   $Id$ 
    50       !!   This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt 
    51       !!---------------------------------------------------------------------- 
    52  
     47      ! 
    5348      IF( kt == nit000 .AND. lwp ) THEN 
    5449         WRITE(numout,*) 
     
    5651         WRITE(numout,*) '~~~~~~~' 
    5752         ! open time.step file 
    58          CALL ctlopn( numstp, 'time.step', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', 1, numout, lwp, 1 ) 
     53         CALL ctl_opn( numstp, 'time.step', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 
    5954      ENDIF 
    60  
    61       ! save the current time step in numstp 
    62       ! ------------------------------------ 
    63       IF(lwp) WRITE(numstp,9100) kt 
    64       IF(lwp) REWIND(numstp) 
    65 9100  FORMAT(1x, i8) 
    66  
    67  
     55      ! 
     56      IF(lwp) WRITE ( numstp, '(1x, i8)' )   kt      !* save the current time step in numstp 
     57      IF(lwp) REWIND( numstp )                       !  -------------------------- 
     58      ! 
    6859   END SUBROUTINE stp_ctl 
    6960 
Note: See TracChangeset for help on using the changeset viewer.