35 |
#ifdef ALLOW_EXF |
#ifdef ALLOW_EXF |
36 |
# include "EXF_CONSTANTS.h" |
# include "EXF_CONSTANTS.h" |
37 |
#endif /* ALLOW_EXF */ |
#endif /* ALLOW_EXF */ |
38 |
#ifdef ALLOW_CAL |
#ifdef ALLOW_AUTODIFF |
39 |
# include "cal.h" |
# include "AUTODIFF_PARAMS.h" |
40 |
#endif |
#endif |
41 |
|
|
42 |
C !INPUT/OUTPUT PARAMETERS: |
C !INPUT/OUTPUT PARAMETERS: |
55 |
#ifdef ALLOW_SITRACER |
#ifdef ALLOW_SITRACER |
56 |
INTEGER iTracer |
INTEGER iTracer |
57 |
#endif |
#endif |
58 |
|
#ifdef ALLOW_COST |
59 |
|
INTEGER locDate(4) |
60 |
|
#endif /* ALLOW_COST */ |
61 |
INTEGER nRetired |
INTEGER nRetired |
62 |
|
|
63 |
C- Old parameters (to be retired one day): |
C- Old parameters (to be retired one day): |
90 |
& SEAICEadvHeff, SEAICEadvArea, SEAICEadvSnow, |
& SEAICEadvHeff, SEAICEadvArea, SEAICEadvSnow, |
91 |
& SEAICEadvSalt, SEAICEadvAge, |
& SEAICEadvSalt, SEAICEadvAge, |
92 |
& SEAICE_clipVelocities, SEAICE_maskRHS, SEAICE_no_slip, |
& SEAICE_clipVelocities, SEAICE_maskRHS, SEAICE_no_slip, |
93 |
& LAD, IMAX_TICE, postSolvTempIter, |
& SEAICEetaZmethod, LAD, IMAX_TICE, postSolvTempIter, |
94 |
& SEAICEadvScheme, SEAICEadvSchArea, |
& SEAICEadvScheme, SEAICEadvSchArea, |
95 |
& SEAICEadvSchHeff, SEAICEadvSchSnow, |
& SEAICEadvSchHeff, SEAICEadvSchSnow, |
96 |
& SEAICEadvSchSalt, SEAICEadvSchAge, |
& SEAICEadvSchSalt, SEAICEadvSchAge, |
97 |
& SEAICEdiffKhHeff, SEAICEdiffKhSnow, SEAICEdiffKhArea, |
& SEAICEdiffKhHeff, SEAICEdiffKhSnow, SEAICEdiffKhArea, |
98 |
& SEAICEdiffKhSalt, SEAICEdiffKhAge, |
& SEAICEdiffKhSalt, SEAICEdiffKhAge, |
99 |
& SEAICE_deltaTtherm, SEAICE_deltaTdyn, |
& SEAICE_deltaTtherm, SEAICE_deltaTdyn, |
100 |
|
& SEAICE_LSRrelaxU, SEAICE_LSRrelaxV, |
101 |
& SEAICE_deltaTevp, SEAICE_elasticParm, SEAICE_evpTauRelax, |
& SEAICE_deltaTevp, SEAICE_elasticParm, SEAICE_evpTauRelax, |
102 |
& SEAICE_evpDampC, SEAICE_zetaMin, SEAICE_zetaMaxFac, |
& SEAICE_evpDampC, SEAICE_zetaMin, SEAICE_zetaMaxFac, |
103 |
|
& SEAICEuseJFNK, SEAICEnewtonIterMax, SEAICEkrylovIterMax, |
104 |
|
& JFNKgamma_nonlin,JFNKres_t,JFNKgamma_lin_min,JFNKgamma_lin_max, |
105 |
|
& SEAICEpresH0, SEAICEpresPow0, SEAICEpresPow1, |
106 |
& SEAICE_monFreq, SEAICE_dumpFreq, SEAICE_taveFreq, |
& SEAICE_monFreq, SEAICE_dumpFreq, SEAICE_taveFreq, |
107 |
& SEAICE_initialHEFF, SEAICEturbFluxFormula, |
& SEAICE_initialHEFF, SEAICEturbFluxFormula, |
108 |
& SEAICE_areaGainFormula, SEAICE_areaLossFormula, |
& SEAICE_areaGainFormula, SEAICE_areaLossFormula, |
130 |
& SEAICE_availHeatFrac, SEAICE_availHeatFracFrz, |
& SEAICE_availHeatFrac, SEAICE_availHeatFracFrz, |
131 |
& AreaFile, HeffFile, uIceFile, vIceFile, HsnowFile, HsaltFile, |
& AreaFile, HeffFile, uIceFile, vIceFile, HsnowFile, HsaltFile, |
132 |
& SOLV_MAX_ITERS, SOLV_NCHECK, NPSEUDOTIMESTEPS, LSR_mixIniGuess, |
& SOLV_MAX_ITERS, SOLV_NCHECK, NPSEUDOTIMESTEPS, LSR_mixIniGuess, |
133 |
& LSR_ERROR, DIFF1, SEAICEuseFREEDRIFT, |
& LSR_ERROR, DIFF1, SEAICEuseFREEDRIFT, SEAICEuseTILT, |
134 |
& SEAICEheatConsFix, SEAICE_multDim, |
& SEAICEheatConsFix, SEAICE_multDim, SEAICE_useMultDimSnow, |
135 |
& SEAICE_area_reg, SEAICE_hice_reg, |
& SEAICE_area_reg, SEAICE_hice_reg, |
136 |
& SEAICE_area_floor, SEAICE_area_max, SEAICE_tauAreaObsRelax, |
& SEAICE_area_floor, SEAICE_area_max, SEAICE_tauAreaObsRelax, |
137 |
& SEAICE_airTurnAngle, SEAICE_waterTurnAngle, |
& SEAICE_airTurnAngle, SEAICE_waterTurnAngle, |
138 |
& MAX_HEFF, MIN_ATEMP, MIN_LWDOWN, MAX_TICE, MIN_TICE, |
& MAX_HEFF, MIN_ATEMP, MIN_LWDOWN, MAX_TICE, MIN_TICE, |
139 |
& SEAICE_EPS, SEAICE_EPS_SQ, |
& SEAICE_EPS, SEAICE_EPS_SQ, |
140 |
& SEAICE_tave_mnc, SEAICE_dump_mnc, SEAICE_mon_mnc, |
& SEAICE_tave_mnc, SEAICE_dump_mnc, SEAICE_mon_mnc, |
141 |
|
#ifdef SEAICE_ITD |
142 |
|
& SEAICE_debugPointI, SEAICE_debugPointJ, |
143 |
|
& Hlimit_c1, Hlimit_c2, Hlimit_c3 |
144 |
|
#else |
145 |
& SEAICE_debugPointI, SEAICE_debugPointJ |
& SEAICE_debugPointI, SEAICE_debugPointJ |
146 |
|
#endif |
147 |
|
|
148 |
#ifdef ALLOW_COST |
#ifdef ALLOW_COST |
149 |
NAMELIST /SEAICE_PARM02/ |
NAMELIST /SEAICE_PARM02/ |
180 |
#endif |
#endif |
181 |
SEAICEadjMODE = 0 |
SEAICEadjMODE = 0 |
182 |
SEAICEuseFREEDRIFT = .FALSE. |
SEAICEuseFREEDRIFT = .FALSE. |
183 |
|
SEAICEuseTILT = .TRUE. |
184 |
SEAICEheatConsFix = .FALSE. |
SEAICEheatConsFix = .FALSE. |
185 |
SEAICEuseTEM = .FALSE. |
SEAICEuseTEM = .FALSE. |
186 |
SEAICEuseMetricTerms = .TRUE. |
SEAICEuseMetricTerms = .TRUE. |
206 |
SEAICE_no_slip = .FALSE. |
SEAICE_no_slip = .FALSE. |
207 |
SEAICE_clipVelocities = .FALSE. |
SEAICE_clipVelocities = .FALSE. |
208 |
SEAICE_maskRHS = .FALSE. |
SEAICE_maskRHS = .FALSE. |
209 |
|
SEAICEetaZmethod = 0 |
210 |
SEAICEadvScheme = 2 |
SEAICEadvScheme = 2 |
211 |
SEAICEadvSchArea = UNSET_I |
SEAICEadvSchArea = UNSET_I |
212 |
SEAICEadvSchHeff = UNSET_I |
SEAICEadvSchHeff = UNSET_I |
219 |
SEAICE_deltaTtherm = dTtracerLev(1) |
SEAICE_deltaTtherm = dTtracerLev(1) |
220 |
SEAICE_deltaTdyn = dTtracerLev(1) |
SEAICE_deltaTdyn = dTtracerLev(1) |
221 |
SEAICE_deltaTevp = UNSET_RL |
SEAICE_deltaTevp = UNSET_RL |
222 |
|
C JFNK stuff |
223 |
|
SEAICEuseJFNK = .FALSE. |
224 |
|
SEAICEnewtonIterMax = 10 |
225 |
|
SEAICEkrylovIterMax = 10 |
226 |
|
JFNKgamma_nonlin = 1. _d -05 |
227 |
|
JFNKgamma_lin_min = 0.10 _d 0 |
228 |
|
JFNKgamma_lin_max = 0.99 _d 0 |
229 |
|
JFNKres_t = UNSET_RL |
230 |
C Hunke, JCP, 2001 use 615 kg/m^2 for this, but does not recommend using it |
C Hunke, JCP, 2001 use 615 kg/m^2 for this, but does not recommend using it |
231 |
SEAICE_evpDampC = -1. _d 0 |
SEAICE_evpDampC = -1. _d 0 |
232 |
SEAICE_zetaMin = 0. _d 0 |
SEAICE_zetaMin = 0. _d 0 |
233 |
SEAICE_zetaMaxFac = 2.5 _d 8 |
SEAICE_zetaMaxFac = 2.5 _d 8 |
234 |
|
SEAICEpresH0 = 1. _d 0 |
235 |
|
SEAICEpresPow0 = 1 |
236 |
|
SEAICEpresPow1 = 1 |
237 |
SEAICE_monFreq = monitorFreq |
SEAICE_monFreq = monitorFreq |
238 |
SEAICE_dumpFreq = dumpFreq |
SEAICE_dumpFreq = dumpFreq |
239 |
SEAICE_taveFreq = taveFreq |
SEAICE_taveFreq = taveFreq |
249 |
SEAICE_mon_mnc = .FALSE. |
SEAICE_mon_mnc = .FALSE. |
250 |
#endif |
#endif |
251 |
SEAICE_initialHEFF = ZERO |
SEAICE_initialHEFF = ZERO |
252 |
|
#ifdef SEAICE_ITD |
253 |
|
CToM<<< |
254 |
|
C Coefficients used to calculate sea ice thickness category limits |
255 |
|
C after Lipscomb et al. (2001, JGR), Equ. 22 |
256 |
|
C choose between |
257 |
|
C - original parameters of Lipscomb et al. (2001): |
258 |
|
C c1=3.0/N, c2=15*c1, c3=3.0 |
259 |
|
C - and a higher resolution of thin end of ITD: |
260 |
|
C c1=1.5/N, c2=42*c1, c3=3.3 |
261 |
|
Hlimit_c1 = 3.0 |
262 |
|
Hlimit_c2 = 15. |
263 |
|
Hlimit_c3 = 3.0 |
264 |
|
C>>>ToM |
265 |
|
#endif |
266 |
SEAICE_rhoIce = 0.91 _d +03 |
SEAICE_rhoIce = 0.91 _d +03 |
267 |
SEAICE_rhoSnow = 330. _d 0 |
SEAICE_rhoSnow = 330. _d 0 |
268 |
ICE2WATR = UNSET_RL |
ICE2WATR = UNSET_RL |
323 |
SEAICE_shortwave = 0.30 _d 0 |
SEAICE_shortwave = 0.30 _d 0 |
324 |
SEAICE_salt0 = 0.0 _d 0 |
SEAICE_salt0 = 0.0 _d 0 |
325 |
SEAICE_saltFrac = 0.0 _d 0 |
SEAICE_saltFrac = 0.0 _d 0 |
326 |
#ifdef SEAICE_MULTICATEGORY |
CToM<<< |
327 |
|
C#ifdef SEAICE_MULTICATEGORY |
328 |
|
#if defined(SEAICE_MULTICATEGORY) || defined(SEAICE_ITD) |
329 |
|
C in case defined(SEAICE_ITD) MULTDIM = nITD (see SEAICE_SIZE.h) |
330 |
|
C because SEAICE_ITD uses code related to SEAICE_MULTICATEGORY |
331 |
|
C>>>ToM |
332 |
SEAICE_multDim = MULTDIM |
SEAICE_multDim = MULTDIM |
333 |
#else |
#else |
334 |
SEAICE_multDim = 1 |
SEAICE_multDim = 1 |
335 |
#endif |
#endif |
336 |
|
SEAICE_useMultDimSnow = .FALSE. |
337 |
C default to be set later (ocean-seaice turbulent flux coeff): |
C default to be set later (ocean-seaice turbulent flux coeff): |
338 |
SEAICE_mcPheeStepFunc = .FALSE. |
SEAICE_mcPheeStepFunc = .FALSE. |
339 |
SEAICE_mcPheeTaper = UNSET_RL |
SEAICE_mcPheeTaper = UNSET_RL |
370 |
vIceFile = ' ' |
vIceFile = ' ' |
371 |
IMAX_TICE = 10 |
IMAX_TICE = 10 |
372 |
postSolvTempIter = 2 |
postSolvTempIter = 2 |
373 |
SOLV_MAX_ITERS = 1500 |
C LSR parameters |
374 |
|
SEAICE_LSRrelaxU = 0.95 _d 0 |
375 |
|
SEAICE_LSRrelaxV = 0.95 _d 0 |
376 |
|
SOLV_MAX_ITERS = UNSET_I |
377 |
SOLV_NCHECK= 2 |
SOLV_NCHECK= 2 |
378 |
C two pseudo time steps correspond to the original modified |
C two pseudo time steps correspond to the original modified |
379 |
C Euler time stepping scheme of Zhang+Hibler (1997) |
C Euler time stepping scheme of Zhang+Hibler (1997) |
443 |
SEAICE_debugPointJ = UNSET_I |
SEAICE_debugPointJ = UNSET_I |
444 |
|
|
445 |
#ifdef ALLOW_COST |
#ifdef ALLOW_COST |
446 |
|
locDate(1) = 0 |
447 |
|
locDate(2) = 0 |
448 |
|
# ifdef ALLOW_CAL |
449 |
|
CALL CAL_GETDATE( -1, startTime, locDate, myThid ) |
450 |
|
# endif /* ALLOW_CAL */ |
451 |
mult_ice_export = 0. _d 0 |
mult_ice_export = 0. _d 0 |
452 |
mult_ice = 0. _d 0 |
mult_ice = 0. _d 0 |
453 |
costIceStart1 = 0 |
costIceStart1 = locDate(1) |
454 |
costIceStart2 = 0 |
costIceStart2 = locDate(2) |
455 |
costIceEnd1 = 0 |
costIceEnd1 = 0 |
456 |
costIceEnd2 = 0 |
costIceEnd2 = 0 |
457 |
cost_ice_flag = 1 |
cost_ice_flag = 1 |
468 |
smrareabarfile = 'smrareabar' |
smrareabarfile = 'smrareabar' |
469 |
smrareadatfile = ' ' |
smrareadatfile = ' ' |
470 |
smrarea_errfile = ' ' |
smrarea_errfile = ' ' |
471 |
# ifdef ALLOW_CAL |
smrareastartdate1 = locDate(1) |
472 |
smrareastartdate1 = startDate_1 |
smrareastartdate2 = locDate(2) |
|
smrareastartdate2 = startDate_2 |
|
|
# endif |
|
473 |
#endif /* ALLOW_COST */ |
#endif /* ALLOW_COST */ |
474 |
|
|
475 |
#ifdef ALLOW_SITRACER |
#ifdef ALLOW_SITRACER |
492 |
C Open and read the data.seaice file |
C Open and read the data.seaice file |
493 |
WRITE(msgBuf,'(A)') |
WRITE(msgBuf,'(A)') |
494 |
&' ' |
&' ' |
495 |
CALL PRINT_MESSAGE( msgBuf, standardmessageunit, |
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
496 |
& SQUEEZE_RIGHT , myThid) |
& SQUEEZE_RIGHT , myThid) |
497 |
WRITE(msgBuf,'(A)') ' SEAICE_READPARMS: opening data.seaice' |
WRITE(msgBuf,'(A)') ' SEAICE_READPARMS: opening data.seaice' |
498 |
CALL PRINT_MESSAGE( msgBuf, standardmessageunit, |
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
499 |
& SQUEEZE_RIGHT , myThid) |
& SQUEEZE_RIGHT , myThid) |
500 |
|
|
501 |
CALL OPEN_COPY_DATA_FILE( |
CALL OPEN_COPY_DATA_FILE( |
575 |
& SEAICE_evpTauRelax = SEAICE_deltaTdyn*SEAICE_elasticParm |
& SEAICE_evpTauRelax = SEAICE_deltaTdyn*SEAICE_elasticParm |
576 |
ENDIF |
ENDIF |
577 |
#endif /* SEAICE_ALLOW_EVP */ |
#endif /* SEAICE_ALLOW_EVP */ |
578 |
C |
|
579 |
#ifdef SEAICE_ALLOW_FREEDRIFT |
#ifdef SEAICE_ALLOW_FREEDRIFT |
580 |
IF ( SEAICEuseFREEDRIFT ) SEAICEuseEVP = .FALSE. |
IF ( SEAICEuseFREEDRIFT ) SEAICEuseEVP = .FALSE. |
581 |
IF ( SEAICEuseFREEDRIFT ) THEN |
IF ( SEAICEuseFREEDRIFT ) THEN |
590 |
C Make sure that we have least two pseudo time steps |
C Make sure that we have least two pseudo time steps |
591 |
NPSEUDOTIMESTEPS = MAX(NPSEUDOTIMESTEPS,2) |
NPSEUDOTIMESTEPS = MAX(NPSEUDOTIMESTEPS,2) |
592 |
|
|
593 |
|
C- limit preconditioner steps |
594 |
|
IF ( SOLV_MAX_ITERS .EQ. UNSET_I ) THEN |
595 |
|
C maximum number of LSOR steps in default Picard solver |
596 |
|
SOLV_MAX_ITERS = 1500 |
597 |
|
C maximum number of LSOR steps as preconditioner in JFNK solver |
598 |
|
IF ( SEAICEuseJFNK ) SOLV_MAX_ITERS = 10 |
599 |
|
ENDIF |
600 |
|
|
601 |
C- The old ways of specifying mcPheeTaper, mcPheePiston & frazilFrac: |
C- The old ways of specifying mcPheeTaper, mcPheePiston & frazilFrac: |
602 |
C a) prevent multiple specification of the same coeff; |
C a) prevent multiple specification of the same coeff; |
603 |
C b) if specified, then try to recover old way of setting & default. |
C b) if specified, then try to recover old way of setting & default. |
679 |
STOP 'ABNORMAL END: S/R SEAICE_READPARMS' |
STOP 'ABNORMAL END: S/R SEAICE_READPARMS' |
680 |
ENDIF |
ENDIF |
681 |
|
|
682 |
|
#ifdef SEAICE_ITD |
683 |
|
C The ice thickness distribution (ITD) module can only be used with |
684 |
|
C package seaice thermodynamics (seaice_growth) |
685 |
|
C SEAICE_ADVDIFF and |
686 |
|
C SEAICE_GROWTH, i.e. needs usePW79thermodynamics = .TRUE. |
687 |
|
useTHSice = .FALSE. |
688 |
|
#endif |
689 |
IF ( useThSice ) THEN |
IF ( useThSice ) THEN |
690 |
C If the thsice package with the Winton thermodynamics is used |
C If the thsice package with the Winton thermodynamics is used |
691 |
C is does not make sense to have the following parameters defined, |
C is does not make sense to have the following parameters defined, |
965 |
ENDIF |
ENDIF |
966 |
#endif |
#endif |
967 |
|
|
968 |
|
C- store value of logical flag which might be changed in AD mode |
969 |
|
#ifdef ALLOW_AUTODIFF |
970 |
|
SEAICEuseFREEDRIFTinFwdMode = SEAICEuseFREEDRIFT |
971 |
|
SEAICEuseDYNAMICSinFwdMode = SEAICEuseDYNAMICS |
972 |
|
#endif /* ALLOW_AUTODIFF */ |
973 |
|
|
974 |
C Check the consitency of a few parameters |
C Check the consitency of a few parameters |
975 |
IF ( SEAICE_emissivity .LT. 1. _d -04 ) THEN |
IF ( SEAICE_emissivity .LT. 1. _d -04 ) THEN |
976 |
WRITE(msgBuf,'(2A)') |
WRITE(msgBuf,'(2A)') |