/[MITgcm]/MITgcm/pkg/exf/exf_readparms.F
ViewVC logotype

Contents of /MITgcm/pkg/exf/exf_readparms.F

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


Revision 1.53 - (show annotations) (download)
Tue Jan 27 15:37:03 2009 UTC (15 years, 8 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint61n, checkpoint61o, checkpoint61l, checkpoint61m, checkpoint61j, checkpoint61k, checkpoint61i
Changes since 1.52: +58 -58 lines
rename thetaMin,phiMin -> xgOrigin,ygOrigin

1 C $Header: /u/gcmpack/MITgcm/pkg/exf/exf_readparms.F,v 1.52 2008/11/17 23:08:29 jmc Exp $
2 C $Name: $
3
4 #include "EXF_OPTIONS.h"
5
6 SUBROUTINE EXF_READPARMS( myThid )
7
8 c ==================================================================
9 c SUBROUTINE exf_readparms
10 c ==================================================================
11 c
12 c o This routine initialises the package that calculates external
13 c forcing fields for a given timestep of the MITgcmUV. Parameters
14 c for this package are set in "data.externalforcing". Some additional
15 c precompiler switches have to be specified in "EXF_OPTIONS.h".
16 c
17 c started: Christian Eckert eckert@mit.edu 30-Jun-1999
18 c
19 c changed: Christian Eckert eckert@mit.edu 11-Jan-2000
20 c - Restructured the code in order to create a package
21 c for the MITgcmUV.
22 c Christian Eckert eckert@mit.edu 12-Feb-2000
23 c - Changed Routine names (package prefix: exf_)
24 c changed: Patrick Heimbach, heimbach@mit.edu 04-May-2000
25 c - changed the handling of precip and sflux with respect
26 c to CPP options ALLOW_BULKFORMULAE and ALLOW_ATM_TEMP
27 c changed: Ralf.Giering@FastOpt.de 25-Mai-20000
28 c - moved relaxation and climatology to extra routines
29 c Patrick Heimbach, heimbach@mit.edu 04-May-2000
30 c - added obcs parameters
31 c changed: Virginie Thierry, vthierry@ucsd.edu 04-June-2001
32 c - added new obcs parameters (for each boundaries)
33 c included runoff D. Stammer, Nov. 25, 2001
34 c included pressure forcing. heimbach@mit.edu 05-Nov-2002
35 c added "repeatPeriod" for cycling of forcing datasets 19-Dec-2002
36 c mods for pkg/seaice: menemenlis@jpl.nasa.gov 20-Dec-2002
37 c
38 c ==================================================================
39 c SUBROUTINE exf_readparms
40 c ==================================================================
41
42 implicit none
43
44 c == global variables ==
45
46 #include "EEPARAMS.h"
47 #include "SIZE.h"
48 #include "PARAMS.h"
49 c#include "cal.h"
50 #include "EXF_PARAM.h"
51 #include "EXF_CONSTANTS.h"
52
53 c == routine arguments ==
54
55 integer myThid
56
57 c == local variables ==
58
59 integer i, idummy
60 integer iUnit
61
62 character*(max_len_mbuf) msgbuf
63
64 c == end of interface ==
65
66 c Surface flux data.
67 NAMELIST /EXF_NML_01/
68 & windstressmax, repeatPeriod, exf_albedo,
69 & ocean_emissivity, ice_emissivity, snow_emissivity,
70 & exf_iceCd, exf_iceCe, exf_iceCh,
71 & exf_scal_BulkCdn, climtempfreeze,
72 & exf_iprec, exf_yftype, exf_monFreq,
73 & useExfYearlyFields, twoDigitYear, useExfCheckRange,
74 & useStabilityFct_overIce, readStressOnAgrid, readStressOnCgrid,
75 & useRelativeWind, noNegativeEvap,
76 & hu, ht, umin, atmrho, atmcp, cen2kel, gravity_mks,
77 & cdrag_1, cdrag_2, cdrag_3, cstanton_1, cstanton_2, cdalton,
78 & flamb, flami, zolmin, zref,
79 & cvapor_fac, cvapor_exp, cvapor_fac_ice, cvapor_exp_ice,
80 & humid_fac, gamma_blk, saltsat, sstExtrapol, psim_fac
81
82 NAMELIST /EXF_NML_02/
83 & hfluxfile, atempfile, aqhfile,
84 & sfluxfile, precipfile, runofffile,
85 & ustressfile, vstressfile, evapfile,
86 & snowprecipfile, uwindfile, vwindfile,
87 & wspeedfile, swfluxfile, lwfluxfile,
88 & apressurefile, swdownfile, lwdownfile,
89 & areamaskfile, climsstfile, climsssfile,
90 & hfluxstartdate1, hfluxstartdate2, hfluxperiod,
91 & atempstartdate1, atempstartdate2, atempperiod,
92 & aqhstartdate1, aqhstartdate2, aqhperiod,
93 & sfluxstartdate1, sfluxstartdate2, sfluxperiod,
94 & evapstartdate1, evapstartdate2, evapperiod,
95 & precipstartdate1, precipstartdate2, precipperiod,
96 & snowprecipstartdate1, snowprecipstartdate2, snowprecipperiod,
97 & runoffstartdate1, runoffstartdate2, runoffperiod,
98 & ustressstartdate1, ustressstartdate2, ustressperiod,
99 & vstressstartdate1, vstressstartdate2, vstressperiod,
100 & uwindstartdate1, uwindstartdate2, uwindperiod,
101 & vwindstartdate1, vwindstartdate2, vwindperiod,
102 & wspeedstartdate1, wspeedstartdate2, wspeedperiod,
103 & swfluxstartdate1, swfluxstartdate2, swfluxperiod,
104 & lwfluxstartdate1, lwfluxstartdate2, lwfluxperiod,
105 & swdownstartdate1, swdownstartdate2, swdownperiod,
106 & lwdownstartdate1, lwdownstartdate2, lwdownperiod,
107 &apressurestartdate1,apressurestartdate2,apressureperiod,
108 & areamaskstartdate1,areamaskstartdate2,areamaskperiod,
109 & climsststartdate1, climsststartdate2, climsstperiod,
110 & climsssstartdate1, climsssstartdate2, climsssperiod
111
112 NAMELIST /EXF_NML_03/
113 & exf_inscal_hflux, exf_inscal_sflux, exf_inscal_evap,
114 & exf_inscal_ustress, exf_inscal_vstress,
115 & exf_inscal_uwind, exf_inscal_vwind, exf_inscal_wspeed,
116 & exf_inscal_atemp, exf_offset_atemp, exf_inscal_aqh,
117 & exf_inscal_sst, exf_inscal_sss,
118 & exf_inscal_swflux, exf_inscal_lwflux, exf_inscal_precip,
119 & exf_inscal_runoff, exf_inscal_apressure, exf_inscal_snowprecip,
120 & exf_inscal_swdown, exf_inscal_lwdown,
121 & exf_inscal_climsst, exf_inscal_climsss,
122 & exf_outscal_hflux, exf_outscal_ustress, exf_outscal_vstress,
123 & exf_outscal_swflux, exf_outscal_sst, exf_outscal_sss,
124 & exf_outscal_sflux, exf_outscal_apressure,
125 & hfluxconst, atempconst, aqhconst, sfluxconst, evapconst,
126 & precipconst, snowprecipconst, runoffconst, ustressconst,
127 & vstressconst, uwindconst, vwindconst, wspeedconst, swfluxconst,
128 & lwfluxconst, swdownconst, lwdownconst, apressureconst,
129 & areamaskconst, climsstconst, climsssconst,
130 & hflux_exfremo_intercept, hflux_exfremo_slope,
131 & atemp_exfremo_intercept, atemp_exfremo_slope,
132 & aqh_exfremo_intercept, aqh_exfremo_slope,
133 & sflux_exfremo_intercept, sflux_exfremo_slope,
134 & evap_exfremo_intercept, evap_exfremo_slope,
135 & precip_exfremo_intercept, precip_exfremo_slope,
136 & snowprecip_exfremo_intercept, snowprecip_exfremo_slope,
137 & runoff_exfremo_intercept, runoff_exfremo_slope,
138 & ustress_exfremo_intercept, ustress_exfremo_slope,
139 & vstress_exfremo_intercept, vstress_exfremo_slope,
140 & uwind_exfremo_intercept, uwind_exfremo_slope,
141 & vwind_exfremo_intercept, vwind_exfremo_slope,
142 & wspeed_exfremo_intercept, wspeed_exfremo_slope,
143 & swflux_exfremo_intercept, swflux_exfremo_slope,
144 & lwflux_exfremo_intercept, lwflux_exfremo_slope,
145 & swdown_exfremo_intercept, swdown_exfremo_slope,
146 & lwdown_exfremo_intercept, lwdown_exfremo_slope,
147 & apressure_exfremo_intercept, apressure_exfremo_slope,
148 & climsst_exfremo_intercept, climsst_exfremo_slope,
149 & climsss_exfremo_intercept, climsss_exfremo_slope
150
151 NAMELIST /EXF_NML_04/
152 & idummy
153 #ifdef USE_EXF_INTERPOLATION
154 & , ustress_lon0, ustress_lon_inc, ustress_lat0, ustress_lat_inc,
155 & vstress_lon0, vstress_lon_inc, vstress_lat0, vstress_lat_inc,
156 & ustress_nlon, ustress_nlat, vstress_nlon, vstress_nlat,
157 & hflux_lon0, hflux_lon_inc, hflux_lat0, hflux_lat_inc,
158 & sflux_lon0, sflux_lon_inc, sflux_lat0, sflux_lat_inc,
159 & hflux_nlon, hflux_nlat, sflux_nlon, sflux_nlat,
160 & swflux_lon0, swflux_lon_inc, swflux_lat0, swflux_lat_inc,
161 & lwflux_lon0, lwflux_lon_inc, lwflux_lat0, lwflux_lat_inc,
162 & swflux_nlon, swflux_nlat, lwflux_nlon, lwflux_nlat,
163 & atemp_lon0, atemp_lon_inc, atemp_lat0, atemp_lat_inc,
164 & atemp_nlon, atemp_nlat,
165 & aqh_lon0, aqh_lon_inc, aqh_lat0, aqh_lat_inc, aqh_nlon, aqh_nlat,
166 &evap_lon0,evap_lon_inc,evap_lat0,evap_lat_inc,evap_nlon,evap_nlat,
167 & precip_lon0, precip_lon_inc, precip_lat0, precip_lat_inc,
168 & runoff_lon0, runoff_lon_inc, runoff_lat0, runoff_lat_inc,
169 & precip_nlon, precip_nlat, runoff_nlon, runoff_nlat,
170 & snowprecip_lon0, snowprecip_lon_inc, snowprecip_nlon,
171 & snowprecip_lat0, snowprecip_lat_inc, snowprecip_nlat,
172 & uwind_lon0, uwind_lon_inc, uwind_lat0, uwind_lat_inc,
173 & vwind_lon0, vwind_lon_inc, vwind_lat0, vwind_lat_inc,
174 & uwind_nlon, uwind_nlat, vwind_nlon, vwind_nlat,
175 & wspeed_lon0, wspeed_lon_inc, wspeed_lat0, wspeed_lat_inc,
176 & wspeed_nlon, wspeed_nlat,
177 & swdown_lon0, swdown_lon_inc, swdown_lat0, swdown_lat_inc,
178 & lwdown_lon0, lwdown_lon_inc, lwdown_lat0, lwdown_lat_inc,
179 & swdown_nlon, swdown_nlat, lwdown_nlon, lwdown_nlat,
180 & apressure_lon0,apressure_lon_inc,apressure_nlon,
181 & apressure_lat0,apressure_lat_inc,apressure_nlat,
182 & areamask_lon0,areamask_lon_inc,areamask_nlon,
183 & areamask_lat0,areamask_lat_inc,areamask_nlat,
184 & climsst_lon0, climsst_lon_inc, climsst_nlon,
185 & climsst_lat0, climsst_lat_inc, climsst_nlat,
186 & climsss_lon0, climsss_lon_inc, climsss_nlon,
187 & climsss_lat0, climsss_lat_inc, climsss_nlat
188 #endif
189
190 NAMELIST /EXF_NML_OBCS/
191 & obcsNstartdate1, obcsNstartdate2, obcsNperiod,
192 & obcsSstartdate1, obcsSstartdate2, obcsSperiod,
193 & obcsEstartdate1, obcsEstartdate2, obcsEperiod,
194 & obcsWstartdate1, obcsWstartdate2, obcsWperiod,
195 & siobNstartdate1, siobNstartdate2, siobNperiod,
196 & siobSstartdate1, siobSstartdate2, siobSperiod,
197 & siobEstartdate1, siobEstartdate2, siobEperiod,
198 & siobWstartdate1, siobWstartdate2, siobWperiod
199
200 _BEGIN_MASTER(mythid)
201
202 c Set default values.
203
204 year2sec = 365.*86400.
205 exf_monFreq = monitorFreq
206 useExfCheckRange = .TRUE.
207 readStressOnAgrid = .FALSE.
208 readStressOnCgrid = .FALSE.
209 useRelativeWind = .FALSE.
210 noNegativeEvap = .FALSE.
211
212 C- default value should be set to main model parameter:
213 c cen2kel = celsius2K
214 c gravity_mks = gravity
215 c atmcp = atm_Cp
216 c humid_fac = atm_Rq <- default is zero !!!
217
218 cen2kel = 273.150 _d 0
219 gravity_mks = 9.81 _d 0
220 atmrho = 1.200 _d 0
221 atmcp = 1005.000 _d 0
222 flamb = 2500000.000 _d 0
223 flami = 334000.000 _d 0
224 cvapor_fac = 640380.000 _d 0
225 cvapor_exp = 5107.400 _d 0
226 cvapor_fac_ice = 11637800.000 _d 0
227 cvapor_exp_ice = 5897.800 _d 0
228 humid_fac = 0.606 _d 0
229 gamma_blk = 0.010 _d 0
230 saltsat = 0.980 _d 0
231 sstExtrapol = 0.0 _d 0
232 cdrag_1 = 0.0027000 _d 0
233 cdrag_2 = 0.0001420 _d 0
234 cdrag_3 = 0.0000764 _d 0
235 cstanton_1 = 0.0327 _d 0
236 cstanton_2 = 0.0180 _d 0
237 cdalton = 0.0346 _d 0
238 zolmin = -100.000 _d 0
239 psim_fac = 5.000 _d 0
240 zref = 10.000 _d 0
241 hu = 10.000 _d 0
242 ht = 2.000 _d 0
243 umin = 0.5 _d 0
244 useStabilityFct_overIce = .FALSE.
245 exf_iceCd = 1.63 _d -3
246 exf_iceCe = 1.63 _d -3
247 exf_iceCh = 1.63 _d -3
248 exf_albedo = 0.1 _d 0
249 c-- this default is chosen to be backward compatible with
250 c-- an earlier setting of 5.5 = ocean_emissivity*stefanBoltzmann
251 ocean_emissivity = 5.50 _d-8 / 5.670 _d-8
252 ice_emissivity = 0.95 _d 0
253 snow_emissivity = 0.95 _d 0
254
255 c Calendar data.
256 hfluxstartdate1 = 0
257 hfluxstartdate2 = 0
258 hfluxperiod = 0.0 _d 0
259 hfluxconst = 0.0 _d 0
260 hflux_exfremo_intercept = 0.0 _d 0
261 hflux_exfremo_slope = 0.0 _d 0
262
263 atempstartdate1 = 0
264 atempstartdate2 = 0
265 atempperiod = 0.0 _d 0
266 atempconst = celsius2K
267 atemp_exfremo_intercept = 0.0 _d 0
268 atemp_exfremo_slope = 0.0 _d 0
269
270 aqhstartdate1 = 0
271 aqhstartdate2 = 0
272 aqhperiod = 0.0 _d 0
273 aqhconst = 0.0 _d 0
274 aqh_exfremo_intercept = 0.0 _d 0
275 aqh_exfremo_slope = 0.0 _d 0
276
277 sfluxstartdate1 = 0
278 sfluxstartdate2 = 0
279 sfluxperiod = 0.0 _d 0
280 sfluxconst = 0.0 _d 0
281 sflux_exfremo_intercept = 0.0 _d 0
282 sflux_exfremo_slope = 0.0 _d 0
283
284 evapstartdate1 = 0
285 evapstartdate2 = 0
286 evapperiod = 0.0 _d 0
287 evapconst = 0.0 _d 0
288 evap_exfremo_intercept = 0.0 _d 0
289 evap_exfremo_slope = 0.0 _d 0
290
291 precipstartdate1 = 0
292 precipstartdate2 = 0
293 precipperiod = 0.0 _d 0
294 precipconst = 0.0 _d 0
295 precip_exfremo_intercept = 0.0 _d 0
296 precip_exfremo_slope = 0.0 _d 0
297
298 snowprecipstartdate1 = 0
299 snowprecipstartdate2 = 0
300 snowprecipperiod = 0.0 _d 0
301 snowprecipconst = 0.0 _d 0
302 snowprecip_exfremo_intercept = 0.0 _d 0
303 snowprecip_exfremo_slope = 0.0 _d 0
304
305 runoffstartdate1 = 0
306 runoffstartdate2 = 0
307 runoffperiod = 0.0 _d 0
308 runoffconst = 0.0 _d 0
309 runoff_exfremo_intercept = 0.0 _d 0
310 runoff_exfremo_slope = 0.0 _d 0
311
312 ustressstartdate1 = 0
313 ustressstartdate2 = 0
314 ustressperiod = 0.0 _d 0
315 ustressconst = 0.0 _d 0
316 ustress_exfremo_intercept = 0.0 _d 0
317 ustress_exfremo_slope = 0.0 _d 0
318
319 vstressstartdate1 = 0
320 vstressstartdate2 = 0
321 vstressperiod = 0.0 _d 0
322 vstressconst = 0.0 _d 0
323 vstress_exfremo_intercept = 0.0 _d 0
324 vstress_exfremo_slope = 0.0 _d 0
325
326 uwindstartdate1 = 0
327 uwindstartdate2 = 0
328 uwindperiod = 0.0 _d 0
329 uwindconst = 0.0 _d 0
330 uwind_exfremo_intercept = 0.0 _d 0
331 uwind_exfremo_slope = 0.0 _d 0
332
333 vwindstartdate1 = 0
334 vwindstartdate2 = 0
335 vwindperiod = 0.0 _d 0
336 vwindconst = 0.0 _d 0
337 vwind_exfremo_intercept = 0.0 _d 0
338 vwind_exfremo_slope = 0.0 _d 0
339
340 wspeedstartdate1 = 0
341 wspeedstartdate2 = 0
342 wspeedperiod = 0.0 _d 0
343 wspeedconst = 0.0 _d 0
344 wspeed_exfremo_intercept = 0.0 _d 0
345 wspeed_exfremo_slope = 0.0 _d 0
346
347 swfluxstartdate1 = 0
348 swfluxstartdate2 = 0
349 swfluxperiod = 0.0 _d 0
350 swfluxconst = 0.0 _d 0
351 swflux_exfremo_intercept = 0.0 _d 0
352 swflux_exfremo_slope = 0.0 _d 0
353
354 lwfluxstartdate1 = 0
355 lwfluxstartdate2 = 0
356 lwfluxperiod = 0.0 _d 0
357 lwfluxconst = 0.0 _d 0
358 lwflux_exfremo_intercept = 0.0 _d 0
359 lwflux_exfremo_slope = 0.0 _d 0
360
361 swdownstartdate1 = 0
362 swdownstartdate2 = 0
363 swdownperiod = 0.0 _d 0
364 swdownconst = 0.0 _d 0
365 swdown_exfremo_intercept = 0.0 _d 0
366 swdown_exfremo_slope = 0.0 _d 0
367
368 lwdownstartdate1 = 0
369 lwdownstartdate2 = 0
370 lwdownperiod = 0.0 _d 0
371 lwdownconst = 0.0 _d 0
372 lwdown_exfremo_intercept = 0.0 _d 0
373 lwdown_exfremo_slope = 0.0 _d 0
374
375 apressurestartdate1 = 0
376 apressurestartdate2 = 0
377 apressureperiod = 0.0 _d 0
378 apressureconst = 0.0 _d 0
379 apressure_exfremo_intercept = 0.0 _d 0
380 apressure_exfremo_slope = 0.0 _d 0
381
382 areamaskstartdate1 = 0
383 areamaskstartdate2 = 0
384 areamaskperiod = 0.0 _d 0
385 areamaskconst = 0.0 _d 0
386
387 climsststartdate1 = 0
388 climsststartdate2 = 0
389 climsstperiod = 0
390 climsstconst = 0.0 _d 0
391 climsst_exfremo_intercept = 0.0 _d 0
392 climsst_exfremo_slope = 0.0 _d 0
393
394 climsssstartdate1 = 0
395 climsssstartdate2 = 0
396 climsssperiod = 0
397 climsssconst = 0.0 _d 0
398 climsss_exfremo_intercept = 0.0 _d 0
399 climsss_exfremo_slope = 0.0 _d 0
400
401 obcsNstartdate1 = 0
402 obcsNstartdate2 = 0
403 obcsNperiod = 0.0 _d 0
404 obcsSstartdate1 = 0
405 obcsSstartdate2 = 0
406 obcsSperiod = 0.0 _d 0
407 obcsEstartdate1 = 0
408 obcsEstartdate2 = 0
409 obcsEperiod = 0.0 _d 0
410 obcsWstartdate1 = 0
411 obcsWstartdate2 = 0
412 obcsWperiod = 0.0 _d 0
413
414 siobNstartdate1 = UNSET_I
415 siobNstartdate2 = UNSET_I
416 siobNperiod = UNSET_RL
417 siobSstartdate1 = UNSET_I
418 siobSstartdate2 = UNSET_I
419 siobSperiod = UNSET_RL
420 siobEstartdate1 = UNSET_I
421 siobEstartdate2 = UNSET_I
422 siobEperiod = UNSET_RL
423 siobWstartdate1 = UNSET_I
424 siobWstartdate2 = UNSET_I
425 siobWperiod = UNSET_RL
426
427 repeatPeriod = 0.0 _d 0
428 windstressmax = 2.0 _d 0
429
430 exf_scal_BulkCdn = 1.0 _d 0
431
432 c Initialise freezing temperature of sea water
433 climtempfreeze = -1.9 _d 0
434
435 c Data files.
436 hfluxfile = ' '
437 atempfile = ' '
438 aqhfile = ' '
439 evapfile = ' '
440 precipfile = ' '
441 snowprecipfile = ' '
442 sfluxfile = ' '
443 runofffile = ' '
444 ustressfile = ' '
445 vstressfile = ' '
446 uwindfile = ' '
447 vwindfile = ' '
448 wspeedfile = ' '
449 swfluxfile = ' '
450 lwfluxfile = ' '
451 swdownfile = ' '
452 lwdownfile = ' '
453 apressurefile = ' '
454 areamaskfile = ' '
455 climsstfile = ' '
456 climsssfile = ' '
457
458 c Start dates.
459 hfluxstartdate = 0.
460 atempstartdate = 0.
461 aqhstartdate = 0.
462 evapstartdate = 0.
463 precipstartdate = 0.
464 snowprecipstartdate= 0.
465 sfluxstartdate = 0.
466 runoffstartdate = 0.
467 ustressstartdate = 0.
468 vstressstartdate = 0.
469 uwindstartdate = 0.
470 vwindstartdate = 0.
471 wspeedstartdate = 0.
472 swfluxstartdate = 0.
473 lwfluxstartdate = 0.
474 swdownstartdate = 0.
475 lwdownstartdate = 0.
476 obcsNstartdate = 0.
477 obcsSstartdate = 0.
478 obcsEstartdate = 0.
479 obcsWstartdate = 0.
480 siobNstartdate = 0.
481 siobSstartdate = 0.
482 siobEstartdate = 0.
483 siobWstartdate = 0.
484 apressurestartdate = 0.
485 areamaskstartdate = 0.
486 climsststartdate = 0.
487 climsssstartdate = 0.
488
489 c Initialise file type and field precision
490 exf_iprec = 32
491 exf_yftype = 'RL'
492 useExfYearlyFields = .FALSE.
493 twoDigitYear = .FALSE.
494
495 c Input scaling factors.
496 exf_inscal_hflux = 1. _d 0
497 exf_inscal_sflux = 1. _d 0
498 exf_inscal_ustress = 1. _d 0
499 exf_inscal_vstress = 1. _d 0
500 exf_inscal_uwind = 1. _d 0
501 exf_inscal_vwind = 1. _d 0
502 exf_inscal_wspeed = 1. _d 0
503 exf_inscal_swflux = 1. _d 0
504 exf_inscal_lwflux = 1. _d 0
505 exf_inscal_precip = 1. _d 0
506 exf_inscal_snowprecip= 1. _d 0
507 exf_inscal_sst = 1. _d 0
508 exf_inscal_sss = 1. _d 0
509 exf_inscal_atemp = 1. _d 0
510 exf_offset_atemp = 0. _d 0
511 exf_inscal_aqh = 1. _d 0
512 exf_inscal_evap = 1. _d 0
513 exf_inscal_apressure = 1. _d 0
514 exf_inscal_runoff = 1. _d 0
515 exf_inscal_swdown = 1. _d 0
516 exf_inscal_lwdown = 1. _d 0
517 exf_inscal_climsst = 1. _d 0
518 exf_inscal_climsss = 1. _d 0
519
520 c Output scaling factors.
521 exf_outscal_hflux = 1. _d 0
522 exf_outscal_sflux = 1. _d 0
523 exf_outscal_ustress = 1. _d 0
524 exf_outscal_vstress = 1. _d 0
525 exf_outscal_swflux = 1. _d 0
526 exf_outscal_sst = 1. _d 0
527 exf_outscal_sss = 1. _d 0
528 exf_outscal_apressure= 1. _d 0
529
530 #ifdef USE_EXF_INTERPOLATION
531 ustress_lon0 = xgOrigin
532 uwind_lon0 = xgOrigin
533 vstress_lon0 = xgOrigin + delX(1)*exf_half
534 hflux_lon0 = xgOrigin + delX(1)*exf_half
535 sflux_lon0 = xgOrigin + delX(1)*exf_half
536 swflux_lon0 = xgOrigin + delX(1)*exf_half
537 runoff_lon0 = xgOrigin + delX(1)*exf_half
538 atemp_lon0 = xgOrigin + delX(1)*exf_half
539 aqh_lon0 = xgOrigin + delX(1)*exf_half
540 evap_lon0 = xgOrigin + delX(1)*exf_half
541 precip_lon0 = xgOrigin + delX(1)*exf_half
542 snowprecip_lon0= xgOrigin + delX(1)*exf_half
543 vwind_lon0 = xgOrigin + delX(1)*exf_half
544 wspeed_lon0 = xgOrigin + delX(1)*exf_half
545 lwflux_lon0 = xgOrigin + delX(1)*exf_half
546 swdown_lon0 = xgOrigin + delX(1)*exf_half
547 lwdown_lon0 = xgOrigin + delX(1)*exf_half
548 apressure_lon0 = xgOrigin + delX(1)*exf_half
549 areamask_lon0 = xgOrigin + delX(1)*exf_half
550 vstress_lat0 = ygOrigin
551 vwind_lat0 = ygOrigin
552 wspeed_lat0 = ygOrigin
553 ustress_lat0 = ygOrigin + delY(1)*exf_half
554 hflux_lat0 = ygOrigin + delY(1)*exf_half
555 sflux_lat0 = ygOrigin + delY(1)*exf_half
556 runoff_lat0 = ygOrigin + delY(1)*exf_half
557 swflux_lat0 = ygOrigin + delY(1)*exf_half
558 atemp_lat0 = ygOrigin + delY(1)*exf_half
559 aqh_lat0 = ygOrigin + delY(1)*exf_half
560 evap_lat0 = ygOrigin + delY(1)*exf_half
561 precip_lat0 = ygOrigin + delY(1)*exf_half
562 snowprecip_lat0= ygOrigin + delY(1)*exf_half
563 uwind_lat0 = ygOrigin + delY(1)*exf_half
564 lwflux_lat0 = ygOrigin + delY(1)*exf_half
565 swdown_lat0 = ygOrigin + delY(1)*exf_half
566 lwdown_lat0 = ygOrigin + delY(1)*exf_half
567 apressure_lat0 = ygOrigin + delY(1)*exf_half
568 areamask_lat0 = ygOrigin + delY(1)*exf_half
569 ustress_nlon = Nx
570 ustress_nlat = Ny
571 vstress_nlon = Nx
572 vstress_nlat = Ny
573 hflux_nlon = Nx
574 hflux_nlat = Ny
575 sflux_nlon = Nx
576 sflux_nlat = Ny
577 swflux_nlon = Nx
578 swflux_nlat = Ny
579 runoff_nlon = Nx
580 runoff_nlat = Ny
581 atemp_nlon = Nx
582 atemp_nlat = Ny
583 aqh_nlon = Nx
584 aqh_nlat = Ny
585 evap_nlon = Nx
586 evap_nlat = Ny
587 precip_nlon = Nx
588 snowprecip_nlon= Nx
589 precip_nlat = Ny
590 snowprecip_nlat= Ny
591 uwind_nlon = Nx
592 uwind_nlat = Ny
593 vwind_nlon = Nx
594 vwind_nlat = Ny
595 wspeed_nlon = Nx
596 wspeed_nlat = Ny
597 lwflux_nlon = Nx
598 lwflux_nlat = Ny
599 swdown_nlon = Nx
600 swdown_nlat = Ny
601 lwdown_nlon = Nx
602 lwdown_nlat = Ny
603 apressure_nlon = Nx
604 apressure_nlat = Ny
605 areamask_nlon = Nx
606 areamask_nlat = Ny
607 Ustress_lon_inc = delX(1)
608 vstress_lon_inc = delX(1)
609 hflux_lon_inc = delX(1)
610 sflux_lon_inc = delX(1)
611 swflux_lon_inc = delX(1)
612 runoff_lon_inc = delX(1)
613 atemp_lon_inc = delX(1)
614 aqh_lon_inc = delX(1)
615 evap_lon_inc = delX(1)
616 precip_lon_inc = delX(1)
617 snowprecip_lon_inc= delX(1)
618 uwind_lon_inc = delX(1)
619 vwind_lon_inc = delX(1)
620 wspeed_lon_inc = delX(1)
621 lwflux_lon_inc = delX(1)
622 swdown_lon_inc = delX(1)
623 lwdown_lon_inc = delX(1)
624 apressure_lon_inc = delX(1)
625 areamask_lon_inc = delX(1)
626 climsst_lon0 = xgOrigin + delX(1)*exf_half
627 climsss_lon0 = xgOrigin + delX(1)*exf_half
628 climsst_lat0 = ygOrigin + delY(1)*exf_half
629 climsss_lat0 = ygOrigin + delY(1)*exf_half
630 climsst_nlon = Nx
631 climsst_nlat = Ny
632 climsss_nlon = Nx
633 climsss_nlat = Ny
634 climsst_lon_inc = delX(1)
635 climsss_lon_inc = delX(1)
636 DO i=1,MAX_LAT_INC
637 IF (i.LT.Ny) THEN
638 vstress_lat_inc(i) = delY(i)
639 vwind_lat_inc(i) = delY(i)
640 wspeed_lat_inc(i) = delY(i)
641 ustress_lat_inc(i) = (delY(i) + delY(i))*exf_half
642 hflux_lat_inc(i) = (delY(i) + delY(i))*exf_half
643 sflux_lat_inc(i) = (delY(i) + delY(i))*exf_half
644 swflux_lat_inc(i) = (delY(i) + delY(i))*exf_half
645 runoff_lat_inc(i) = (delY(i) + delY(i))*exf_half
646 atemp_lat_inc(i) = (delY(i) + delY(i))*exf_half
647 aqh_lat_inc(i) = (delY(i) + delY(i))*exf_half
648 evap_lat_inc(i) = (delY(i) + delY(i))*exf_half
649 precip_lat_inc(i) = (delY(i) + delY(i))*exf_half
650 snowprecip_lat_inc(i)= (delY(i) + delY(i))*exf_half
651 uwind_lat_inc(i) = (delY(i) + delY(i))*exf_half
652 lwflux_lat_inc(i) = (delY(i) + delY(i))*exf_half
653 swdown_lat_inc(i) = (delY(i) + delY(i))*exf_half
654 lwdown_lat_inc(i) = (delY(i) + delY(i))*exf_half
655 apressure_lat_inc(i) = (delY(i) + delY(i))*exf_half
656 areamask_lat_inc(i) = (delY(i) + delY(i))*exf_half
657 climsst_lat_inc(i) = (delY(i) + delY(i))*exf_half
658 climsss_lat_inc(i) = (delY(i) + delY(i))*exf_half
659 ELSE
660 ustress_lat_inc(i) = 0.
661 vstress_lat_inc(i) = 0.
662 hflux_lat_inc(i) = 0.
663 sflux_lat_inc(i) = 0.
664 swflux_lat_inc(i) = 0.
665 runoff_lat_inc(i) = 0.
666 atemp_lat_inc(i) = 0.
667 aqh_lat_inc(i) = 0.
668 evap_lat_inc(i) = 0.
669 precip_lat_inc(i) = 0.
670 snowprecip_lat_inc(i)= 0.
671 uwind_lat_inc(i) = 0.
672 vwind_lat_inc(i) = 0.
673 wspeed_lat_inc(i) = 0.
674 lwflux_lat_inc(i) = 0.
675 swdown_lat_inc(i) = 0.
676 lwdown_lat_inc(i) = 0.
677 apressure_lat_inc(i) = 0.
678 areamask_lat_inc(i) = 0.
679 climsst_lat_inc(i) = 0.
680 climsss_lat_inc(i) = 0.
681 ENDIF
682 ENDDO
683 #endif /* USE_EXF_INTERPOLATION */
684
685 c Next, read the forcing data file.
686 WRITE(msgBuf,'(A)') 'EXF_READPARMS: opening data.exf'
687 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
688 & SQUEEZE_RIGHT , 1)
689
690 CALL OPEN_COPY_DATA_FILE(
691 I 'data.exf', 'EXF_READPARMS',
692 O iUnit,
693 I myThid )
694
695 WRITE(msgBuf,'(A)')
696 & 'EXF_READPARMS: reading EXF_NML_01'
697 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
698 & SQUEEZE_RIGHT , 1)
699 READ( iUnit, nml = EXF_NML_01 )
700 WRITE(msgBuf,'(A)')
701 & 'EXF_READPARMS: reading EXF_NML_02'
702 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
703 & SQUEEZE_RIGHT , 1)
704 READ( iUnit, nml = EXF_NML_02 )
705 WRITE(msgBuf,'(A)')
706 & 'EXF_READPARMS: reading EXF_NML_03'
707 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
708 & SQUEEZE_RIGHT , 1)
709 READ( iUnit, nml = EXF_NML_03 )
710 WRITE(msgBuf,'(A)')
711 & 'EXF_READPARMS: reading EXF_NML_04'
712 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
713 & SQUEEZE_RIGHT , 1)
714 READ( iUnit, nml = EXF_NML_04 )
715 #ifdef ALLOW_OBCS
716 WRITE(msgBuf,'(A)')
717 & 'EXF_READPARMS: reading EXF_NML_OBCS'
718 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
719 & SQUEEZE_RIGHT , 1)
720 READ( iUnit, nml = EXF_NML_OBCS )
721 IF(siobNstartdate1.EQ.UNSET_I ) siobNstartdate1 = obcsNstartdate1
722 IF(siobNstartdate2.EQ.UNSET_I ) siobNstartdate2 = obcsNstartdate2
723 IF(siobNperiod .EQ.UNSET_RL) siobNperiod = obcsNperiod
724 IF(siobSstartdate1.EQ.UNSET_I ) siobSstartdate1 = obcsSstartdate1
725 IF(siobSstartdate2.EQ.UNSET_I ) siobSstartdate2 = obcsSstartdate2
726 IF(siobSperiod .EQ.UNSET_RL) siobSperiod = obcsSperiod
727 IF(siobEstartdate1.EQ.UNSET_I ) siobEstartdate1 = obcsEstartdate1
728 IF(siobEstartdate2.EQ.UNSET_I ) siobEstartdate2 = obcsEstartdate2
729 IF(siobEperiod .EQ.UNSET_RL) siobEperiod = obcsEperiod
730 IF(siobWstartdate1.EQ.UNSET_I ) siobWstartdate1 = obcsWstartdate1
731 IF(siobWstartdate2.EQ.UNSET_I ) siobWstartdate2 = obcsWstartdate2
732 IF(siobWperiod .EQ.UNSET_RL) siobWperiod = obcsWperiod
733 #endif
734
735 WRITE(msgBuf,'(A)')
736 & 'EXF_READPARMS: finished reading data.exf'
737 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
738 & SQUEEZE_RIGHT , 1)
739
740 CLOSE( iUnit )
741
742 C-- Derive other parameters:
743 hq = ht
744 #if ( ( defined (ALLOW_BULKFORMULAE) && defined (ALLOW_ATM_WIND) ) \
745 || defined (USE_EXF_INTERPOLATION) )
746 stressIsOnCgrid = .FALSE.
747 #else
748 stressIsOnCgrid = readStressOnCgrid
749 #endif
750
751 CALL EXF_CHECK( myThid )
752
753 c Complete the start date specifications for the forcing
754 c fields to get a complete calendar date array.
755 C => moved to EXF_INIT_FIXED
756
757 _END_MASTER( mythid )
758 _BARRIER
759
760 RETURN
761 END

  ViewVC Help
Powered by ViewVC 1.1.22