/[MITgcm]/MITgcm/model/inc/PARAMS.h
ViewVC logotype

Contents of /MITgcm/model/inc/PARAMS.h

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


Revision 1.34 - (show annotations) (download)
Fri Nov 6 22:44:43 1998 UTC (25 years, 6 months ago) by cnh
Branch: MAIN
CVS Tags: checkpoint18
Changes since 1.33: +16 -3 lines
File MIME type: text/plain
Changes to allow for atmospheric integration builds of the code

1 C $Header: /u/gcmpack/models/MITgcmUV/model/inc/PARAMS.h,v 1.33 1998/10/28 03:11:36 cnh Exp $
2 C
3 C /==========================================================\
4 C | PARAMS.h |
5 C | o Header file defining model "parameters". |
6 C |==========================================================|
7 C | The values from the model standard input file are |
8 C | stored into the variables held here. Notes describing |
9 C | the parameters can also be found here. |
10 C \==========================================================/
11
12 C Macros for special grid options
13 #include "PARAMS_MACROS.h"
14
15 C-- Contants
16 C Useful physical values
17 Real*8 PI
18 PARAMETER ( PI = 3.14159265358979323844D0 )
19 Real*8 deg2rad
20 PARAMETER ( deg2rad = 2.D0*PI/360.D0 )
21
22 C Symbolic values
23 C precXXXX - Used to indicate what precision to use for
24 C dumping model state.
25 INTEGER precFloat32
26 PARAMETER ( precFloat32 = 0 )
27 INTEGER precFloat64
28 PARAMETER ( precFloat64 = 1 )
29 C UNSET_xxx - Used to indicate variables that have not been given a value
30 Real*8 UNSET_FLOAT8
31 PARAMETER ( UNSET_FLOAT8 = 1.234567D5 )
32 Real*4 UNSET_FLOAT4
33 PARAMETER ( UNSET_FLOAT4 = 1.234567E5 )
34 _RL UNSET_RL
35 PARAMETER ( UNSET_RL = 1.234567D5 )
36 _RS UNSET_RS
37 PARAMETER ( UNSET_RS = 1.234567E5 )
38 INTEGER UNSET_I
39 PARAMETER ( UNSET_I = 123456789 )
40
41 C Checkpoint data
42 INTEGER maxNoChkptLev
43 PARAMETER ( maxNoChkptLev = 2 )
44
45 C-- COMMON /PARM_C/ Character valued parameters used by the model.
46 C checkPtSuff - List of checkpoint file suffices
47 C bathyFile - File containing bathymetry. If not defined bathymetry
48 C is taken from inline function.
49 C hydrogThetaFile - File containing initial hydrographic data for potential
50 C temperature.
51 C hydrogSaltFile - File containing initial hydrographic data for salinity.
52 C zonalWindFile - File containing zonal wind data
53 C meridWindFile - File containing meridional wind data
54 C thetaClimFile - File containing theta climataology used
55 C in relaxation term -lambda(theta-theta*)
56 C saltClimFile - File containing salt climataology used
57 C in relaxation term -lambda(salt-salt*)
58 C buoyancyRelation - Flag used to indicate which relation to use to
59 C get buoyancy.
60 COMMON /PARM_C/ checkPtSuff,
61 & bathyFile, hydrogThetaFile, hydrogSaltFile,
62 & zonalWindFile, meridWindFile, thetaClimFile,
63 & saltClimFile, buoyancyRelation
64 CHARACTER*(5) checkPtSuff(maxNoChkptLev)
65 CHARACTER*(MAX_LEN_FNAM) bathyFile
66 CHARACTER*(MAX_LEN_FNAM) hydrogThetaFile
67 CHARACTER*(MAX_LEN_FNAM) hydrogSaltFile
68 CHARACTER*(MAX_LEN_FNAM) zonalWindFile
69 CHARACTER*(MAX_LEN_FNAM) meridWindFile
70 CHARACTER*(MAX_LEN_FNAM) thetaClimFile
71 CHARACTER*(MAX_LEN_FNAM) saltClimFile
72 CHARACTER*(MAX_LEN_FNAM) buoyancyRelation
73
74 C-- COMMON /PARM_I/ Integer valued parameters used by the model.
75 C cg2dMaxIters - Maximum number of iterations in the
76 C two-dimensional con. grad solver.
77 C cg2dChkResFreq - Frequency with which to check residual
78 C in con. grad solver.
79 C cg3dMaxIters - Maximum number of iterations in the
80 C three-dimensional con. grad solver.
81 C cg3dChkResFreq - Frequency with which to check residual
82 C in con. grad solver.
83 C nIter0 - Start time-step number of for this run
84 C nTimeSteps - Number of timesteps to execute
85 C numStepsPerPickup - For offline setup. Frequency of pickup
86 C of flow fields.
87 C writeStatePrec - Precision used for writing model state.
88 C writeBinaryPrec - Precision used for writing binary files
89 C readBinaryPrec - Precision used for reading binary files
90 C nCheckLev - Holds current checkpoint level
91 C nShap - "Order" of shapiro filter to apply to
92 C model prognositic fields.
93 C nShap == 1 => del2
94 C nShap == 2 => del4
95 C nShap == 3 => del6
96 C etc...
97
98 COMMON /PARM_I/
99 & cg2dMaxIters,
100 & cg2dChkResFreq,
101 & cg3dMaxIters,
102 & cg3dChkResFreq,
103 & nIter0, nTimeSteps,
104 & numStepsPerPickup,
105 & writeStatePrec, nCheckLev,
106 & writeBinaryPrec, readBinaryPrec,
107 & nShap
108 INTEGER cg2dMaxIters
109 INTEGER cg2dChkResFreq
110 INTEGER cg3dMaxIters
111 INTEGER cg3dChkResFreq
112 INTEGER nIter0
113 INTEGER nTimeSteps
114 INTEGER numStepsPerPickup
115 INTEGER writeStatePrec
116 INTEGER writeBinaryPrec
117 INTEGER readBinaryPrec
118 INTEGER nCheckLev
119 INTEGER nShap
120
121 C-- COMMON /PARM_L/ Logical valued parameters used by the model.
122 C usingCartesianGrid - If TRUE grid generation will be in a cartesian
123 C coordinate frame.
124 C usingSphericalPolarGrid - If TRUE grid generation will be in a
125 C spherical polar frame.
126 C momViscosity - Flag which turns momentum friction terms on and off.
127 C momAdvection - Flag which turns advection of momentum on and off.
128 C momForcing - Flag which turns external forcing of momentum on
129 C and off.
130 C momPressureForcing - Flag which turns pressure term in momentum equation
131 C on and off.
132 C metricTerms - Flag which turns metric terms on or off.
133 C usingSphericalPolarMTerms - If TRUE use spherical polar metric terms.
134 C useCoriolis - Flag which turns the coriolis terms on and off.
135 C tempDiffusion - Flag which turns diffusion of temperature on
136 C and off.
137 C tempAdvection - Flag which turns advection of temperature on
138 C and off.
139 C tempForcing - Flag which turns external forcing of temperature on
140 C and off.
141 C saltDiffusion - Flag which turns diffusion of salinit on
142 C and off.
143 C saltAdvection - Flag which turns advection of salinit on
144 C and off.
145 C saltForcing - Flag which turns external forcing of salinit on
146 C and off.
147 C implicitFreeSurface - Set to true to use implcit free surface
148 C rigidLid - Set to true to use rigid lid
149 C momStepping - Turns momentum equation time-stepping off
150 C tempStepping - Turns temperature equation time-stepping off
151 C saltStepping - Turns salinity equation time-stepping off
152 C useConstantF - Coriolis parameter set to f0
153 C useBetaPlaneF - Coriolis parameter set to f0 + beta.y
154 C useSphereF - Coriolis parameter set to 2.omega.sin(phi)
155 C implicitDiffusion - Turns implicit vertical diffusion on
156 C doThetaClimRelax - Set true if relaxation to temperature
157 C climatology is required.
158 C doSaltClimRelax - Set true if relaxation to salinity
159 C climatology is required.
160 C periodicExternalForcing - Set true if forcing is time-dependant
161 C usingPCoords - Set to indicate that we are working in pressure
162 C coords.
163 C usingZCoords - Set to indicate that we are working in height
164 C coords.
165 COMMON /PARM_L/ usingCartesianGrid, usingSphericalPolarGrid,
166 & momViscosity, momAdvection, momForcing, useCoriolis,
167 & momPressureForcing,tempDiffusion, tempAdvection, tempForcing,
168 & saltDiffusion, saltAdvection, saltForcing,
169 & implicitFreeSurface, rigidLid,
170 & momStepping, tempStepping, saltStepping,
171 & metricTerms, usingSphericalPolarMTerms,
172 & useConstantF, useBetaPlaneF, useSphereF,
173 & implicitDiffusion, doThetaClimRelax, doSaltClimRelax,
174 & periodicExternalForcing, usingPCoords, usingZCoords
175 LOGICAL usingCartesianGrid
176 LOGICAL usingSphericalPolarGrid
177 LOGICAL usingSphericalPolarMTerms
178 LOGICAL momViscosity
179 LOGICAL momAdvection
180 LOGICAL momForcing
181 LOGICAL momPressureForcing
182 LOGICAL useCoriolis
183 LOGICAL tempDiffusion
184 LOGICAL tempAdvection
185 LOGICAL tempForcing
186 LOGICAL saltDiffusion
187 LOGICAL saltAdvection
188 LOGICAL saltForcing
189 LOGICAL implicitFreeSurface
190 LOGICAL rigidLid
191 LOGICAL momStepping
192 LOGICAL tempStepping
193 LOGICAL saltStepping
194 LOGICAL metricTerms
195 LOGICAL useConstantF
196 LOGICAL useBetaPlaneF
197 LOGICAL useSphereF
198 LOGICAL implicitDiffusion
199 LOGICAL doThetaClimRelax
200 LOGICAL doSaltClimRelax
201 LOGICAL periodicExternalForcing
202 LOGICAL usingPCoords
203 LOGICAL usingZCoords
204
205 C-- COMMON /PARM_R/ "Real" valued parameters used by the model.
206 C cg2dTargetResidual
207 C - Target residual for cg2d solver.
208 C cg3dTargetResidual
209 C - Target residual for cg3d solver.
210 C cg2dpcOffDFac - Averaging weight for preconditioner off-diagonal.
211 C Note. 20th May 1998
212 C I made a weird discovery! In the model paper we argue
213 C for the form of the preconditioner used here ( see
214 C A Finite-volume, Incompressible Navier-Stokes Model
215 C ...., Marshall et. al ). The algebra gives a simple
216 C 0.5 factor for the averaging of ac and aCw to get a
217 C symmettric pre-conditioner. By using a factor of 0.51
218 C i.e. scaling the off-diagonal terms in the
219 C preconditioner down slightly I managed to get the
220 C number of iterations for convergence in a test case to
221 C drop form 192 -> 134! Need to investigate this further!
222 C For now I have introduced a parameter cg2dpcOffDFac which
223 C defaults to 0.51 but can be set at runtime.
224 C delP - Vertical grid spacing ( Pa ).
225 C delZ - Vertical grid spacing ( m ).
226 C delR - Vertical grid spacing ( units of r ).
227 C delX - Separation between cell faces (m) or (deg), depending
228 C delY on input flags.
229 C gravity - Accel. due to gravity ( m/s^2 )
230 C recip_gravity and its inverse
231 C gBaro - Accel. due to gravity used in barotropic equation ( m/s^2 )
232 C ronil - Reference density
233 C rhoConst - Vertically constant reference density
234 C startTime - Start time for model ( s )
235 C phiMin - Latitude of southern most cell face.
236 C thetaMin - Longitude of western most cell face (this
237 C is an "inert" parameter but it is included
238 C to make geographical references simple.)
239 C rSphere - Radius of sphere for a spherical polar grid ( m ).
240 C recip_RSphere - Reciprocal radius of sphere ( m ).
241 C f0 - Reference coriolis parameter ( 1/s )
242 C ( Southern edge f for beta plane )
243 C beta - df/dy ( s^-1.m^-1 )
244 C omega - Angular velocity ( rad/s )
245 C viscAh - Eddy viscosity coeff. for mixing of
246 C momentum laterally ( m^2/s )
247 C viscAz - Eddy viscosity coeff. for mixing of
248 C momentum vertically ( m^2/s )
249 C viscAp - Eddy viscosity coeff. for mixing of
250 C momentum vertically ( Pa^2/s )
251 C viscAr - Eddy viscosity coeff. for mixing of
252 C momentum vertically ( units of r^2/s )
253 C viscA4 - Biharmonic viscosity coeff. for mixing of
254 C momentum laterally ( m^4/s )
255 C diffKhT - Laplacian diffusion coeff. for mixing of
256 C heat laterally ( m^2/s )
257 C diffKzT - Laplacian diffusion coeff. for mixing of
258 C heat vertically ( m^2/s )
259 C diffKpT - Laplacian diffusion coeff. for mixing of
260 C heat vertically ( Pa^2/s )
261 C diffKrT - Laplacian diffusion coeff. for mixing of
262 C heat vertically ( units of r^2/s )
263 C diffK4T - Biharmonic diffusion coeff. for mixing of
264 C heat laterally ( m^4/s )
265 C diffKhS - Laplacian diffusion coeff. for mixing of
266 C salt laterally ( m^2/s )
267 C diffKzS - Laplacian diffusion coeff. for mixing of
268 C salt vertically ( m^2/s )
269 C diffKpS - Laplacian diffusion coeff. for mixing of
270 C salt vertically ( Pa^2/s )
271 C diffKrS - Laplacian diffusion coeff. for mixing of
272 C salt vertically ( units of r^2/s )
273 C diffK4S - Biharmonic diffusion coeff. for mixing of
274 C salt laterally ( m^4/s )
275 C deltaT - Default timestep ( s )
276 C deltaTClock - Timestep used as model "clock". This determines the
277 C IO frequencies and is used in tagging output. It can
278 C be totally different to the dynamical time. Typically
279 C it will be the deep-water timestep for accelerated runs.
280 C Frequency of checkpointing and dumping of the model state
281 C are referenced to this clock. ( s )
282 C deltaTMom - Timestep for momemtum equations ( s )
283 C deltaTtracer - Timestep for tracer equations ( s )
284 C freesurfFac - Parameter to turn implicit free surface term on or off
285 C freesurfac = 1. uses implicit free surface
286 C freesurfac = 0. uses rigid lid
287 C hFacMin - Minimum fraction size of a cell (affects hFacC etc...)
288 C hFacMinDz - Minimum dimesional size of a cell (affects hFacC etc..., m)
289 C hFacMinDp - Minimum dimesional size of a cell (affects hFacC etc..., Pa)
290 C hFacMinDr - Minimum dimesional size of a cell (affects hFacC etc..., units of r)
291 C tauCD - CD scheme coupling timescale ( 1/s )
292 C rCD - CD scheme normalised coupling parameter ( 0-1 )
293 C GMmaxslope - max. slope allowed in GM/Redi tensor
294 C GMlength - Length to use in Visbeck et al. formula for K (m)
295 C GMalpha - alpha to use in Visbeck et al. formula for K
296 C GMdepth - Depth over which to integrate Richardson # (Visbeck et al.)
297 C GMkbackground - background value of GM/Redi diffusion coefficient ( m^2/s )
298 C GMmaxval - max. value of KapGM allowed in GM/Redi scheme ( m^2/s )
299 C startTime - Starting time for this integration ( s ).
300 C endTime - Ending time for this integration ( s ).
301 C chkPtFreq - Frequency of rolling check pointing ( s ).
302 C pChkPtFreq - Frequency of permanent check pointing ( s ).
303 C dumpFreq - Frequency with which model state is written to
304 C post-processing files ( s ).
305 C afFacMom - Advection of momentum term tracer parameter
306 C vfFacMom - Momentum viscosity tracer parameter
307 C pfFacMom - Momentum pressure forcing tracer parameter
308 C cfFacMom - Coriolis term tracer parameter
309 C foFacMom - Momentum forcing tracer parameter
310 C mtFacMom - Metric terms tracer parameter
311 C cAdjFreq - Frequency of convective adjustment
312 C
313 C taveFreq - Frequency with which time-averaged model state is written to
314 C post-processing files ( s ).
315 C tauThetaClimRelax - Relaxation to climatology time scale ( s ).
316 C lambdaThetaClimRelax - Inverse time scale for relaxation ( 1/s ).
317 C tauSaltClimRelax - Relaxation to climatology time scale ( s ).
318 C lambdaSaltClimRelax - Inverse time scale for relaxation ( 1/s ).
319 C externForcingPeriod - Is the period of which forcing varies (eg. 1 month)
320 C externForcingCycle - Is the repeat time of the forcing (eg. 1 year)
321 C (note: externForcingCycle must be an integer
322 C number times externForcingPeriod)
323 C horiVertRatio - Ratio on units in vertical to units in horizontal.
324 C recip_horiVertRatio ( 1 if horiz in m and vertical in m ).
325 C ( g*rho if horiz in m and vertical in Pa ).
326 C latFFTFiltLo - Low latitude for FFT filtering of latitude
327 C circles ( see filter*.F )
328 COMMON /PARM_R/ cg2dTargetResidual, cg2dpcOffDFac,
329 & cg3dTargetResidual,
330 & delP, delZ, delR, delX, delY,
331 & deltaT,deltaTmom, deltaTtracer, deltaTClock,abeps, startTime,
332 & phiMin, thetaMin, rSphere, recip_RSphere, f0, fCori, beta,
333 & viscAh, viscAz, viscA4, viscAr,
334 & diffKhT, diffKzT, diffK4T, diffKrT,
335 & diffKhS, diffKzS, diffK4S, diffKrS,
336 & delT, tauCD, rCD, freeSurfFac, hFacMin, hFacMinDz,
337 & GMmaxslope,GMlength,GMalpha,GMdepth,GMkbackground,GMmaxval,
338 & gravity, recip_Gravity, gBaro, rhonil, recip_rhonil,
339 & recip_rhoConst, rhoConst, tRef, sRef,
340 & endTime, chkPtFreq, pchkPtFreq, dumpFreq, taveFreq,
341 & afFacMom, vfFacMom, pfFacMom, cfFacMom, foFacMom, mtFacMom,
342 & cAdjFreq, omega, tauThetaClimRelax, lambdaThetaClimRelax,
343 & tauSaltClimRelax, lambdaSaltClimRelax,
344 & externForcingCycle, externForcingPeriod,
345 & viscAp, diffKpT, diffKpS, hFacMinDr, hFacMinDp,
346 & theta_S, specVol_S, horiVertRatio, recip_horiVertRatio,
347 & latFFTFiltLo
348
349 _RL cg2dTargetResidual
350 _RL cg3dTargetResidual
351 _RL cg2dpcOffDFac
352 _RL delZ(Nr)
353 _RL delP(Nr)
354 _RL delR(Nr)
355 _RL delX(Nx)
356 _RL delY(Ny)
357 _RL deltaT
358 _RL deltaTClock
359 _RL deltaTmom
360 _RL deltaTtracer
361 _RL abeps
362 _RL phiMin
363 _RL thetaMin
364 _RL rSphere
365 _RL recip_RSphere
366 _RL f0
367 _RL freeSurfFac
368 _RL hFacMin
369 _RL hFacMinDz
370 _RL hFacMinDp
371 _RL hFacMinDr
372 _RL beta
373 _RL viscAh
374 _RL viscAz
375 _RL viscAp
376 _RL viscAr
377 _RL viscA4
378 _RL diffKhT
379 _RL diffKrT
380 _RL diffKzT
381 _RL diffKpT
382 _RL diffK4T
383 _RL diffKhS
384 _RL diffKrS
385 _RL diffKzS
386 _RL diffKpS
387 _RL diffK4S
388 _RL delt
389 _RL tauCD
390 _RL rCD
391 _RL GMmaxslope
392 _RL GMlength
393 _RL GMalpha
394 _RL GMdepth
395 _RL GMkbackground
396 _RL GMmaxval
397 _RL gravity
398 _RL recip_gravity
399 _RL gBaro
400 _RL rhonil
401 _RL recip_rhonil
402 _RL rhoConst
403 _RL recip_rhoConst
404 _RL specVol_S(Nr)
405 _RL tRef(Nr)
406 _RL theta_S(Nr)
407 _RL sRef(Nr)
408 _RS Fcori(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
409 _RL startTime
410 _RL endTime
411 _RL chkPtFreq
412 _RL pChkPtFreq
413 _RL dumpFreq
414 _RL taveFreq
415 _RL afFacMom
416 _RL vfFacMom
417 _RL pfFacMom
418 _RL cfFacMom
419 _RL foFacMom
420 _RL mTFacMom
421 _RL cAdjFreq
422 _RL omega
423 _RL tauThetaClimRelax
424 _RL lambdaThetaClimRelax
425 _RL tauSaltClimRelax
426 _RL lambdaSaltClimRelax
427 _RL externForcingCycle
428 _RL externForcingPeriod
429 _RL horiVertRatio
430 _RL recip_horiVertRatio
431 _RL latFFTFiltLo
432
433 COMMON /PARM_A/ HeatCapacity_Cp,
434 & Lamba_theta
435 _RL HeatCapacity_Cp
436 _RL Lamba_theta
437
438 C Equation of State (polynomial coeffients)
439 COMMON /PARM_EOS_NL/ eosC,eosSig0,eosRefT,eosRefS
440 _RL eosC(9,Nr+1),eosSig0(Nr+1),eosRefT(Nr+1),eosRefS(Nr+1)
441 C Linear equation of state
442 C tAlpha - Linear EOS thermal expansion coefficient ( 1/degree ).
443 C sBeta - Linear EOS haline contraction coefficient.
444 COMMON /PARM_EOS_LIN/ tAlpha,sBeta,eosType
445 _RL tAlpha
446 _RL sBeta
447 character*(6) eosType
448

  ViewVC Help
Powered by ViewVC 1.1.22