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 4403 – NEMO

Changeset 4403


Ignore:
Timestamp:
2014-02-04T13:11:47+01:00 (10 years ago)
Author:
trackstand2
Message:

Added optional atStep arg to dump_array

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2011/DEV_r2739_STFC_dCSE/NEMOGCM/NEMO/OPA_SRC/arpdebugging.f90

    r3837 r4403  
    1212 
    1313    SUBROUTINE dump_rarray(count, name, field1, field2, withHalos, & 
    14                            toGlobal) 
     14                           toGlobal, atStep) 
    1515      IMPLICIT none 
    1616      INTEGER,           INTENT(in) :: count  ! What timestep we're on 
     
    2020      LOGICAL,           INTENT(in),                 OPTIONAL :: withHalos 
    2121      LOGICAL,           INTENT(in),                 OPTIONAL :: toGlobal 
     22      INTEGER,           INTENT(in),                 OPTIONAL :: atStep 
    2223      ! Locals 
    2324      INTEGER           :: ji, jj 
     
    2829      CHARACTER (LEN=13), PARAMETER :: fmt_var = "(2I4,2E18.10)" 
    2930 
     31      IF(PRESENT(atStep))THEN 
     32         ! If this isn't the desired time-step to dump then don't 
     33         IF(count /= atStep)RETURN 
     34      END IF 
     35 
    3036      IF(PRESENT(field2))THEN 
    3137         shape1= SHAPE(field1) 
     
    128134 
    129135    SUBROUTINE dump_iarray(count, name, field1, field2, withHalos, & 
    130                            toGlobal) 
     136                           toGlobal, atStep) 
    131137      IMPLICIT none 
    132138      INTEGER,           INTENT(in) :: count  ! What timestep we're on 
     
    136142      LOGICAL,           INTENT(in),                 OPTIONAL :: withHalos 
    137143      LOGICAL,           INTENT(in),                 OPTIONAL :: toGlobal 
     144      INTEGER,           INTENT(in),                 OPTIONAL :: atStep 
    138145      ! Locals 
    139146      INTEGER           :: ji, jj 
     
    144151      CHARACTER (LEN=13), PARAMETER :: fmt_var = "(2I4,(I6))" 
    145152 
     153      IF(PRESENT(atStep))THEN 
     154         ! If this isn't the desired time-step to dump then don't 
     155         IF(count /= atStep)RETURN 
     156      END IF 
     157 
    146158      IF(PRESENT(field2))THEN 
    147159         shape1= SHAPE(field1) 
Note: See TracChangeset for help on using the changeset viewer.