/[MITgcm]/MITgcm/pkg/kpp/kpp_readparms.F
ViewVC logotype

Contents of /MITgcm/pkg/kpp/kpp_readparms.F

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


Revision 1.21 - (show annotations) (download)
Fri Sep 18 11:40:22 2009 UTC (14 years, 7 months ago) by mlosch
Branch: MAIN
CVS Tags: checkpoint62v, checkpoint62u, checkpoint62t, checkpoint62c, checkpoint62s, checkpoint62r, checkpoint62q, checkpoint62p, checkpoint62a, checkpoint62g, checkpoint62f, checkpoint62e, checkpoint62d, checkpoint62k, checkpoint62j, checkpoint62i, checkpoint62h, checkpoint62o, checkpoint62n, checkpoint62m, checkpoint62l, checkpoint62w, checkpoint62z, checkpoint62y, checkpoint62x, checkpoint63g, checkpoint64, checkpoint62, checkpoint63, checkpoint63p, checkpoint63q, checkpoint63r, checkpoint63s, checkpoint63l, checkpoint63m, checkpoint63n, checkpoint63o, checkpoint63h, checkpoint63i, checkpoint63j, checkpoint63k, checkpoint63d, checkpoint63e, checkpoint63f, checkpoint63a, checkpoint63b, checkpoint63c, checkpoint62b, checkpoint64x, checkpoint64q, checkpoint64p, checkpoint64s, checkpoint64r, checkpoint64u, checkpoint64t, checkpoint64w, checkpoint64v, checkpoint64i, checkpoint64h, checkpoint64k, checkpoint64j, checkpoint64m, checkpoint64l, checkpoint64o, checkpoint64n, checkpoint64a, checkpoint64c, checkpoint64b, checkpoint64e, checkpoint64d, checkpoint64g, checkpoint64f, checkpoint61v, checkpoint61w, checkpoint61z, checkpoint61x, checkpoint61y
Changes since 1.20: +15 -8 lines
add double diffusive contributions as a hack, turned off by default
for now, and the code can be excluded with a CPP-flag
EXCLUDE_KPP_DOUBLEDIFF just as EXCLUDE_KPP_SHEAR_MIX

