/[MITgcm]/MITgcm/model/src/do_statevars_diags.F
ViewVC logotype

Diff of /MITgcm/model/src/do_statevars_diags.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.9 by mlosch, Thu Jun 7 13:47:07 2007 UTC revision 1.11 by jmc, Tue Sep 4 16:49:44 2007 UTC
# Line 11  C     !INTERFACE: Line 11  C     !INTERFACE:
11        SUBROUTINE DO_STATEVARS_DIAGS( myTime, seqFlag, myIter, myThid )        SUBROUTINE DO_STATEVARS_DIAGS( myTime, seqFlag, myIter, myThid )
12  C     !DESCRIPTION: \bv  C     !DESCRIPTION: \bv
13  C     *==========================================================*  C     *==========================================================*
14  C     | SUBROUTINE DO_STATEVARS_DIAGS                                  C     | SUBROUTINE DO_STATEVARS_DIAGS
15  C     | o Controlling routine for state variables diagnostics  C     | o Controlling routine for state variables diagnostics
16  C     *==========================================================*  C     *==========================================================*
17  C     | Computing diagnostics of the model state (state-variables)  C     | Computing diagnostics of the model state (state-variables)
18  C     | is done at this level ;  C     | is done at this level ;
19  C     | by contrast, other diagnostics (fluxes, tendencies)  C     | by contrast, other diagnostics (fluxes, tendencies)
20  C     | remain within the computation sequence.    C     | remain within the computation sequence.
21  C     *==========================================================*  C     *==========================================================*
22  C     \ev  C     \ev
23    
# Line 50  C     selectVars :: select which group o Line 50  C     selectVars :: select which group o
50  C            = 1 :: fill-in diagnostics for tracer   variables only  C            = 1 :: fill-in diagnostics for tracer   variables only
51  C            = 2 :: fill-in diagnostics for momentum variables only  C            = 2 :: fill-in diagnostics for momentum variables only
52  C            = 3 :: fill-in diagnostics for momentum & tracer variables  C            = 3 :: fill-in diagnostics for momentum & tracer variables
53  C            = 4 :: fill-in state variable tendency diagnostics the second time  C            = 4 :: fill-in state variable tendency diagnostics the second time
54  C     bi,bj      :: tile indices  C     bi,bj      :: tile indices
55        INTEGER selectVars        INTEGER selectVars
56    #if defined(ALLOW_THSICE) || defined(ALLOW_LAND)
57        INTEGER bi, bj        INTEGER bi, bj
58    #endif
59    
60  C--   Fill-in Diagnostics pkg storage array (for state-variables)  C--   Fill-in Diagnostics pkg storage array (for state-variables)
61        IF ( usediagnostics ) THEN        IF ( usediagnostics ) THEN
62    
63  C-    select which group of state-var diagnostics to fill-in,  C-    select which group of state-var diagnostics to fill-in,
64  C      depending on: where this S/R is called from (seqFlag)  C      depending on: where this S/R is called from (seqFlag)
65  C                    and stagger/synchronous TimeStep  C                    and stagger/synchronous TimeStep
66          selectVars = 0          selectVars = 0
67          IF ( staggerTimeStep ) THEN          IF ( staggerTimeStep ) THEN
68            IF ( seqFlag.EQ.0 ) selectVars = 2            IF ( seqFlag.EQ.0 ) selectVars = 2
69            IF ( seqFlag.EQ.1 ) selectVars = 1            IF ( seqFlag.EQ.1 ) selectVars = 1
70          ELSE          ELSE
# Line 73  C                    and stagger/synchro Line 75  C                    and stagger/synchro
75    
76  #ifdef ALLOW_PTRACERS  #ifdef ALLOW_PTRACERS
77          IF ( (selectVars.EQ.1 .OR. selectVars.EQ.3)          IF ( (selectVars.EQ.1 .OR. selectVars.EQ.3)
78       &      .AND. usePTRACERS ) THEN       &      .AND. usePTRACERS ) THEN
79            CALL PTRACERS_DIAGNOSTICS_FILL(myThid)            CALL PTRACERS_DIAGNOSTICS_STATE( myThid )
80          ENDIF          ENDIF
81  #endif  #endif
82    
83  #ifdef ALLOW_SEAICE  #ifdef ALLOW_SEAICE
84         IF ( seqFlag.EQ.0 .AND. useSEAICE ) THEN         IF ( seqFlag.EQ.0 .AND. useSEAICE ) THEN
85          CALL SEAICE_DIAGNOSTICS_FILL( myTime, myIter, myThid )          CALL SEAICE_DIAGNOSTICS_STATE( myTime, myIter, myThid )
86         ENDIF         ENDIF
87  #endif /* ALLOW_SEAICE */  #endif /* ALLOW_SEAICE */
88    
# Line 88  C                    and stagger/synchro Line 90  C                    and stagger/synchro
90         IF ( seqFlag.EQ.0 .AND. useThSIce ) THEN         IF ( seqFlag.EQ.0 .AND. useThSIce ) THEN
91          DO bj=myByLo(myThid),myByHi(myThid)          DO bj=myByLo(myThid),myByHi(myThid)
92           DO bi=myBxLo(myThid),myBxHi(myThid)           DO bi=myBxLo(myThid),myBxHi(myThid)
93            CALL THSICE_DIAGNOSTICS_FILL( myTime,myIter, bi,bj, myThid )            CALL THSICE_DIAGNOSTICS_STATE( myTime,myIter,bi,bj,myThid )
94           ENDDO           ENDDO
95          ENDDO          ENDDO
96         ENDIF         ENDIF
# Line 98  C                    and stagger/synchro Line 100  C                    and stagger/synchro
100         IF ( seqFlag.EQ.0 .AND. useLand ) THEN         IF ( seqFlag.EQ.0 .AND. useLand ) THEN
101          DO bj=myByLo(myThid),myByHi(myThid)          DO bj=myByLo(myThid),myByHi(myThid)
102           DO bi=myBxLo(myThid),myBxHi(myThid)           DO bi=myBxLo(myThid),myBxHi(myThid)
103            CALL LAND_DIAGNOSTICS_FILL( myTime,myIter, bi,bj, myThid )            CALL LAND_DIAGNOSTICS_STATE( myTime,myIter, bi,bj, myThid )
104           ENDDO           ENDDO
105          ENDDO          ENDDO
106         ENDIF         ENDIF

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.22