--- MITgcm/pkg/thsice/thsice_readparms.F 2003/11/23 01:20:13 1.1 +++ MITgcm/pkg/thsice/thsice_readparms.F 2005/06/24 04:36:54 1.7 @@ -1,15 +1,23 @@ -C $Header: /home/ubuntu/mnt/e9_copy/MITgcm/pkg/thsice/thsice_readparms.F,v 1.1 2003/11/23 01:20:13 jmc Exp $ +C $Header: /home/ubuntu/mnt/e9_copy/MITgcm/pkg/thsice/thsice_readparms.F,v 1.7 2005/06/24 04:36:54 edhill Exp $ C $Name: $ #include "THSICE_OPTIONS.h" +CBOP +C !ROUTINE: THSICE_READPARMS +C !INTERFACE: SUBROUTINE THSICE_READPARMS( myThid ) -C /==========================================================* -C | SUBROUTINE THSICE_READPARMS + +C !DESCRIPTION: \bv +C *==========================================================* +C | S/R THSICE_READPARMS C | o Routine to initialize THSICE parameters and constants -C |==========================================================* +C *==========================================================* C | Initialize Th-Sea-ICE parameters, read in data.ice -C \==========================================================* +C *==========================================================* +C \ev + +C !USES: IMPLICIT NONE C === Global variables === @@ -18,15 +26,19 @@ #include "PARAMS.h" #include "GRID.h" #include "THSICE_PARAMS.h" -c #include "THSICE.h" +#ifdef ALLOW_MNC +#include "MNC_PARAMS.h" +#endif +C !INPUT/OUTPUT PARAMETERS: C === Routine arguments === INTEGER myThid +CEOP #ifdef ALLOW_THSICE C === Local variables === -C msgBuf - Informational/error meesage buffer +C msgBuf - Informational/error message buffer C iUnit - Work variable for IO unit number CHARACTER*(MAX_LEN_MBUF) msgBuf INTEGER iUnit @@ -37,7 +49,8 @@ & cpice, cpwater, & kice, ksnow, & transcoef, Lfresh, qsnow, - & albsnodry, albsnowet, albicemax, albicemin, halb, + & albColdSnow, albWarmSnow, albOldSnow, hNewSnowAge, + & albIceMax, albIceMin, hAlbIce, hAlbSnow, & i0, ksolar, & saltice, S_winton, mu_Tf, & Tf0kel, @@ -46,10 +59,16 @@ & frac_energy, hihig NAMELIST /THSICE_PARM01/ - & startIceModel, - & thSIce_deltaT, - & stressReduction, - & thSIce_taveFreq, thSIce_diagFreq, thSIce_monFreq + & startIceModel, stepFwd_oceMxL, + & thSIce_deltaT, ocean_deltaT, tauRelax_MxL, + & hMxL_default, sMxL_default, vMxL_default, + & stressReduction, + & thSIce_taveFreq, thSIce_diagFreq, thSIce_monFreq, + & thSIce_tave_mnc, thSIce_snapshot_mnc, thSIce_mon_mnc, + & thSIce_pickup_read_mnc, thSIce_pickup_write_mnc, + & thSIceFract_InitFile, thSIceThick_InitFile, + & thSIceSnowH_InitFile, thSIceSnowA_InitFile, + & thSIceEnthp_InitFile, thSIceTsurf_InitFile _BEGIN_MASTER(myThid) @@ -74,11 +93,14 @@ transcoef=0.006 _d 0 Lfresh = 3.34 _d 5 qsnow = Lfresh - albsnodry= 0.85 _d 0 - albsnowet= 0.75 _d 0 - albicemax= 0.65 _d 0 - albicemin= 0.20 _d 0 - halb = 0.5 _d 0 + albColdSnow= 0.85 _d 0 + albWarmSnow= 0.70 _d 0 + albOldSnow = 0.55 _d 0 + albIceMax = 0.65 _d 0 + albIceMin = 0.20 _d 0 + hAlbIce = 0.50 _d 0 + hAlbSnow = 0.30 _d 0 + hNewSnowAge= 2. _d -3 i0 = 0.3 _d 0 ksolar = 1.5 _d 0 saltice = 4. _d 0 @@ -97,12 +119,38 @@ hihig = 2.5 _d 0 C-- Default values (parameters) - startIceModel = 0 - thSIce_deltaT = deltaTtracer + stepFwd_oceMxL = .FALSE. + startIceModel = 0 + thSIce_deltaT = dTtracerLev(1) + ocean_deltaT = dTtracerLev(1) + tauRelax_MxL = 0. _d 0 + hMxL_default = 50. _d 0 + sMxL_default = 35. _d 0 + vMxL_default = 5. _d -2 stressReduction = 1. _d 0 thSIce_taveFreq = taveFreq thSIce_diagFreq = dumpFreq thSIce_monFreq = monitorFreq +#ifdef ALLOW_MNC + thSIce_tave_mnc = timeave_mnc + thSIce_snapshot_mnc = snapshot_mnc + thSIce_mon_mnc = monitor_mnc + thSIce_pickup_read_mnc = pickup_read_mnc + thSIce_pickup_write_mnc = pickup_write_mnc +#else + thSIce_tave_mnc = .FALSE. + thSIce_snapshot_mnc = .FALSE. + thSIce_mon_mnc = .FALSE. + thSIce_pickup_read_mnc = .FALSE. + thSIce_pickup_write_mnc = .FALSE. +#endif + thSIceFract_InitFile = ' ' + thSIceThick_InitFile = ' ' + thSIceSnowH_InitFile = ' ' + thSIceSnowA_InitFile = ' ' + thSIceEnthp_InitFile = ' ' + thSIceTsurf_InitFile = ' ' + C-- Read parameters from open data file READ(UNIT=iUnit,NML=THSICE_CONST) @@ -122,9 +170,29 @@ Tmlt1=-mu_Tf*S_winton rhoiw = rhosw - rhoi +C Set I/O parameters + thSIce_tave_mdsio = .TRUE. + thSIce_snapshot_mdsio = .TRUE. + thSIce_mon_stdio = .TRUE. + thSIce_pickup_write_mdsio = .TRUE. +#ifdef ALLOW_MNC + IF (useMNC) THEN + IF ( .NOT.outputTypesInclusive + & .AND. thSIce_tave_mnc ) thSIce_tave_mdsio = .FALSE. + IF ( .NOT.outputTypesInclusive + & .AND. thSIce_snapshot_mnc ) + & thSIce_snapshot_mdsio = .FALSE. + IF ( .NOT.outputTypesInclusive + & .AND. thSIce_mon_mnc ) thSIce_mon_stdio = .FALSE. + IF ( .NOT.outputTypesInclusive + & .AND. thSIce_pickup_write_mnc ) + & thSIce_pickup_write_mdsio = .FALSE. + ENDIF +#endif + C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| iUnit = standardMessageUnit -c iUnit = 88 +c CALL MDSFINDUNIT( iUnit, mythid ) c OPEN(iUnit,file='thsice_check_params',status='unknown') WRITE(iUnit,*) 'ThSI: rhos =',rhos WRITE(iUnit,*) 'ThSI: rhoi =',rhoi @@ -138,11 +206,14 @@ WRITE(iUnit,*) 'ThSI: transcoef=',transcoef WRITE(iUnit,*) 'ThSI: Lfresh =',Lfresh WRITE(iUnit,*) 'ThSI: qsnow =',qsnow - WRITE(iUnit,*) 'ThSI: albsnodry=',albsnodry - WRITE(iUnit,*) 'ThSI: albsnowet=',albsnowet - WRITE(iUnit,*) 'ThSI: albicemax=',albicemax - WRITE(iUnit,*) 'ThSI: albicemin=',albicemin - WRITE(iUnit,*) 'ThSI: halb =',halb + WRITE(iUnit,*) 'ThSI: albColdSnow=',albColdSnow + WRITE(iUnit,*) 'ThSI: albWarmSnow=',albWarmSnow + WRITE(iUnit,*) 'ThSI: albOldSnow =',albOldSnow + WRITE(iUnit,*) 'ThSI: hNewSnowAge=',hNewSnowAge + WRITE(iUnit,*) 'ThSI: albIceMax =',albIceMax + WRITE(iUnit,*) 'ThSI: albIceMin =',albIceMin + WRITE(iUnit,*) 'ThSI: hAlbIce =',hAlbIce + WRITE(iUnit,*) 'ThSI: hAlbSnow =',hAlbSnow WRITE(iUnit,*) 'ThSI: i0 =',i0 WRITE(iUnit,*) 'ThSI: ksolar =',ksolar WRITE(iUnit,*) 'ThSI: saltice =',saltice @@ -161,12 +232,18 @@ WRITE(iUnit,*) 'ThSI: frac_energy',frac_energy WRITE(iUnit,*) 'ThSI: hihig =',hihig WRITE(iUnit,*) 'ThSI: stressReduction =',stressReduction - WRITE(iUnit,*) 'ThSI: thSIce_deltaT =',thSIce_deltaT + WRITE(iUnit,*) 'ThSI: thSIce_deltaT =',thSIce_deltaT + WRITE(iUnit,*) 'ThSI: ocean_deltaT =',ocean_deltaT + WRITE(iUnit,*) 'ThSI: stepFwd_oceMxL=',stepFwd_oceMxL + WRITE(iUnit,*) 'ThSI: tauRelax_MxL =',tauRelax_MxL + WRITE(iUnit,*) 'ThSI: hMxL_default =',hMxL_default + WRITE(iUnit,*) 'ThSI: sMxL_default =',sMxL_default + WRITE(iUnit,*) 'ThSI: vMxL_default =',vMxL_default WRITE(iUnit,*) 'ThSI: thSIce_taveFreq=',thSIce_taveFreq WRITE(iUnit,*) 'ThSI: thSIce_diagFreq=',thSIce_diagFreq WRITE(iUnit,*) 'ThSI: thSIce_monFreq =',thSIce_monFreq WRITE(iUnit,*) 'ThSI: startIceModel =',startIceModel - IF (iUnit.EQ.88) CLOSE(iUnit) + IF (iUnit.NE.standardMessageUnit) CLOSE(iUnit) C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| _END_MASTER(myThid)