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

Contents of /MITgcm/model/src/packages_boot.F

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


Revision 1.42 - (show annotations) (download)
Sat Nov 24 15:44:52 2007 UTC (16 years, 6 months ago) by dimitri
Branch: MAIN
Changes since 1.41: +4 -2 lines
Fix a bug reported by An Nguyen: calc_salt_plume_depth requires that sigmaR be
available.  Bug fixed by adding flag "usePLUME", which is also a first step
for addition of pkg/plume

1 C $Header: /u/gcmpack/MITgcm/model/src/packages_boot.F,v 1.41 2007/06/15 20:48:38 gforget Exp $
2 C $Name: $
3
4 #include "PACKAGES_CONFIG.h"
5 #include "CPP_OPTIONS.h"
6
7 CBOP
8 C !ROUTINE: PACKAGES_BOOT
9 C !INTERFACE:
10 SUBROUTINE PACKAGES_BOOT( myThid )
11
12 C !DESCRIPTION: \bv
13 C *==========================================================*
14 C | SUBROUTINE PACKAGES_BOOT
15 C | o Routine to parse runtime package selection file
16 C *==========================================================*
17 C | Routine reads a flat file which contains a single flag
18 C | for each known "package". Flag can enables runtime
19 C | activation or deactivation of a package. The data is read
20 C | from a file called data.pkg.
21 C | Note - If a runtime activation flag is set on but the
22 C | package code was not included in the build then
23 C | the default behavior is to stop with an error.
24 C *==========================================================*
25 C \ev
26
27 C !USES:
28 IMPLICIT NONE
29 C === Global variables ===
30 #include "SIZE.h"
31 #include "EEPARAMS.h"
32 #include "PARAMS.h"
33
34 C !INPUT/OUTPUT PARAMETERS:
35 C === Routine arguments ===
36 C myThid - Number of this instances
37 INTEGER myThid
38
39 C !LOCAL VARIABLES:
40 C === Local variables ===
41 C msgBuf - Informational/error meesage buffer
42 C iUnit - Work variable for IO unit number
43 CHARACTER*(MAX_LEN_MBUF) msgBuf
44 INTEGER iUnit
45
46 C data.pkg namelists
47 NAMELIST /PACKAGES/
48 & useOPPS,
49 & usePP81,
50 & useMY82,
51 & useGGL90,
52 & useKPP,
53 & useGMRedi,
54 & useOBCS,
55 & useAIM,
56 & useLand,
57 & useGrdchk,
58 & useEXF,
59 & useECCO,
60 & useSHAP_FILT,
61 & useZONAL_FILT,
62 & useFLT,
63 & usePTRACERS,
64 & useGCHEM,
65 & useRBCS,
66 & useOffLine,
67 & useSBO,
68 & useSEAICE,
69 & useShelfIce,
70 & useThSIce,
71 & useATM2D,
72 & useBulkForce,
73 & useEBM,
74 & usefizhi,
75 & usegridalt,
76 & useDiagnostics,
77 & useMNC,
78 & useREGRID,
79 & useRunClock,
80 & useMATRIX,
81 & useEMBED_FILES,
82 & useMYPACKAGE,
83 & usePLUME
84 CEOP
85
86 _BEGIN_MASTER(myThid)
87
88 WRITE(msgBuf,'(A)') ' PACKAGES_BOOT: opening data.pkg'
89 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
90 & SQUEEZE_RIGHT , myThid )
91
92
93 CALL OPEN_COPY_DATA_FILE(
94 I 'data.pkg', 'PACKAGES_BOOT',
95 O iUnit,
96 I myThid )
97
98 C-- Default package configuration
99 useOPPS =.FALSE.
100 usePP81 =.FALSE.
101 useMY82 =.FALSE.
102 useGGL90 =.FALSE.
103 useKPP =.FALSE.
104 useGMRedi =.FALSE.
105 useOBCS =.FALSE.
106 useAIM =.FALSE.
107 useLand =.FALSE.
108 useCAL =.FALSE.
109 useEXF =.FALSE.
110 useEBM =.FALSE.
111 useGrdchk =.FALSE.
112 useECCO =.FALSE.
113 useSHAP_FILT =.FALSE.
114 useZONAL_FILT =.FALSE.
115 useFLT =.FALSE.
116 usePTRACERS =.FALSE.
117 useGCHEM =.FALSE.
118 useRBCS =.FALSE.
119 useOffLine =.FALSE.
120 useMATRIX =.FALSE.
121 useSBO =.FALSE.
122 useSEAICE =.FALSE.
123 useShelfIce =.FALSE.
124 useThSIce =.FALSE.
125 useATM2D =.FALSE.
126 useBulkForce =.FALSE.
127 usefizhi =.FALSE.
128 usegridalt =.FALSE.
129 useDiagnostics =.FALSE.
130 useMNC =.FALSE.
131 useRunClock =.FALSE.
132 useREGRID =.FALSE.
133 useMYPACKAGE =.FALSE.
134 usePLUME =.FALSE.
135
136 C-- Read parameters from open data file
137 READ(UNIT=iUnit,NML=PACKAGES)
138
139
140 WRITE(msgBuf,'(A)') ' PACKAGES_BOOT: finished reading data.pkg'
141 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
142 & SQUEEZE_RIGHT , myThid )
143
144 C-- Close the open data file
145 CLOSE(iUnit)
146
147 C-- packages with hard-coded switch
148 #ifdef ALLOW_CAL
149 IF (useEXF) useCAL = .TRUE.
150 #endif
151
152 #ifdef ALLOW_PROFILES
153 useCAL = .TRUE.
154 #endif
155
156 C-- packages with an implied switch
157 useGAD = tempStepping .OR. saltStepping .OR. usePTRACERS
158
159 _END_MASTER(myThid)
160
161 C-- Everyone else must wait for the parameters to be loaded
162 _BARRIER
163
164 RETURN
165 END

  ViewVC Help
Powered by ViewVC 1.1.22