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

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

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

revision 1.10 by cnh, Wed Oct 28 03:11:37 1998 UTC revision 1.19 by jmc, Tue Mar 6 16:51:02 2001 UTC
# Line 1  Line 1 
1  C $Header$  C $Header$
2    C $Name$
3    
4  #include "CPP_EEOPTIONS.h"  #include "CPP_OPTIONS.h"
5    
6        SUBROUTINE DO_THE_MODEL_IO(myCurrentTime, myIter, myThid)        SUBROUTINE DO_THE_MODEL_IO(
7         I          forceOutput, myCurrentTime, myIter, myThid)
8  C     /==========================================================\  C     /==========================================================\
9  C     | SUBROUTINE DO_THE_MODEL_IO                               |  C     | SUBROUTINE DO_THE_MODEL_IO                               |
10  C     | o Controlling routine for IO in model main time-stepping |  C     | o Controlling routine for IO in model main time-stepping |
# Line 21  C     | loaded. To work well this assume Line 23  C     | loaded. To work well this assume
23  C     | reliable tool to join datasets together at the end of a  |  C     | reliable tool to join datasets together at the end of a  |
24  C     | run - see joinds.p                                       |  C     | run - see joinds.p                                       |
25  C     \==========================================================/  C     \==========================================================/
26          IMPLICIT NONE
27    
28  C     == Global variables ===  C     == Global variables ===
29  #include "SIZE.h"  #include "SIZE.h"
30  #include "EEPARAMS.h"  #include "EEPARAMS.h"
31  #include "PARAMS.h"  #include "PARAMS.h"
32  #include "DYNVARS.h"  #include "DYNVARS.h"
 #include "CG2D.h"  
33    
34        LOGICAL  DIFFERENT_MULTIPLE        LOGICAL  DIFFERENT_MULTIPLE
35        EXTERNAL DIFFERENT_MULTIPLE        EXTERNAL DIFFERENT_MULTIPLE
36    
37  C     == Routine arguments ==  C     == Routine arguments ==
38    C     forceOutput - If .TRUE. then force I/O, indepenent of other tests
39  C     myThid - Thread number for this instance of the routine.  C     myThid - Thread number for this instance of the routine.
40  C     myIter - Iteration number  C     myIter - Iteration number
41  C     myCurrentTime - Current time of simulation ( s )  C     myCurrentTime - Current time of simulation ( s )
42          LOGICAL forceOutput
43        INTEGER myThid        INTEGER myThid
44        INTEGER myIter        INTEGER myIter
45        REAL    myCurrentTime        _RL    myCurrentTime
46    
47  C     == Local variables ==  C     == Local variables ==
 C     suff - Hold suffix part of a filename  
       CHARACTER*(MAX_LEN_FNAM) suff  
         
48    
49  C--   Generaly only thread 1 does IO here. It can not start until  C--   Generaly only thread 1 does IO here. It can not start until
50  C--   all threads fields are ready.  C--   all threads fields are ready.
# Line 61  C--    Write "text-plots" of certain fie Line 62  C--    Write "text-plots" of certain fie
62       &                        Nr, myIter, myThid )       &                        Nr, myIter, myThid )
63         CALL PLOT_FIELD_XYZRL( theta, 'Current theta ' ,         CALL PLOT_FIELD_XYZRL( theta, 'Current theta ' ,
64       &                        Nr, myIter, myThid )       &                        Nr, myIter, myThid )
65         CALL PLOT_FIELD_XYRL( cg2d_x, 'Current cg2d_x ' ,         CALL PLOT_FIELD_XYRL( etaN  , 'Current etaN  ' ,
66       &                        myIter, myThid )       &                        myIter, myThid )
67    
68        ENDIF        ENDIF
69    
70  C--   Write model state to binary file  C--   Write model state to binary file
71        CALL WRITE_STATE( .FALSE., myCurrentTime, myIter, myThid )        CALL WRITE_STATE( forceOutput, myCurrentTime, myIter, myThid )
72    
73    #ifdef ALLOW_TIMEAVE
74    C--   Do time averages
75          IF (taveFreq.GT.0.) THEN
76           CALL TIMEAVE_STATV_WRITE( myCurrentTime, myIter, myThid )
77          ENDIF
78    #endif
79    
80    #ifdef ALLOW_GMREDI
81    C--   Do KPP diagnostics.
82          IF (useGMRedi)
83         & CALL GMREDI_DIAGS( myCurrentTime, myIter, myThid )
84    #endif
85    
86    #ifdef ALLOW_KPP
87    C--   Do KPP diagnostics.
88          IF (useKPP)
89         & CALL KPP_DO_DIAGS( myCurrentTime, myIter, myThid )
90    #endif
91    
 C  
92        RETURN        RETURN
93        END        END
94    

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.19

  ViewVC Help
Powered by ViewVC 1.1.22