1 C $Header: /u/gcmpack/MITgcm/pkg/kpp/kpp_readparms.F,v 1.20 2009/07/08 21:57:51 jmc Exp $
2 C $Name: $
3 #include "KPP_OPTIONS.h"
4
5 C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
6 CBOP 0
7 C !ROUTINE: KPP_READPARMS
8
9 C !INTERFACE:
10 SUBROUTINE KPP_READPARMS( myThid )
11
12 C !DESCRIPTION:
13 C Routine to read in file data.kpp
14
15 C !USES:
16 IMPLICIT NONE
17 #include "SIZE.h"
18 #include "EEPARAMS.h"
19 #include "PARAMS.h"
20 #include "KPP_PARAMS.h"
21
22 C !INPUT PARAMETERS:
23 INTEGER myThid
24 CEOP
25
26 C !LOCAL VARIABLES:
27 #ifdef ALLOW_KPP
28 C msgBuf - Informational/error meesage buffer
29 C errIO - IO error flag
30 C iUnit - Work variable for IO unit number
31
32 CHARACTER*(MAX_LEN_MBUF) msgBuf
33 INTEGER errIO, iUnit
34
35 C-- KPP vertical mixing parameters
36 NAMELIST /KPP_PARM01/
37 & kpp_freq, kpp_dumpFreq, kpp_taveFreq,
38 & KPPmixingMaps, KPPwriteState, KPP_ghatUseTotalDiffus,
39 & KPPuseDoubleDiff, LimitHblStable,
40 & minKPPhbl,
41 & epsln, phepsi, epsilon, vonk, dB_dz,
42 & conc1, conam, concm, conc2, zetam,
43 & conas, concs, conc3, zetas,
44 & Ricr, cekman, cmonob, concv, hbf,
45 & zmin, zmax, umin, umax,
46 & num_v_smooth_Ri, num_v_smooth_BV,
47 & num_z_smooth_sh, num_m_smooth_sh,
48 & Riinfty, BVSQcon, difm0, difs0, dift0,
49 & difmcon, difscon, diftcon,
50 & Rrho0, dsfmax,
51 & cstar
52
53 _BEGIN_MASTER(myThid)
54
55 WRITE(msgBuf,'(A)') ' KPP_INIT: opening data.kpp'
56 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
57 & SQUEEZE_RIGHT , 1)
58
59
60 CALL OPEN_COPY_DATA_FILE(
61 I 'data.kpp', 'KPP_INIT',
62 O iUnit,
63 I myThid )
64
65 C-- set default KPP vertical mixing parameters
66 kpp_freq = deltaTClock
67 kpp_dumpFreq = dumpFreq
68 kpp_taveFreq = taveFreq
69 KPPmixingMaps = .FALSE.
70 KPPwriteState = .FALSE.
71 KPPuseDoubleDiff = .FALSE.
72 LimitHblStable = .TRUE.
73 KPP_ghatUseTotalDiffus = .FALSE.
74 minKPPhbl = UNSET_RL
75
76 C-----------------------------------------------------------------------
77 C define some non-dimensional constants and
78 C the vertical mixing coefficients in m-k-s units
79 C-----------------------------------------------------------------------
80
81 epsln = 1. _d -20
82 phepsi = 1. _d -10
83 epsilon = 1. _d -1
84 vonk = 0.4 _d 0
85 dB_dz = 5.2 _d -5
86 conc1 = 5. _d 0
87 conam = 1.257 _d 0
88 concm = 8.380 _d 0
89 conc2 = 16. _d 0
90 zetam = -0.2 _d 0
91 conas = -28.86 _d 0
92 concs = 98.96 _d 0
93 conc3 = 16. _d 0
94 zetas = -1. _d 0
95
96 C parameters for subroutine "bldepth"
97
98 Ricr = 0.3 _d 0
99 cekman = 0.7 _d 0
100 cmonob = 1. _d 0
101 concv = 1.8 _d 0
102 hbf = 1. _d 0
103
104 C parameters and common arrays for subroutines
105 C "kmixinit" and "wscale"
106
107 zmin = -4. _d -7
108 zmax = 0. _d 0
109 umin = 0. _d 0
110 umax = 4. _d -2
111
112 C parameters for subroutine "Ri_iwmix"
113
114 num_v_smooth_Ri = 0
115 num_v_smooth_BV = 0
116 num_z_smooth_sh = 0
117 num_m_smooth_sh = 0
118 Riinfty = 0.7 _d 0
119 BVSQcon = -0.2 _d -4
120
121 difm0 = 5. _d -3
122 difs0 = 5. _d -3
123 dift0 = 5. _d -3
124
125 difmcon = 0.1 _d 0
126 difscon = 0.1 _d 0
127 diftcon = 0.1 _d 0
128
129 C parameters for double diffusion routine "KPP_DOUBLEDIFF"
130
131 Rrho0 = 1.9 _d 0
132 dsfmax = 10. _d -3
133
134 C parameters for subroutine "blmix"
135
136 cstar = 10.
137
138 C-----------------------------------------------------------------------
139
140 C-- Read settings from model parameter file "data.kpp".
141 READ(UNIT=iUnit,NML=KPP_PARM01,IOSTAT=errIO)
142 IF ( errIO .LT. 0 ) THEN
143 WRITE(msgBuf,'(A)')
144 & 'S/R INI_PARMS'
145 CALL PRINT_ERROR( msgBuf , 1)
146 WRITE(msgBuf,'(A)')
147 & 'Error reading numerical model '
148 CALL PRINT_ERROR( msgBuf , 1)
149 WRITE(msgBuf,'(A)')
150 & 'parameter file "data.kpp"'
151 CALL PRINT_ERROR( msgBuf , 1)
152 WRITE(msgBuf,'(A)')
153 & 'Problem in namelist KPP_PARM01'
154 CALL PRINT_ERROR( msgBuf , 1)
155 C CALL MODELDATA_EXAMPLE( myThid )
156 STOP 'ABNORMAL END: S/R KPP_INIT'
157 ENDIF
158
159 CLOSE(iUnit)
160
161 WRITE(msgBuf,'(A)') ' KPP_INIT: finished reading data.kpp'
162 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
163 & SQUEEZE_RIGHT , 1)
164
165 _END_MASTER(myThid)
166
167 C-- Everyone else must wait for the parameters to be loaded
168 _BARRIER
169
170 #endif /* ALLOW_KPP */
171
172 RETURN
173 END

  ViewVC Help
Powered by ViewVC 1.1.22