/[MITgcm]/MITgcm/pkg/ecco/ecco_cost.h
ViewVC logotype

Contents of /MITgcm/pkg/ecco/ecco_cost.h

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


Revision 1.11 - (show annotations) (download)
Wed Sep 7 03:02:11 2005 UTC (18 years, 9 months ago) by heimbach
Branch: MAIN
CVS Tags: checkpoint57t_post, checkpoint57v_post, checkpoint57s_post, checkpoint57r_post, checkpint57u_post
Changes since 1.10: +5 -1 lines
File MIME type: text/plain
Introduce nnztbar, nnzsbar to distinguish btw 2d/3d bar files
at initialisation time.

1
2 c ==================================================================
3 c HEADER AVERAGES
4 c ==================================================================
5 c
6 c o Header for averaged temperature, salinity, and surface pressure
7 c fields and counters associated with the averaging.
8 c
9 c started: Christian Eckert eckert@mit.edu 30-Jun-1999
10 c
11 c ==================================================================
12 c HEADER AVERAGES
13 c ==================================================================
14
15 c Averaging counters:
16 c ===================
17 c
18 c sum1day - counter for the daily averaging
19 c sum1mon - counter for the monthly averaging
20 c dayrec - number of averaged surface pressure records.
21 c monrec - number of averaged theta and salinity records.
22
23 common /average_i/
24 & sum1day,sum1mon,
25 & dayrec,monrec
26 integer sum1day
27 integer sum1mon
28 integer dayrec
29 integer monrec
30
31
32 c Averaged Fields:
33 c ================
34 c
35 c tbar - contains the averaged temperature field after the call
36 c to subroutine POST_MONTHLY. Before, it accumulates the
37 c intantaneous temperatures.
38 c sbar - contains the averaged salinity field after the call
39 c to subroutine POST_MONTHLY. Before, it accumulates the
40 c intantaneous salinities.
41 c psbar - contains the averaged surface pressure field after the call
42 c to subroutine POST_DAILY. Before, it accumulates the
43 c intantaneous surface pressure field.
44 c ubar - contains the averaged zonal velocity component for the
45 c whole integration period. Before, it accumulates the
46 c intantaneous field.
47 c vbar - contains the averaged zonal velocity component for the
48 c whole integration period. Before, it accumulates the
49 c intantaneous field.
50 c tauxbar - contains the averaged zonal velocity component for the
51 c whole integration period. Before, it accumulates the
52 c intantaneous field.
53 c tauybar - contains the averaged zonal velocity component for the
54 c whole integration period. Before, it accumulates the
55 c intantaneous field.
56 c hfluxbar - contains the averaged zonal velocity component for the
57 c whole integration period. Before, it accumulates the
58 c intantaneous field.
59 c sfluxbar - contains the averaged zonal velocity component for the
60 c whole integration period. Before, it accumulates the
61 c intantaneous field.
62
63 common /averages_r/
64 & tbar,
65 & sbar,
66 & psbar,
67 & ubar,
68 & vbar,
69 & wbar,
70 & tauxbar,
71 & tauybar,
72 & hfluxbar,
73 & sfluxbar,
74 & Slmean,
75 & Tlmean,
76 & wlmean,
77 & Sfmean,
78 & Tfmean,
79 & sbar_gen,
80 & tbar_gen,
81 & wfmean
82
83 #if (defined (ALLOW_THETA_COST_CONTRIBUTION) || \
84 defined (ALLOW_CTDT_COST_CONTRIBUTION) || \
85 defined (ALLOW_XBT_COST_CONTRIBUTION) || \
86 defined (ALLOW_DRIFT_COST_CONTRIBUTION) || \
87 defined (ALLOW_OBCS_COST_CONTRIBUTION))
88 _RL tbar (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
89 #else
90 #ifdef ALLOW_SST_COST_CONTRIBUTION
91 _RL tbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
92 #else
93 _RL tbar
94 #endif
95 #endif
96 #ifdef GENERIC_BAR_MONTH
97 _RL tbar_gen (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
98 _RL sbar_gen (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
99 #else
100 _RL tbar_gen
101 _RL sbar_gen
102 #endif
103
104 #if (defined (ALLOW_SALT_COST_CONTRIBUTION) || \
105 defined (ALLOW_CTDS_COST_CONTRIBUTION) || \
106 defined (ALLOW_DRIFT_COST_CONTRIBUTION) || \
107 defined (ALLOW_OBCS_COST_CONTRIBUTION))
108 _RL sbar (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
109 #else
110 #ifdef ALLOW_SSS_COST_CONTRIBUTION
111 _RL sbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
112 #else
113 _RL sbar
114 #endif
115 #endif
116
117 #ifdef ALLOW_SSH_COST_CONTRIBUTION
118 _RL psbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
119 #else
120 _RL psbar
121 #endif
122
123 #if (defined (ALLOW_DRIFTER_COST_CONTRIBUTION) || \
124 defined (ALLOW_OBCS_COST_CONTRIBUTION))
125 _RL ubar (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
126 _RL vbar (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
127 #else
128 _RL ubar
129 _RL vbar
130 #endif
131
132 #ifdef ALLOW_DRIFTW_COST_CONTRIBUTION
133 _RL wbar (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
134 #else
135 _RL wbar
136 #endif
137
138 #ifdef ALLOW_DRIFT_COST_CONTRIBUTION
139 _RL Tlmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
140 _RL Slmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
141 _RL Tfmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
142 _RL Sfmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
143 #else
144 _RL Tlmean
145 _RL Slmean
146 _RL Tfmean
147 _RL Sfmean
148 #endif
149
150 #ifdef ALLOW_DRIFTW_COST_CONTRIBUTION
151 _RL wlmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
152 _RL wfmean(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
153 #else
154 _RL wlmean
155 _RL wfmean
156 #endif
157
158 #ifdef ALLOW_SCAT_COST_CONTRIBUTION
159 _RL tauxbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
160 _RL tauybar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
161 #else
162 _RL tauxbar
163 _RL tauybar
164 #endif
165
166 #ifdef ALLOW_MEAN_HFLUX_COST_CONTRIBUTION
167 _RL hfluxbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
168 #else
169 _RL hfluxbar
170 #endif
171
172 #ifdef ALLOW_MEAN_SFLUX_COST_CONTRIBUTION
173 _RL sfluxbar (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
174 #else
175 _RL sfluxbar
176 #endif
177
178
179 common /averages_c/
180 & tbarfile,
181 & sbarfile,
182 & psbarfile,
183 & ubarfile,
184 & vbarfile,
185 & wbarfile,
186 & tauxbarfile,
187 & tauybarfile,
188 & hfluxbarfile,
189 & sfluxbarfile
190 character*(MAX_LEN_FNAM) tbarfile
191 character*(MAX_LEN_FNAM) sbarfile
192 character*(MAX_LEN_FNAM) psbarfile
193 character*(MAX_LEN_FNAM) ubarfile
194 character*(MAX_LEN_FNAM) vbarfile
195 character*(MAX_LEN_FNAM) wbarfile
196 character*(MAX_LEN_FNAM) tauxbarfile
197 character*(MAX_LEN_FNAM) tauybarfile
198 character*(MAX_LEN_FNAM) hfluxbarfile
199 character*(MAX_LEN_FNAM) sfluxbarfile
200
201 c file precision and field type
202
203 common /prec_type_cost/
204 & cost_iprec,
205 & cost_yftype
206
207 integer cost_iprec
208 character*(2) cost_yftype
209
210 c ==================================================================
211 c END OF HEADER AVERAGES
212 c ==================================================================
213
214
215
216 c ==================================================================
217 c HEADER COST
218 c ==================================================================
219 c
220 c o Header for model-data comparison.
221 c
222 c The individual cost function contributions are multiplied by
223 c factors mult_"var" which allow to switch off these contributions
224 c without removing them in the adjoint code. This is useful for
225 c doing tests with the adjoint and perhaps useful in assimilation
226 c experiments where individual contributions are successively
227 c switched on. For future applications it would be better to place
228 c the initialisation of the multipliers somewhere else, for example
229 c in a namelist, which is read in at the start of the model.
230 c
231 c started: Christian Eckert eckert@mit.edu 24-Feb-1999
232 c
233 c changed: Christian Eckert eckert@mit.edu
234 c
235 c
236 c ==================================================================
237 c HEADER COST
238 c ==================================================================
239
240
241 c The cost function, its contributions, and multipliers:
242 c ======================================================
243 c
244 c fc - Final cost function.
245 c objf_hflux - Heat flux contribution.
246 c objf_sflux - Salt flux contribution.
247 c objf_tauu - Zonal wind stress contribution.
248 c objf_tauv - Meridional wind stress contribution.
249 c objf_hfluxm - time-mean Heat flux contribution.
250 c objf_sfluxm - time-mean Salt flux contribution.
251 c objf_tauum - time-mean Zonal wind stress contribution.
252 c objf_tauvm - time-mean Meridional wind stress contribution.
253 c objf_hfluxmm - Global time-mean Heat flux contribution.
254 c objf_sfluxmm - Global time-mean Salt flux contribution.
255 c objf_hmean - Mean sea surface height contribution.
256 c objf_h - Residual sea surface height contribution.
257 c objf_temp - Temperature contribution.
258 c objf_salt - Salinity contribution.
259 c objf_temp0 - Initial conditions Temperature contribution.
260 c objf_salt0 - Initial conditions Salinity contribution.
261 c objf_sst - Sea surface temperature contribution.
262 c objf_tmi - Sea surface temperature contribution.
263 c objf_sss - Sea surface salinity contribution.
264 c objf_ctdt - Temperature measurements from Woce CTD
265 c objf_ctds - Salinity measurements from Woce CTD
266 c objf_ctdtclim - Temperature measurements from Woce CTD without timetag
267 c objf_ctdsclim - Salinity measurements from Woce CTD without timetag
268 c objf_xbt - XBT temperature data
269 c objf_argot - ARGO temperature profiles
270 c objf_argos - ARGO salt profiles
271 c objf_scatxm - time-mean zonal SCAT contribution
272 c objf_scatym - time-mean meridional SCAT contribution
273 c objf_scatx - zonal SCAT contribution
274 c objf_scaty - meridional SCAT contribution
275 c objf_kapgm - kappa GM contribution
276 c objf_diffkr - diffusion contribution
277 c objf_theta_ini_fin - final vs. initial theta misfit
278 c objf_salt_ini_fin - final vs. initial salt misfit
279 c
280 c mult_"var" - multipliers for the individual cost
281 c function contributions.
282
283 common /ecco_cost_objf/
284 & objf_hflux,
285 & objf_hfluxm,
286 & objf_hfluxmm,
287 & objf_sflux,
288 & objf_sfluxm,
289 & objf_sfluxmm,
290 & objf_tauu,
291 & objf_tauum,
292 & objf_tauv,
293 & objf_tauvm,
294 & objf_hmean,
295 & objf_h,
296 & objf_temp,
297 & objf_salt,
298 & objf_temp0,
299 & objf_salt0,
300 & objf_sst,
301 & objf_tmi,
302 & objf_sss,
303 & objf_ctdt,
304 & objf_ctds,
305 & objf_ctdtclim,
306 & objf_ctdsclim,
307 & objf_xbt,
308 & objf_argot,
309 & objf_argos,
310 & objf_drift,
311 & objf_tdrift,
312 & objf_sdrift,
313 & objf_wdrift,
314 & objf_scatx,
315 & objf_scaty,
316 & objf_scatxm,
317 & objf_scatym,
318 & objf_atemp,
319 & objf_aqh,
320 & objf_precip,
321 & objf_swflux,
322 & objf_swdown,
323 & objf_uwind,
324 & objf_vwind,
325 & objf_atempm,
326 & objf_aqhm,
327 & objf_precipm,
328 & objf_swfluxm,
329 & objf_swdownm,
330 & objf_uwindm,
331 & objf_vwindm,
332 & objf_obcsn,
333 & objf_obcss,
334 & objf_obcsw,
335 & objf_obcse,
336 & objf_obcsvol,
337 & objf_curmtr,
338 & objf_ageos,
339 & objf_kapgm,
340 & objf_diffkr,
341 & objf_theta_ini_fin,
342 & objf_salt_ini_fin,
343 & objf_eddytau
344
345 _RL objf_hflux (nsx,nsy)
346 _RL objf_hfluxm (nsx,nsy)
347 _RL objf_hfluxmm(nsx,nsy)
348 _RL objf_sflux (nsx,nsy)
349 _RL objf_sfluxm (nsx,nsy)
350 _RL objf_sfluxmm(nsx,nsy)
351 _RL objf_tauu (nsx,nsy)
352 _RL objf_tauum (nsx,nsy)
353 _RL objf_tauv (nsx,nsy)
354 _RL objf_tauvm (nsx,nsy)
355 _RL objf_hmean
356 _RL objf_h (nsx,nsy)
357 _RL objf_temp (nsx,nsy)
358 _RL objf_salt (nsx,nsy)
359 _RL objf_temp0(nsx,nsy)
360 _RL objf_salt0(nsx,nsy)
361 _RL objf_sst (nsx,nsy)
362 _RL objf_tmi (nsx,nsy)
363 _RL objf_sss (nsx,nsy)
364 _RL objf_ctdt (nsx,nsy)
365 _RL objf_ctds (nsx,nsy)
366 _RL objf_ctdtclim (nsx,nsy)
367 _RL objf_ctdsclim (nsx,nsy)
368 _RL objf_xbt (nsx,nsy)
369 _RL objf_argot(nsx,nsy)
370 _RL objf_argos(nsx,nsy)
371 _RL objf_drift(nsx,nsy)
372 _RL objf_tdrift(nsx,nsy)
373 _RL objf_sdrift(nsx,nsy)
374 _RL objf_wdrift(nsx,nsy)
375 _RL objf_scatx(nsx,nsy)
376 _RL objf_scaty(nsx,nsy)
377 _RL objf_scatxm(nsx,nsy)
378 _RL objf_scatym(nsx,nsy)
379 _RL objf_atemp(nsx,nsy)
380 _RL objf_aqh (nsx,nsy)
381 _RL objf_precip(nsx,nsy)
382 _RL objf_swflux(nsx,nsy)
383 _RL objf_swdown(nsx,nsy)
384 _RL objf_uwind(nsx,nsy)
385 _RL objf_vwind(nsx,nsy)
386 _RL objf_atempm(nsx,nsy)
387 _RL objf_aqhm (nsx,nsy)
388 _RL objf_precipm(nsx,nsy)
389 _RL objf_swfluxm(nsx,nsy)
390 _RL objf_swdownm(nsx,nsy)
391 _RL objf_uwindm(nsx,nsy)
392 _RL objf_vwindm(nsx,nsy)
393 _RL objf_obcsn(nsx,nsy)
394 _RL objf_obcss(nsx,nsy)
395 _RL objf_obcsw(nsx,nsy)
396 _RL objf_obcse(nsx,nsy)
397 _RL objf_obcsvol
398 _RL objf_curmtr(nsx,nsy)
399 _RL objf_ageos(nsx,nsy)
400 _RL objf_kapgm(nsx,nsy)
401 _RL objf_diffkr(nsx,nsy)
402 _RL objf_theta_ini_fin(nsx,nsy)
403 _RL objf_salt_ini_fin(nsx,nsy)
404 _RL objf_eddytau(nsx,nsy)
405
406 common /ecco_cost_num/
407 & num_hflux,
408 & num_hfluxm,
409 & num_hfluxmm,
410 & num_sflux,
411 & num_sfluxm,
412 & num_sfluxmm,
413 & num_tauu,
414 & num_tauum,
415 & num_tauv,
416 & num_tauvm,
417 & num_hmean,
418 & num_h,
419 & num_temp,
420 & num_salt,
421 & num_temp0,
422 & num_salt0,
423 & num_sst,
424 & num_tmi,
425 & num_sss,
426 & num_ctdt,
427 & num_ctds,
428 & num_ctdtclim,
429 & num_ctdsclim,
430 & num_xbt,
431 & num_argot,
432 & num_argos,
433 & num_drift,
434 & num_tdrift,
435 & num_sdrift,
436 & num_wdrift,
437 & num_scatx,
438 & num_scaty,
439 & num_scatxm,
440 & num_scatym,
441 & num_atemp,
442 & num_aqh,
443 & num_precip,
444 & num_swflux,
445 & num_swdown,
446 & num_uwind,
447 & num_vwind,
448 & num_atempm,
449 & num_aqhm,
450 & num_precipm,
451 & num_swfluxm,
452 & num_swdownm,
453 & num_uwindm,
454 & num_vwindm,
455 & num_obcsn,
456 & num_obcss,
457 & num_obcsw,
458 & num_obcse,
459 & num_obcsvol,
460 & num_curmtr,
461 & num_ageos,
462 & num_kapgm,
463 & num_diffkr,
464 & num_theta_ini_fin,
465 & num_salt_ini_fin,
466 & num_eddytau
467
468 _RL num_hflux (nsx,nsy)
469 _RL num_hfluxm (nsx,nsy)
470 _RL num_hfluxmm(nsx,nsy)
471 _RL num_sflux (nsx,nsy)
472 _RL num_sfluxm (nsx,nsy)
473 _RL num_sfluxmm(nsx,nsy)
474 _RL num_tauu (nsx,nsy)
475 _RL num_tauum (nsx,nsy)
476 _RL num_tauv (nsx,nsy)
477 _RL num_tauvm (nsx,nsy)
478 _RL num_hmean
479 _RL num_h (nsx,nsy)
480 _RL num_temp (nsx,nsy)
481 _RL num_salt (nsx,nsy)
482 _RL num_temp0(nsx,nsy)
483 _RL num_salt0(nsx,nsy)
484 _RL num_sst (nsx,nsy)
485 _RL num_tmi (nsx,nsy)
486 _RL num_sss (nsx,nsy)
487 _RL num_ctdt (nsx,nsy)
488 _RL num_ctds (nsx,nsy)
489 _RL num_ctdtclim (nsx,nsy)
490 _RL num_ctdsclim (nsx,nsy)
491 _RL num_xbt (nsx,nsy)
492 _RL num_argot(nsx,nsy)
493 _RL num_argos(nsx,nsy)
494 _RL num_drift(nsx,nsy)
495 _RL num_tdrift(nsx,nsy)
496 _RL num_sdrift(nsx,nsy)
497 _RL num_wdrift(nsx,nsy)
498 _RL num_scatx(nsx,nsy)
499 _RL num_scaty(nsx,nsy)
500 _RL num_scatxm(nsx,nsy)
501 _RL num_scatym(nsx,nsy)
502 _RL num_atemp(nsx,nsy)
503 _RL num_aqh (nsx,nsy)
504 _RL num_precip(nsx,nsy)
505 _RL num_swflux(nsx,nsy)
506 _RL num_swdown(nsx,nsy)
507 _RL num_uwind(nsx,nsy)
508 _RL num_vwind(nsx,nsy)
509 _RL num_atempm(nsx,nsy)
510 _RL num_aqhm (nsx,nsy)
511 _RL num_precipm(nsx,nsy)
512 _RL num_swfluxm(nsx,nsy)
513 _RL num_swdownm(nsx,nsy)
514 _RL num_uwindm(nsx,nsy)
515 _RL num_vwindm(nsx,nsy)
516 _RL num_obcsn(nsx,nsy)
517 _RL num_obcss(nsx,nsy)
518 _RL num_obcsw(nsx,nsy)
519 _RL num_obcse(nsx,nsy)
520 _RL num_obcsvol
521 _RL num_curmtr(nsx,nsy)
522 _RL num_ageos(nsx,nsy)
523 _RL num_kapgm(nsx,nsy)
524 _RL num_diffkr(nsx,nsy)
525 _RL num_theta_ini_fin(nsx,nsy)
526 _RL num_salt_ini_fin(nsx,nsy)
527 _RL num_eddytau(nsx,nsy)
528
529 common /ecco_cost_aux_r/
530 & mult_hflux,
531 & mult_sflux,
532 & mult_tauu,
533 & mult_tauv,
534 & mult_hmean,
535 & mult_h,
536 & mult_temp,
537 & mult_salt,
538 & mult_temp0,
539 & mult_salt0,
540 & mult_sst,
541 & mult_tmi,
542 & mult_sss,
543 & mult_ctdt,
544 & mult_ctds,
545 & mult_ctdtclim,
546 & mult_ctdsclim,
547 & mult_xbt,
548 & mult_argot,
549 & mult_argos,
550 & mult_drift,
551 & mult_tdrift,
552 & mult_sdrift,
553 & mult_wdrift,
554 & mult_scatx,
555 & mult_scaty,
556 & mult_atemp,
557 & mult_aqh,
558 & mult_precip,
559 & mult_swflux,
560 & mult_swdown,
561 & mult_uwind,
562 & mult_vwind,
563 & mult_obcsn,
564 & mult_obcss,
565 & mult_obcsw,
566 & mult_obcse,
567 & mult_obcsvol,
568 & mult_curmtr,
569 & mult_ageos,
570 & mult_kapgm,
571 & mult_diffkr,
572 & mult_ini_fin,
573 & mult_eddytau
574
575 _RL mult_hflux
576 _RL mult_sflux
577 _RL mult_tauu
578 _RL mult_tauv
579 _RL mult_hmean
580 _RL mult_h
581 _RL mult_temp
582 _RL mult_salt
583 _RL mult_temp0
584 _RL mult_salt0
585 _RL mult_sst
586 _RL mult_tmi
587 _RL mult_sss
588 _RL mult_ctdt
589 _RL mult_ctds
590 _RL mult_ctdtclim
591 _RL mult_ctdsclim
592 _RL mult_xbt
593 _RL mult_argot
594 _RL mult_argos
595 _RL mult_drift
596 _RL mult_tdrift
597 _RL mult_sdrift
598 _RL mult_wdrift
599 _RL mult_scatx
600 _RL mult_scaty
601 _RL mult_atemp
602 _RL mult_aqh
603 _RL mult_precip
604 _RL mult_swflux
605 _RL mult_swdown
606 _RL mult_uwind
607 _RL mult_vwind
608 _RL mult_obcsn
609 _RL mult_obcss
610 _RL mult_obcsw
611 _RL mult_obcse
612 _RL mult_obcsvol
613 _RL mult_curmtr
614 _RL mult_ageos
615 _RL mult_kapgm
616 _RL mult_diffkr
617 _RL mult_ini_fin
618 _RL mult_eddytau
619
620 c Record counters relevant for the cost function evaluation.
621 c ==========================================================
622 c
623 c nmonsrec - number of monthly records that will be generated by
624 c the current model integration.
625 c ndaysrec - number of daily records that will be generated by
626 c the current model integration.
627
628 common /ecco_cost_i/
629 & nmonsrec,
630 & ndaysrec,
631 & nnztbar,
632 & nnzsbar
633 integer nmonsrec
634 integer ndaysrec
635 integer nnztbar
636 integer nnzsbar
637
638
639 c Data files for the weights used in the cost function:
640 c =====================================================
641 c
642 c hflux_errfile - heat flux error.
643 c sflux_errfile - salt flux error.
644 c tauu_errfile - zonal wind stress error.
645 c tauum_errfile - zonal wind stress error.
646 c tauv_errfile - meridional wind stress error.
647 c tauvm_errfile - meridional wind stress error.
648 c tscatx_errfile - zonal wind stress error.
649 c tscaty_errfile - meridional wind stress error.
650 c data_errfile - weights for theta, salt, and SST
651 c geoid_errfile - geoid error.
652 c geoid_covariancefile - geoid error covariance.
653 c ssh_errfile - sea surface height error.
654 c ctdt_errfile - CTD temperature error.
655 c ctds_errfile - CTD salinity error.
656 c drift_errfile - drifter error.
657 c salterrfile - representation error due unresolved eddies
658 c temperrfile - representation error due unresolved eddies
659 c velerrfile - representation error
660
661 common /ecco_cost_c/
662 & hflux_errfile,
663 & hfluxm_errfile,
664 & sflux_errfile,
665 & sfluxm_errfile,
666 & tauu_errfile,
667 & tauum_errfile,
668 & tauv_errfile,
669 & tauvm_errfile,
670 & scatx_errfile,
671 & scaty_errfile,
672 & data_errfile,
673 & geoid_errfile,
674 & geoid_covariancefile,
675 & ssh_errfile,
676 & ctdt_errfile,
677 & ctds_errfile,
678 & drift_errfile,
679 & udrifterrfile,
680 & vdrifterrfile,
681 & salterrfile,
682 & temperrfile,
683 & velerrfile,
684 & atemp_errfile,
685 & aqh_errfile,
686 & precip_errfile,
687 & swflux_errfile,
688 & swdown_errfile,
689 & uwind_errfile,
690 & vwind_errfile
691 character*(MAX_LEN_FNAM) hflux_errfile
692 character*(MAX_LEN_FNAM) sflux_errfile
693 character*(MAX_LEN_FNAM) tauu_errfile
694 character*(MAX_LEN_FNAM) tauv_errfile
695 character*(MAX_LEN_FNAM) hfluxm_errfile
696 character*(MAX_LEN_FNAM) sfluxm_errfile
697 character*(MAX_LEN_FNAM) tauum_errfile
698 character*(MAX_LEN_FNAM) tauvm_errfile
699 character*(MAX_LEN_FNAM) scatx_errfile
700 character*(MAX_LEN_FNAM) scaty_errfile
701 character*(MAX_LEN_FNAM) data_errfile
702 character*(MAX_LEN_FNAM) geoid_errfile
703 character*(MAX_LEN_FNAM) geoid_covariancefile
704 character*(MAX_LEN_FNAM) ssh_errfile
705 character*(MAX_LEN_FNAM) ctdt_errfile
706 character*(MAX_LEN_FNAM) ctds_errfile
707 character*(MAX_LEN_FNAM) drift_errfile
708 character*(MAX_LEN_FNAM) udrifterrfile
709 character*(MAX_LEN_FNAM) vdrifterrfile
710 character*(MAX_LEN_FNAM) salterrfile
711 character*(MAX_LEN_FNAM) temperrfile
712 character*(MAX_LEN_FNAM) velerrfile
713 character*(MAX_LEN_FNAM) atemp_errfile
714 character*(MAX_LEN_FNAM) aqh_errfile
715 character*(MAX_LEN_FNAM) precip_errfile
716 character*(MAX_LEN_FNAM) swflux_errfile
717 character*(MAX_LEN_FNAM) swdown_errfile
718 character*(MAX_LEN_FNAM) uwind_errfile
719 character*(MAX_LEN_FNAM) vwind_errfile
720
721
722 c Arrays where the weights are stored:
723 c ====================================
724 c
725 c cosphi - cosine of latitude.
726 c whflux - weight for heat flux.
727 c wsflux - weight for salt flux.
728 c wtauu - weight for zonal wind stress.
729 c wtauu - weight for meridional wind stress.
730 c wscatx - weight for zonal scat stress.
731 c wscaty - weight for meridional scat stress.
732 c wtheta - weight for temperature.
733 c wtheta2 - representation error due to unresolved eddies
734 c wsst - weight for sea surface temperature.
735 c wsss - weight for sea surface salinity.
736 c wsalt - weight for salinity.
737 c wsalt2 - representation error due to unresolved eddies
738 c wtp - weight for TOPEX/POSEIDON data.
739 c wers - weight for ERS data.
740 c wp - weight for geoid.
741 c wctdt - weight for CTD temperature.
742 c wctds - weight for CTD salinity.
743 c wudrift - weight for mean zonal velocity from drifters.
744 c wvdrift - weight for mean meridional velocity from drifters.
745
746 common /ecco_cost_weights_r/
747 & frame,
748 & cosphi,
749 & whflux,wsflux,wtauu,wtauv,
750 & watemp,waqh,wprecip,wswflux,wswdown,
751 & wuwind,wvwind,
752 & wscatx,wscaty,
753 & wtheta,wtheta2,wthetaLev,
754 & wsalt,wsalt2,wsaltLev,
755 & wsst,wsss,
756 & wtp,wers,
757 & wp,
758 & wctdt,wctds,
759 & wudrift,wvdrift,
760 & whfluxmm,wsfluxmm,
761 & wcurrent,wcurrent2,
762 & wcurrentLev,wbaro
763
764 _RL frame (1-olx:snx+olx,1-oly:sny+oly )
765 _RL cosphi (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
766 _RL whflux (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
767 _RL whfluxm (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
768 _RL whfluxmm(1-olx:snx+olx,1-oly:sny+oly)
769 _RL wsflux (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
770 _RL wsfluxm (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
771 _RL wsfluxmm(1-olx:snx+olx,1-oly:sny+oly)
772 _RL wtauu (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
773 _RL wtauv (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
774 _RL wtauum (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
775 _RL wtauvm (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
776 _RL wscatx (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
777 _RL wscaty (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
778 _RL watemp (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
779 _RL waqh (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
780 _RL wprecip (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
781 _RL wswflux (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
782 _RL wswdown (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
783 _RL wuwind (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
784 _RL wvwind (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
785 _RL wtheta ( nr,nsx,nsy)
786 _RL wsalt ( nr,nsx,nsy)
787 _RL wtheta2 (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
788 _RL wsalt2 (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
789 _RL wthetaLev (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
790 _RL wsaltLev (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
791 _RL wsst (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
792 _RL wsss (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
793 _RL wtp (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
794 _RL wers (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
795 _RL wp (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
796 _RL wctdt ( nr,nsx,nsy)
797 _RL wctds ( nr,nsx,nsy)
798 _RL wudrift (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
799 _RL wvdrift (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
800 _RL wcurrent( nr,nsx,nsy)
801 _RL wcurrent2 (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
802 _RL wcurrentLev (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
803 _RL wbaro
804
805 common /ecco_cost_weights_0_r/
806 & whflux0, wsflux0, wtau0,
807 & watemp0, waqh0, wprecip0, wswflux0, wswdown0, wwind0
808 _RL whflux0
809 _RL wsflux0
810 _RL wtau0
811 _RL watemp0
812 _RL waqh0
813 _RL wprecip0
814 _RL wswflux0
815 _RL wswdown0
816 _RL wwind0
817
818 common /ecco_cost_weights_mean_r/
819 & wmean_hflux, wmean_sflux, wmean_tau,
820 & wmean_atemp, wmean_aqh,
821 & wmean_precip, wmean_swflux, wmean_swdown, wmean_wind
822 _RL wmean_hflux
823 _RL wmean_sflux
824 _RL wmean_tau
825 _RL wmean_atemp
826 _RL wmean_aqh
827 _RL wmean_precip
828 _RL wmean_swflux
829 _RL wmean_swdown
830 _RL wmean_wind
831
832 common /ecco_cost_weights_2_r/
833 & whflux2,wsflux2,wtauu2,wtauv2
834 _RL whflux2 (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
835 _RL wsflux2 (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
836 _RL wtauu2 (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
837 _RL wtauv2 (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
838
839
840
841 #if (defined (ALLOW_OBCSN_COST_CONTRIBUTION) || \
842 defined (ALLOW_OBCSN_CONTROL))
843 common /ecco_cost_weights_obcsn/
844 & wobcsn, wobcsnLev
845 _RL wobcsn ( nr,nobcs)
846 _RL wobcsnLev (1-olx:snx+olx,nr,nsx,nsy,nobcs)
847 #endif
848 #if (defined (ALLOW_OBCSS_COST_CONTRIBUTION) || \
849 defined (ALLOW_OBCSS_CONTROL))
850 common /ecco_cost_weights_obcss/
851 & wobcss, wobcssLev
852 _RL wobcss ( nr,nobcs)
853 _RL wobcssLev (1-olx:snx+olx,nr,nsx,nsy,nobcs)
854 #endif
855 #if (defined (ALLOW_OBCSW_COST_CONTRIBUTION) || \
856 defined (ALLOW_OBCSW_CONTROL))
857 common /ecco_cost_weights_obcsw/
858 & wobcsw, wobcswLev
859 _RL wobcsw ( nr,nobcs)
860 _RL wobcswLev (1-oly:sny+oly,nr,nsx,nsy,nobcs)
861 #endif
862 #if (defined (ALLOW_OBCSE_COST_CONTRIBUTION) || \
863 defined (ALLOW_OBCSE_CONTROL))
864 common /ecco_cost_weights_obcse/
865 & wobcse, wobcseLev
866 _RL wobcse ( nr,nobcs)
867 _RL wobcseLev (1-oly:sny+oly,nr,nsx,nsy,nobcs)
868 #endif
869
870
871 c Arrays that contain observations for the model-data comparison:
872 c ===============================================================
873 c
874 c tdat - reference temperature data.
875 c scatxdat - reference zonal wind stress.
876 c scatydat - reference meridional wind stress.
877 c sstdat - reference sea surface temperature data.
878 c tmidat - reference TMI sea surface temperature data.
879 c sssdat - reference sea surface temperature data.
880 c tauxmask - mask for reference wind stress data.
881 c tauymask - mask for reference wind stress data.
882 c scatxmask - mask for scat wind stress data.
883 c scatymask - mask for scat wind stress data.
884 c sstmask - mask for reference sea surface temperature data.
885 c tmimask - mask for reference sea surface temperature data.
886 c sssmask - mask for reference sea surface temperature data.
887 c sdat - reference salinity data.
888 c tpmean - reference mean sea surface height data.
889 c tpmeanmask - mask for reference mean sea surface height data.
890 c tpobs - TOPEX/POSEIDON data.
891 c tpmask - mask for TOPEX/POSEIDON data.
892 c ersobs - ERS data.
893 c ersmask - mask for ERS data.
894 c ctdtobs - CTD temperature data
895 c ctdsobs - CTD salinity data
896 c xbtobs - XBT data
897 c argot - ARGO temperature data
898 c argos - ARGO salt data
899 c udriftdat - drifters zonal velocities
900 c vdriftdat - drifters meridional velocities
901
902 common /ecco_cost_data_r/
903 & tdat,
904 & scatxdat,
905 & scatydat,
906 & sstdat,
907 & tmidat,
908 & sssdat,
909 & sstmask,
910 & tmimask,
911 & sssmask,
912 & tauxmask,
913 & tauymask,
914 & scatxmask,
915 & scatymask,
916 & sdat,
917 & tpmean,
918 & tpmeanmask,
919 & tpobs,
920 & tpmask,
921 & ersobs,
922 & ersmask,
923 & ctdtobs,
924 & ctdsobs,
925 & xbtobs,
926 & argotobs,
927 & argosobs,
928 & udriftdat,
929 & vdriftdat,
930 & curmtruobs,
931 & curmtrvobs
932
933 _RL tdat (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
934 _RL scatxdat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
935 _RL scatydat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
936 _RL sstdat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
937 _RL tmidat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
938 _RL sssdat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
939 _RL tauxmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
940 _RL tauymask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
941 _RL scatxmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
942 _RL scatymask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
943 _RL sstmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
944 _RL tmimask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
945 _RL sssmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
946 _RL sdat (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
947 _RL tpmean (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
948 _RL tpmeanmask(1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
949 _RL tpobs (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
950 _RL tpmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
951 _RL ersobs (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
952 _RL ersmask (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
953 _RL ctdtobs (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
954 _RL ctdsobs (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
955 _RL xbtobs (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
956 _RL argotobs (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
957 _RL argosobs (1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
958 _RL udriftdat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
959 _RL vdriftdat (1-olx:snx+olx,1-oly:sny+oly, nsx,nsy)
960 _RL curmtruobs(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
961 _RL curmtrvobs(1-olx:snx+olx,1-oly:sny+oly,nr,nsx,nsy)
962
963
964 c Files that contain obervations:
965 c ===============================
966 c
967 c tdatfile - reference data file for temperature.
968 c sdatfile - reference data file for salinity.
969 c scatxdatfile - reference data file for zonal wind stress.
970 c scatydatfile - reference data file for meridional wind stress.
971 c sstdatfile - reference data file for sea surface temperature.
972 c tmidatfile - reference data file for TMI sea surface temperature.
973 c topexmeanfile - reference data file for mean sea surface height.
974 c topexfile - reference data file for sea surface height data
975 c (TOPEX/POSEIDON).
976 c ersfile - reference data file for sea surface height data
977 c (ERS).
978 c ctdtfile, ctdsfile- reference data file for temperature and salinity
979 c from CTD
980 c ctdtclimfile, ctdsclimfile- reference data file for temperature
981 c and salinity from CTD with out timetag
982 c xbtfile - reference data file for xbt
983 c ARGOtfile - reference data file for ARGO
984 c ARGOsfile - reference data file for ARGO
985 c driftfile - reference data file for drifter's mean velocities
986
987 common /ecco_cost_data_c/
988 & tdatfile,
989 & sdatfile,
990 & scatxdatfile,
991 & scatydatfile,
992 & sstdatfile,
993 & tmidatfile,
994 & sssdatfile,
995 & topexmeanfile,
996 & topexfile,
997 & ersfile,
998 & ctdtfile,
999 & ctdsfile,
1000 & ctdtclimfile,
1001 & ctdsclimfile,
1002 & xbtfile,
1003 & argotfile,
1004 & argosfile,
1005 & udriftfile,
1006 & vdriftfile,
1007 & curmtrufile,
1008 & curmtrvfile
1009
1010 character*(MAX_LEN_FNAM) tdatfile
1011 character*(MAX_LEN_FNAM) sdatfile
1012 character*(MAX_LEN_FNAM) scatxdatfile
1013 character*(MAX_LEN_FNAM) scatydatfile
1014 character*(MAX_LEN_FNAM) sstdatfile
1015 character*(MAX_LEN_FNAM) tmidatfile
1016 character*(MAX_LEN_FNAM) sssdatfile
1017 character*(MAX_LEN_FNAM) topexmeanfile
1018 character*(MAX_LEN_FNAM) topexfile
1019 character*(MAX_LEN_FNAM) ersfile
1020 character*(MAX_LEN_FNAM) ctdtfile
1021 character*(MAX_LEN_FNAM) ctdsfile
1022 character*(MAX_LEN_FNAM) ctdtclimfile
1023 character*(MAX_LEN_FNAM) ctdsclimfile
1024 character*(MAX_LEN_FNAM) xbtfile
1025 character*(MAX_LEN_FNAM) argotfile
1026 character*(MAX_LEN_FNAM) argosfile
1027 character*(MAX_LEN_FNAM) argofile
1028 character*(MAX_LEN_FNAM) udriftfile
1029 character*(MAX_LEN_FNAM) vdriftfile
1030 character*(MAX_LEN_FNAM) curmtrufile
1031 character*(MAX_LEN_FNAM) curmtrvfile
1032
1033
1034 c Flags used in the model-data comparison:
1035 c ========================================
1036 c
1037 c using_ers - flag that indicates the use of ERS data
1038
1039 common /ecco_cost_data_flags/
1040 & using_topex,
1041 & using_ers
1042 logical using_topex
1043 logical using_ers
1044
1045 c Calendar information for the observations:
1046 c ==========================================
1047 c
1048 c sststartdate - start date of the sea surface temperature data.
1049 c tmistartdate - start date of the sea surface temperature data.
1050 c topexstartdate - start date of the sea surface height data.
1051 c ersstartdate - start date of the sea surface height data.
1052 c sshperiod - sampling interval for the sea surface height data.
1053
1054 common /ecco_cost_data_times_i/
1055 & scatxstartdate,
1056 & scatystartdate,
1057 & sststartdate,
1058 & argotstartdate,
1059 & argosstartdate,
1060 & tmistartdate,
1061 & sssstartdate,
1062 & topexstartdate,
1063 & ersstartdate
1064 integer scatxstartdate(4)
1065 integer scatystartdate(4)
1066 integer sststartdate(4)
1067 integer argotstartdate(4)
1068 integer argosstartdate(4)
1069 integer tmistartdate(4)
1070 integer sssstartdate(4)
1071 integer topexstartdate(4)
1072 integer ersstartdate(4)
1073
1074 common /ecco_cost_data_aux_i/
1075 & tmistartdate1,
1076 & tmistartdate2,
1077 & sststartdate1,
1078 & sststartdate2,
1079 & sssstartdate1,
1080 & sssstartdate2,
1081 & argotstartdate1,
1082 & argotstartdate2,
1083 & argosstartdate1,
1084 & argosstartdate2,
1085 & topexstartdate1,
1086 & topexstartdate2,
1087 & ersstartdate1,
1088 & ersstartdate2,
1089 & scatstartdate1,
1090 & scatstartdate2
1091
1092 integer tmistartdate1
1093 integer tmistartdate2
1094 integer sststartdate1
1095 integer sststartdate2
1096 integer sssstartdate1
1097 integer sssstartdate2
1098 integer argotstartdate1
1099 integer argotstartdate2
1100 integer argosstartdate1
1101 integer argosstartdate2
1102 integer topexstartdate1
1103 integer topexstartdate2
1104 integer ersstartdate1
1105 integer ersstartdate2
1106 integer scatstartdate1
1107 integer scatstartdate2
1108
1109 common /ecco_cost_data_times_r/
1110 & topexperiod,
1111 & ersperiod,
1112 & scatperiod
1113 _RL topexperiod
1114 _RL ersperiod
1115 _RL scatperiod
1116
1117 c ==================================================================
1118 c END OF HEADER COST
1119 c ==================================================================
1120
1121

  ViewVC Help
Powered by ViewVC 1.1.22