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

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

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


Revision 1.22.4.1 - (hide annotations) (download)
Fri Jan 31 05:06:50 2003 UTC (21 years, 3 months ago) by dimitri
Branch: release1
CVS Tags: release1_p13_pre, release1_p13, release1_p11, release1_p12, release1_p16, release1_p17, release1_p14, release1_p15, release1_p12_pre
Branch point for: release1_50yr
Changes since 1.22: +9 -1 lines
o added pkg/sbo for computing IERS Special Bureau for the Oceans (SBO)
  core products, including oceanic mass, center-of-mass, angular, and
  bottom pressure.
Modified Files:
	doc/tag-index model/inc/CPP_OPTIONS.h model/inc/PARAMS.h
	model/src/do_the_model_io.F model/src/packages_boot.F
	model/src/packages_check.F model/src/packages_readparms.F
	model/src/the_model_main.F

1 dimitri 1.22.4.1 C $Header: /home/ubuntu/mnt/e9_copy/MITgcm/model/src/do_the_model_io.F,v 1.22.4.1 2003/01/31 05:06:50 dimitri Exp $
2 adcroft 1.21 C $Name: $
3 cnh 1.1
4 cnh 1.11 #include "CPP_OPTIONS.h"
5 cnh 1.1
6 cnh 1.22 CBOP
7     C !ROUTINE: DO_THE_MODEL_IO
8     C !INTERFACE:
9 heimbach 1.20 SUBROUTINE DO_THE_MODEL_IO(myCurrentTime, myIter, myThid)
10 cnh 1.22 C !DESCRIPTION: \bv
11     C *==========================================================*
12     C | SUBROUTINE DO_THE_MODEL_IO
13     C | o Controlling routine for IO in model main time-stepping
14     C | loop.
15     C *==========================================================*
16     C | Many systems do not have thread safe IO so it is easier
17     C | to lump everything together and do dumping of fields
18     C | and updating of forcing terms in a single place.
19     C | The approach to IO used here is that writes are only
20     C | performed by thread 1 and that a process only writes out
21     C | its data ( it does not know about anyone elses data!)
22     C | Reading on the other hand is assumed to be from a file
23     C | containing all the data for all the processes. Only the
24     C | portion of data of interest to this process is actually
25     C | loaded. To work well this assumes the existence of some
26     C | reliable tool to join datasets together at the end of a
27     C | run - see joinds.p
28     C *==========================================================*
29     C \ev
30    
31     C !USES:
32 adcroft 1.12 IMPLICIT NONE
33 cnh 1.1 C == Global variables ===
34     #include "SIZE.h"
35     #include "EEPARAMS.h"
36     #include "PARAMS.h"
37     #include "DYNVARS.h"
38 cnh 1.3 LOGICAL DIFFERENT_MULTIPLE
39     EXTERNAL DIFFERENT_MULTIPLE
40    
41 cnh 1.22 C !INPUT/OUTPUT PARAMETERS:
42 cnh 1.1 C == Routine arguments ==
43     C myThid - Thread number for this instance of the routine.
44     C myIter - Iteration number
45 cnh 1.3 C myCurrentTime - Current time of simulation ( s )
46 cnh 1.1 INTEGER myThid
47     INTEGER myIter
48 adcroft 1.13 _RL myCurrentTime
49 cnh 1.1
50 cnh 1.22 CEOP
51 cnh 1.1
52 cnh 1.10 C-- Generaly only thread 1 does IO here. It can not start until
53     C-- all threads fields are ready.
54 cnh 1.6 IF (
55 cnh 1.10 & DIFFERENT_MULTIPLE(dumpFreq,myCurrentTime,
56     & myCurrentTime-deltaTClock)
57 cnh 1.6 & ) THEN
58    
59 cnh 1.3 _BARRIER
60 cnh 1.1
61 cnh 1.3 C-- Write "text-plots" of certain fields
62 cnh 1.10 CALL PLOT_FIELD_XYZRL( uVel , 'Current uVel ' ,
63     & Nr, myIter, myThid )
64     CALL PLOT_FIELD_XYZRL( vVel , 'Current vVel ' ,
65     & Nr, myIter, myThid )
66     CALL PLOT_FIELD_XYZRL( theta, 'Current theta ' ,
67     & Nr, myIter, myThid )
68 jmc 1.19 CALL PLOT_FIELD_XYRL( etaN , 'Current etaN ' ,
69 cnh 1.10 & myIter, myThid )
70 adcroft 1.13
71 cnh 1.3 ENDIF
72    
73     C-- Write model state to binary file
74 heimbach 1.20 CALL WRITE_STATE( myCurrentTime, myIter, myThid )
75 cnh 1.5
76 jmc 1.19 #ifdef ALLOW_TIMEAVE
77 adcroft 1.16 C-- Do time averages
78     IF (taveFreq.GT.0.) THEN
79 jmc 1.19 CALL TIMEAVE_STATV_WRITE( myCurrentTime, myIter, myThid )
80 adcroft 1.21 #ifdef ALLOW_AIM
81     IF (useAIM)
82     & CALL AIM_WRITE_DIAGS( myCurrentTime, myIter, myThid )
83     #endif
84 adcroft 1.16 ENDIF
85     #endif
86    
87     #ifdef ALLOW_GMREDI
88     C-- Do KPP diagnostics.
89 heimbach 1.17 IF (useGMRedi)
90 adcroft 1.16 & CALL GMREDI_DIAGS( myCurrentTime, myIter, myThid )
91     #endif
92    
93     #ifdef ALLOW_KPP
94     C-- Do KPP diagnostics.
95 heimbach 1.17 IF (useKPP)
96 adcroft 1.16 & CALL KPP_DO_DIAGS( myCurrentTime, myIter, myThid )
97 dimitri 1.22.4.1 #endif
98    
99     #ifdef ALLOW_SBO
100     C-- Do SBO diagnostics.
101     IF (useSBO) THEN
102     CALL SBO_CALC ( myCurrentTime, myIter, myThid )
103     CALL SBO_DIAGS( myCurrentTime, myIter, myThid )
104     ENDIF
105 adcroft 1.16 #endif
106    
107 cnh 1.1 RETURN
108     END
109    

  ViewVC Help
Powered by ViewVC 1.1.22