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 5974 for branches/2015/dev_r5072_UKMO2_OBS_simplification/NEMOGCM/NEMO/OPA_SRC/stpctl.F90 – NEMO

Ignore:
Timestamp:
2015-12-02T11:52:05+01:00 (8 years ago)
Author:
timgraham
Message:

Upgrade to head of trunk (r5936)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2015/dev_r5072_UKMO2_OBS_simplification/NEMOGCM/NEMO/OPA_SRC/stpctl.F90

    r3294 r5974  
    1616   USE oce             ! ocean dynamics and tracers variables 
    1717   USE dom_oce         ! ocean space and time domain variables  
    18    USE sol_oce         ! ocean space and time domain variables  
    1918   USE in_out_manager  ! I/O manager 
    2019   USE lbclnk          ! ocean lateral boundary conditions (or mpp link) 
    2120   USE lib_mpp         ! distributed memory computing 
    22    USE dynspg_oce      ! pressure gradient schemes  
    2321   USE c1d             ! 1D vertical configuration 
    2422 
     
    4341      !! ** Method  : - Save the time step in numstp 
    4442      !!              - Print it each 50 time steps 
    45       !!              - Print solver statistics in numsol  
    46       !!              - Stop the run IF problem for the solver ( indec < 0 ) 
     43      !!              - Stop the run IF problem ( indic < 0 ) 
    4744      !! 
    4845      !! ** Actions :   'time.step' file containing the last ocean time-step 
     
    5047      !!---------------------------------------------------------------------- 
    5148      INTEGER, INTENT( in ) ::   kt         ! ocean time-step index 
    52       INTEGER, INTENT( inout ) ::   kindic  ! indicator of solver convergence 
     49      INTEGER, INTENT( inout ) ::   kindic  ! error indicator 
    5350      !! 
    5451      INTEGER  ::   ji, jj, jk              ! dummy loop indices 
     
    143140      IF( lk_c1d )  RETURN          ! No log file in case of 1D vertical configuration 
    144141 
    145       ! log file (solver or ssh statistics) 
    146       ! -------- 
    147       IF( lk_dynspg_flt ) THEN      ! elliptic solver statistics (if required) 
    148          ! 
    149          IF(lwp) WRITE(numsol,9200) kt, niter, res, SQRT(epsr)/eps       ! Solver 
    150          ! 
    151          IF( kindic < 0 .AND. zsmin > 0.e0 .AND. zumax <= 20.e0 ) THEN   ! create a abort file if problem found  
    152             IF(lwp) THEN 
    153                WRITE(numout,*) ' stpctl: the elliptic solver DO not converge or explode' 
    154                WRITE(numout,*) ' ====== ' 
    155                WRITE(numout,9200) kt, niter, res, sqrt(epsr)/eps 
    156                WRITE(numout,*) 
    157                WRITE(numout,*) ' stpctl: output of last fields' 
    158                WRITE(numout,*) ' ======  ' 
    159             ENDIF 
    160          ENDIF 
    161          ! 
    162       ELSE                                   !* ssh statistics (and others...) 
    163          IF( kt == nit000 .AND. lwp ) THEN   ! open ssh statistics file (put in solver.stat file) 
    164             CALL ctl_opn( numsol, 'solver.stat', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 
    165          ENDIF 
    166          ! 
    167          zssh2 = SUM( sshn(:,:) * sshn(:,:) * tmask_i(:,:) ) 
    168          IF( lk_mpp )   CALL mpp_sum( zssh2 )      ! sum over the global domain 
    169          ! 
    170          IF(lwp) WRITE(numsol,9300) kt, zssh2, zumax, zsmin      ! ssh statistics 
    171          ! 
     142      ! log file (ssh statistics) 
     143      ! --------                                   !* ssh statistics (and others...) 
     144      IF( kt == nit000 .AND. lwp ) THEN   ! open ssh statistics file (put in solver.stat file) 
     145         CALL ctl_opn( numsol, 'solver.stat', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, narea ) 
    172146      ENDIF 
     147      ! 
     148      zssh2 = SUM( sshn(:,:) * sshn(:,:) * tmask_i(:,:) ) 
     149      IF( lk_mpp )   CALL mpp_sum( zssh2 )      ! sum over the global domain 
     150      ! 
     151      IF(lwp) WRITE(numsol,9300) kt, zssh2, zumax, zsmin      ! ssh statistics 
     152      ! 
    173153 
    1741549200  FORMAT('it:', i8, ' iter:', i4, ' r: ',e16.10, ' b: ',e16.10 ) 
Note: See TracChangeset for help on using the changeset viewer.