4 |
|
|
5 |
#include "EXF_OPTIONS.h" |
#include "EXF_OPTIONS.h" |
6 |
|
|
7 |
subroutine exf_getffields( mycurrenttime, mycurrentiter, mythid ) |
subroutine exf_getffields( mytime, myiter, mythid ) |
8 |
|
|
9 |
c ================================================================== |
c ================================================================== |
10 |
c SUBROUTINE exf_getffields |
c SUBROUTINE exf_getffields |
41 |
c == routine arguments == |
c == routine arguments == |
42 |
|
|
43 |
integer mythid |
integer mythid |
44 |
integer mycurrentiter |
integer myiter |
45 |
_RL mycurrenttime |
_RL mytime |
46 |
|
|
47 |
c == local variables == |
c == local variables == |
48 |
|
|
68 |
& vstress_lon0, vstress_lon_inc, vstress_lat0, vstress_lat_inc, |
& vstress_lon0, vstress_lon_inc, vstress_lat0, vstress_lat_inc, |
69 |
& vstress_nlon, vstress_nlat, |
& vstress_nlon, vstress_nlat, |
70 |
& vstress_exfremo_intercept, vstress_exfremo_slope, |
& vstress_exfremo_intercept, vstress_exfremo_slope, |
71 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
72 |
#else /* ifndef USE_EXF_INTERPOLATION */ |
#else /* ifndef USE_EXF_INTERPOLATION */ |
73 |
call exf_set_gen( |
call exf_set_gen( |
74 |
& ustressfile, ustressstartdate, ustressperiod, |
& ustressfile, ustressstartdate, ustressperiod, |
76 |
& exf_inscal_ustress, |
& exf_inscal_ustress, |
77 |
& ustress_exfremo_intercept, ustress_exfremo_slope, |
& ustress_exfremo_intercept, ustress_exfremo_slope, |
78 |
& ustress, ustress0, ustress1, ustressmask, |
& ustress, ustress0, ustress1, ustressmask, |
79 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
80 |
call exf_set_gen( |
call exf_set_gen( |
81 |
& vstressfile, vstressstartdate, vstressperiod, |
& vstressfile, vstressstartdate, vstressperiod, |
82 |
& ustressstartdate1, ustressstartdate2, |
& ustressstartdate1, ustressstartdate2, |
83 |
& exf_inscal_vstress, |
& exf_inscal_vstress, |
84 |
& vstress_exfremo_intercept, vstress_exfremo_slope, |
& vstress_exfremo_intercept, vstress_exfremo_slope, |
85 |
& vstress, vstress0, vstress1, vstressmask, |
& vstress, vstress0, vstress1, vstressmask, |
86 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
87 |
#endif /* USE_EXF_INTERPOLATION */ |
#endif /* USE_EXF_INTERPOLATION */ |
88 |
|
|
89 |
#ifdef ALLOW_ATM_WIND |
#ifdef ALLOW_ATM_WIND |
103 |
& vwind_lon0, vwind_lon_inc, vwind_lat0, vwind_lat_inc, |
& vwind_lon0, vwind_lon_inc, vwind_lat0, vwind_lat_inc, |
104 |
& vwind_nlon, vwind_nlat, |
& vwind_nlon, vwind_nlat, |
105 |
& vwind_exfremo_intercept, vwind_exfremo_slope, |
& vwind_exfremo_intercept, vwind_exfremo_slope, |
106 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
107 |
#else /* ifndef USE_EXF_INTERPOLATION */ |
#else /* ifndef USE_EXF_INTERPOLATION */ |
108 |
call exf_set_gen( |
call exf_set_gen( |
109 |
& uwindfile, uwindstartdate, uwindperiod, |
& uwindfile, uwindstartdate, uwindperiod, |
111 |
& exf_inscal_uwind, |
& exf_inscal_uwind, |
112 |
& uwind_exfremo_intercept, uwind_exfremo_slope, |
& uwind_exfremo_intercept, uwind_exfremo_slope, |
113 |
& uwind, uwind0, uwind1, uwindmask, |
& uwind, uwind0, uwind1, uwindmask, |
114 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
115 |
call exf_set_gen( |
call exf_set_gen( |
116 |
& vwindfile, vwindstartdate, vwindperiod, |
& vwindfile, vwindstartdate, vwindperiod, |
117 |
& vwindstartdate1, vwindstartdate2, |
& vwindstartdate1, vwindstartdate2, |
118 |
& exf_inscal_vwind, |
& exf_inscal_vwind, |
119 |
& vwind_exfremo_intercept, vwind_exfremo_slope, |
& vwind_exfremo_intercept, vwind_exfremo_slope, |
120 |
& vwind, vwind0, vwind1, vwindmask, |
& vwind, vwind0, vwind1, vwindmask, |
121 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
122 |
#endif /* USE_EXF_INTERPOLATION */ |
#endif /* USE_EXF_INTERPOLATION */ |
123 |
|
|
124 |
#endif /* ALLOW_ATM_WIND */ |
#endif /* ALLOW_ATM_WIND */ |
134 |
& hflux_lon0, hflux_lon_inc, hflux_lat0, hflux_lat_inc, |
& hflux_lon0, hflux_lon_inc, hflux_lat0, hflux_lat_inc, |
135 |
& hflux_nlon, hflux_nlat, xC, yC, interp_method, |
& hflux_nlon, hflux_nlat, xC, yC, interp_method, |
136 |
#endif |
#endif |
137 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
138 |
|
|
139 |
c Salt flux. |
c Salt flux. |
140 |
call exf_set_gen ( |
call exf_set_gen ( |
147 |
& sflux_lon0, sflux_lon_inc, sflux_lat0, sflux_lat_inc, |
& sflux_lon0, sflux_lon_inc, sflux_lat0, sflux_lat_inc, |
148 |
& sflux_nlon, sflux_nlat, xC, yC, interp_method, |
& sflux_nlon, sflux_nlat, xC, yC, interp_method, |
149 |
#endif |
#endif |
150 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
151 |
|
|
152 |
#ifdef ALLOW_ATM_TEMP |
#ifdef ALLOW_ATM_TEMP |
153 |
|
|
162 |
& atemp_lon0, atemp_lon_inc, atemp_lat0, atemp_lat_inc, |
& atemp_lon0, atemp_lon_inc, atemp_lat0, atemp_lat_inc, |
163 |
& atemp_nlon, atemp_nlat, xC, yC, interp_method, |
& atemp_nlon, atemp_nlat, xC, yC, interp_method, |
164 |
#endif |
#endif |
165 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
166 |
do bj = mybylo(mythid),mybyhi(mythid) |
do bj = mybylo(mythid),mybyhi(mythid) |
167 |
do bi = mybxlo(mythid),mybxhi(mythid) |
do bi = mybxlo(mythid),mybxhi(mythid) |
168 |
do j = 1,sny |
do j = 1,sny |
184 |
& aqh_lon0, aqh_lon_inc, aqh_lat0, aqh_lat_inc, |
& aqh_lon0, aqh_lon_inc, aqh_lat0, aqh_lat_inc, |
185 |
& aqh_nlon, aqh_nlat, xC, yC, interp_method, |
& aqh_nlon, aqh_nlat, xC, yC, interp_method, |
186 |
#endif |
#endif |
187 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
188 |
|
|
189 |
c Net long wave radiative flux. |
c Net long wave radiative flux. |
190 |
call exf_set_gen( |
call exf_set_gen( |
197 |
& lwflux_lon0, lwflux_lon_inc, lwflux_lat0, lwflux_lat_inc, |
& lwflux_lon0, lwflux_lon_inc, lwflux_lat0, lwflux_lat_inc, |
198 |
& lwflux_nlon, lwflux_nlat, xC, yC, interp_method, |
& lwflux_nlon, lwflux_nlat, xC, yC, interp_method, |
199 |
#endif |
#endif |
200 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
201 |
|
|
202 |
c Precipitation. |
c Precipitation. |
203 |
call exf_set_gen( |
call exf_set_gen( |
210 |
& precip_lon0, precip_lon_inc, precip_lat0, precip_lat_inc, |
& precip_lon0, precip_lon_inc, precip_lat0, precip_lat_inc, |
211 |
& precip_nlon, precip_nlat, xC, yC, interp_method, |
& precip_nlon, precip_nlat, xC, yC, interp_method, |
212 |
#endif |
#endif |
213 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
214 |
|
|
215 |
#endif /* ALLOW_ATM_TEMP */ |
#endif /* ALLOW_ATM_TEMP */ |
216 |
|
|
226 |
& swflux_lon0, swflux_lon_inc, swflux_lat0, swflux_lat_inc, |
& swflux_lon0, swflux_lon_inc, swflux_lat0, swflux_lat_inc, |
227 |
& swflux_nlon, swflux_nlat, xC, yC, interp_method, |
& swflux_nlon, swflux_nlat, xC, yC, interp_method, |
228 |
#endif |
#endif |
229 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
230 |
#endif |
#endif |
231 |
|
|
232 |
#ifdef EXF_READ_EVAP |
#ifdef EXF_READ_EVAP |
241 |
& evap_lon0, evap_lon_inc, evap_lat0, evap_lat_inc, |
& evap_lon0, evap_lon_inc, evap_lat0, evap_lat_inc, |
242 |
& evap_nlon, evap_nlat, xC, yC, interp_method, |
& evap_nlon, evap_nlat, xC, yC, interp_method, |
243 |
#endif |
#endif |
244 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
245 |
#endif |
#endif |
246 |
|
|
247 |
#ifdef ALLOW_DOWNWARD_RADIATION |
#ifdef ALLOW_DOWNWARD_RADIATION |
257 |
& swdown_lon0, swdown_lon_inc, swdown_lat0, swdown_lat_inc, |
& swdown_lon0, swdown_lon_inc, swdown_lat0, swdown_lat_inc, |
258 |
& swdown_nlon, swdown_nlat, xC, yC, interp_method, |
& swdown_nlon, swdown_nlat, xC, yC, interp_method, |
259 |
#endif |
#endif |
260 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
261 |
|
|
262 |
c Downward longwave radiation. |
c Downward longwave radiation. |
263 |
call exf_set_gen ( |
call exf_set_gen ( |
270 |
& lwdown_lon0, lwdown_lon_inc, lwdown_lat0, lwdown_lat_inc, |
& lwdown_lon0, lwdown_lon_inc, lwdown_lat0, lwdown_lat_inc, |
271 |
& lwdown_nlon, lwdown_nlat, xC, yC, interp_method, |
& lwdown_nlon, lwdown_nlat, xC, yC, interp_method, |
272 |
#endif |
#endif |
273 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
274 |
|
|
275 |
#endif |
#endif |
276 |
|
|
287 |
& apressure_lat_inc, apressure_nlon, apressure_nlat, xC, yC, |
& apressure_lat_inc, apressure_nlon, apressure_nlat, xC, yC, |
288 |
& interp_method, |
& interp_method, |
289 |
#endif |
#endif |
290 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
291 |
#endif |
#endif |
292 |
|
|
293 |
c-- Control variables for atmos. state |
c-- Control variables for atmos. state |
297 |
& xx_atemp_file, xx_atempstartdate, xx_atempperiod, |
& xx_atemp_file, xx_atempstartdate, xx_atempperiod, |
298 |
& maskc, atemp, xx_atemp0, xx_atemp1, xx_atemp_dummy, |
& maskc, atemp, xx_atemp0, xx_atemp1, xx_atemp_dummy, |
299 |
& xx_atemp_remo_intercept, xx_atemp_remo_slope, |
& xx_atemp_remo_intercept, xx_atemp_remo_slope, |
300 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
301 |
#endif |
#endif |
302 |
|
|
303 |
#ifdef ALLOW_AQH_CONTROL |
#ifdef ALLOW_AQH_CONTROL |
305 |
& xx_aqh_file, xx_aqhstartdate, xx_aqhperiod, |
& xx_aqh_file, xx_aqhstartdate, xx_aqhperiod, |
306 |
& maskc, aqh, xx_aqh0, xx_aqh1, xx_aqh_dummy, |
& maskc, aqh, xx_aqh0, xx_aqh1, xx_aqh_dummy, |
307 |
& xx_aqh_remo_intercept, xx_aqh_remo_slope, |
& xx_aqh_remo_intercept, xx_aqh_remo_slope, |
308 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
309 |
#endif |
#endif |
310 |
|
|
311 |
#ifdef ALLOW_PRECIP_CONTROL |
#ifdef ALLOW_PRECIP_CONTROL |
313 |
& xx_precip_file, xx_precipstartdate, xx_precipperiod, |
& xx_precip_file, xx_precipstartdate, xx_precipperiod, |
314 |
& maskc, precip, xx_precip0, xx_precip1, xx_precip_dummy, |
& maskc, precip, xx_precip0, xx_precip1, xx_precip_dummy, |
315 |
& xx_precip_remo_intercept, xx_precip_remo_slope, |
& xx_precip_remo_intercept, xx_precip_remo_slope, |
316 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
317 |
#endif |
#endif |
318 |
|
|
319 |
#ifdef ALLOW_SWFLUX_CONTROL |
#ifdef ALLOW_SWFLUX_CONTROL |
321 |
& xx_swflux_file, xx_swfluxstartdate, xx_swfluxperiod, |
& xx_swflux_file, xx_swfluxstartdate, xx_swfluxperiod, |
322 |
& maskc, swflux, xx_swflux0, xx_swflux1, xx_swflux_dummy, |
& maskc, swflux, xx_swflux0, xx_swflux1, xx_swflux_dummy, |
323 |
& xx_swflux_remo_intercept, xx_swflux_remo_slope, |
& xx_swflux_remo_intercept, xx_swflux_remo_slope, |
324 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
325 |
#endif |
#endif |
326 |
|
|
327 |
#ifdef ALLOW_SWDOWN_CONTROL |
#ifdef ALLOW_SWDOWN_CONTROL |
329 |
& xx_swdown_file, xx_swdownstartdate, xx_swdownperiod, |
& xx_swdown_file, xx_swdownstartdate, xx_swdownperiod, |
330 |
& maskc, swdown, xx_swdown0, xx_swdown1, xx_swdown_dummy, |
& maskc, swdown, xx_swdown0, xx_swdown1, xx_swdown_dummy, |
331 |
& xx_swdown_remo_intercept, xx_swdown_remo_slope, |
& xx_swdown_remo_intercept, xx_swdown_remo_slope, |
332 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
333 |
#endif |
#endif |
334 |
|
|
335 |
#ifdef ALLOW_UWIND_CONTROL |
#ifdef ALLOW_UWIND_CONTROL |
337 |
& xx_uwind_file, xx_uwindstartdate, xx_uwindperiod, |
& xx_uwind_file, xx_uwindstartdate, xx_uwindperiod, |
338 |
& maskc, uwind, xx_uwind0, xx_uwind1, xx_uwind_dummy, |
& maskc, uwind, xx_uwind0, xx_uwind1, xx_uwind_dummy, |
339 |
& xx_uwind_remo_intercept, xx_uwind_remo_slope, |
& xx_uwind_remo_intercept, xx_uwind_remo_slope, |
340 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
341 |
#endif /* ALLOW_UWIND_CONTROL */ |
#endif /* ALLOW_UWIND_CONTROL */ |
342 |
|
|
343 |
#ifdef ALLOW_VWIND_CONTROL |
#ifdef ALLOW_VWIND_CONTROL |
345 |
& xx_vwind_file, xx_vwindstartdate, xx_vwindperiod, |
& xx_vwind_file, xx_vwindstartdate, xx_vwindperiod, |
346 |
& maskc, vwind, xx_vwind0, xx_vwind1, xx_vwind_dummy, |
& maskc, vwind, xx_vwind0, xx_vwind1, xx_vwind_dummy, |
347 |
& xx_vwind_remo_intercept, xx_vwind_remo_slope, |
& xx_vwind_remo_intercept, xx_vwind_remo_slope, |
348 |
& mycurrenttime, mycurrentiter, mythid ) |
& mytime, myiter, mythid ) |
349 |
#endif /* ALLOW_VWIND_CONTROL */ |
#endif /* ALLOW_VWIND_CONTROL */ |
350 |
|
|
351 |
#ifdef ALLOW_LWFLUX_CONTROL |
#ifdef ALLOW_LWFLUX_CONTROL |