1 |
C $Header: /u/u3/gcmpack/MITgcm/model/src/packages_readparms.F,v 1.21.2.2 2003/10/06 04:12:29 edhill Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "PACKAGES_CONFIG.h" |
5 |
#include "CPP_OPTIONS.h" |
6 |
|
7 |
CStartOfInterface |
8 |
CBOP |
9 |
C !ROUTINE: PACKAGES_READPARMS |
10 |
C !INTERFACE: |
11 |
SUBROUTINE PACKAGES_READPARMS(myThid) |
12 |
|
13 |
C !DESCRIPTION: \bv |
14 |
C *==========================================================* |
15 |
C | SUBROUTINE PACKAGES_READPARMS |
16 |
C | o Read runtime package configuration parameters |
17 |
C *==========================================================* |
18 |
C | Packages can have internal runtime configuration |
19 |
C | parameters. A package provides a routine |
20 |
C | ${PKGNAME}_READ_PARMS to read these parameters. In |
21 |
C | general this routine should read parameters from a file |
22 |
C | called data.${pkgname}. |
23 |
C | This routine (S/R PACKAGES_READPARMS) calls per-package |
24 |
C | parameter reading routines. |
25 |
C *==========================================================* |
26 |
C \ev |
27 |
|
28 |
C !CALLING SEQUENCE: |
29 |
C PACKAGES_READPARMS |
30 |
C | |
31 |
C |-- GMREDI_READPARMS |
32 |
C | |
33 |
C |-- KPP_READPARMS |
34 |
C | |
35 |
C |-- SBO_READPARMS |
36 |
C | |
37 |
C |-- SEAICE_READPARMS |
38 |
C | |
39 |
C |-- SHAP_FILT_READPARMS |
40 |
C | |
41 |
C |-- ZONAL_FILT_READPARMS |
42 |
C | |
43 |
C |-- OBCS_READPARMS |
44 |
C | |
45 |
C |-- COST_READPARMS |
46 |
C | |
47 |
C |-- CTRL_INIT |
48 |
C | |
49 |
C |-- OPTIM_READPARMS |
50 |
C | |
51 |
C |-- GRDCHK_READPARMS |
52 |
C | |
53 |
C |-- ECCO_READPARMS |
54 |
|
55 |
|
56 |
C !USES: |
57 |
IMPLICIT NONE |
58 |
C == Global variables == |
59 |
#include "SIZE.h" |
60 |
#include "EEPARAMS.h" |
61 |
#include "PARAMS.h" |
62 |
|
63 |
C == Routine arguments == |
64 |
INTEGER myThid |
65 |
CEOP |
66 |
|
67 |
#ifdef ALLOW_GMREDI |
68 |
C-- Initialize GM/Redi parameters |
69 |
IF (useGMRedi) CALL GMREDI_READPARMS( myThid ) |
70 |
#endif |
71 |
|
72 |
#ifdef ALLOW_KPP |
73 |
C-- Initialize KPP parameters |
74 |
IF (useKPP) CALL KPP_READPARMS( myThid ) |
75 |
#endif |
76 |
|
77 |
#ifdef ALLOW_SBO |
78 |
C-- Initialize SBO parameters |
79 |
IF (useSBO) CALL SBO_READPARMS( myThid ) |
80 |
#endif |
81 |
|
82 |
#ifdef ALLOW_SEAICE |
83 |
C-- Initialize SEAICE parameters |
84 |
IF (useSEAICE) CALL SEAICE_READPARMS( myThid ) |
85 |
#endif |
86 |
|
87 |
#ifdef ALLOW_SHAP_FILT |
88 |
IF (useSHAP_FILT) CALL SHAP_FILT_READPARMS( myThid ) |
89 |
#endif |
90 |
|
91 |
#ifdef ALLOW_ZONAL_FILT |
92 |
IF (useZONAL_FILT) CALL ZONAL_FILT_READPARMS( myThid ) |
93 |
#endif |
94 |
|
95 |
#ifdef ALLOW_OBCS |
96 |
IF (useOBCS) CALL OBCS_READPARMS( myThid ) |
97 |
#endif |
98 |
|
99 |
cswdblk -- add --- |
100 |
#ifdef ALLOW_BULK_FORCE |
101 |
C -- initialize Bulkf parameters |
102 |
IF (useBulkForce) call BULKF_READPARMS( myThid ) |
103 |
#endif |
104 |
cswdblk --- end add --- |
105 |
|
106 |
cswdice -- add --- |
107 |
#ifdef ALLOW_THERM_SEAICE |
108 |
C -- initialize Sea Ice parameters |
109 |
IF (useThermSeaIce) call ICE_READPARMS( myThid ) |
110 |
#endif |
111 |
cswdice --- end add --- |
112 |
|
113 |
#ifdef ALLOW_PTRACERS |
114 |
IF (usePTRACERS) CALL PTRACERS_READPARMS( myThid ) |
115 |
#endif |
116 |
|
117 |
cswdptr -- add -- |
118 |
#ifdef ALLOW_GCHEM |
119 |
IF (usePTRACERS) CALL GCHEM_READPARMS( myThid ) |
120 |
#endif |
121 |
cswdptr -- end add --- |
122 |
|
123 |
#if (defined (ALLOW_ADJOINT_RUN) || \ |
124 |
defined (ALLOW_TANGENTLINEAR_RUN) || \ |
125 |
defined (ALLOW_ECCO_OPTIMIZATION)) |
126 |
C-- Initialise the optim. parameters. |
127 |
call optim_readparms( myThid ) |
128 |
C-- Initialise the control parameters |
129 |
call ctrl_readparms( myThid ) |
130 |
C-- Initialise the cost parameters |
131 |
call cost_readparms( mythid ) |
132 |
_BARRIER |
133 |
#endif |
134 |
|
135 |
#ifdef ALLOW_GRADIENT_CHECK |
136 |
C-- Initialise gradient check parameters |
137 |
if (useGrdchk) call grdchk_readparms( myThid ) |
138 |
#endif |
139 |
|
140 |
ceh3 #ifdef ALLOW_CALENDAR |
141 |
#ifdef ALLOW_CAL |
142 |
C-- Initialise the calendar package. |
143 |
ceh3 should have an IF ( useCAL ) THEN |
144 |
call cal_readparms( myThid ) |
145 |
#endif |
146 |
|
147 |
C-- Custom routine to set forcing fields. |
148 |
#if (defined (INCLUDE_EXTERNAL_FORCING_PACKAGE) || defined(ALLOW_EXF)) |
149 |
ceh3 #ifdef INCLUDE_EXTERNAL_FORCING_PACKAGE |
150 |
ceh3 #ifdef ALLOW_EXF |
151 |
ceh3 needs an IF ( useEXF ) THEN |
152 |
call exf_readparms ( mythid ) |
153 |
#endif |
154 |
|
155 |
#ifdef INCLUDE_ECCO_PACKAGE |
156 |
c-- Initialize ECCO package parameters |
157 |
IF (useECCO) call ecco_readparms ( myThid ) |
158 |
#endif |
159 |
|
160 |
END |