/[MITgcm]/MITgcm/pkg/ecco/cost_hyd.F
ViewVC logotype

Contents of /MITgcm/pkg/ecco/cost_hyd.F

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


Revision 1.4 - (show annotations) (download)
Wed Aug 31 19:00:52 2005 UTC (18 years, 9 months ago) by heimbach
Branch: MAIN
Changes since 1.3: +62 -11 lines
New routine cost_generic.F should facilitate intro.
of new cost terms and replace individual routines.

1 C $Header: /u/gcmpack/MITgcm/pkg/ecco/cost_hyd.F,v 1.3 2005/04/29 10:31:56 heimbach Exp $
2
3 #include "COST_CPPOPTIONS.h"
4
5
6 subroutine cost_hyd( myiter, mytime, mythid )
7
8 c ==================================================================
9 c SUBROUTINE cost_hyd
10 c ==================================================================
11 c
12 c o Evaluate cost function contributions of temperature, salt, and
13 c sea surface temperature contributions.
14 c
15 c started: Christian Eckert eckert@mit.edu 30-Jun-1999
16 c
17 c changed: Christian Eckert eckert@mit.edu 25-Feb-2000
18 c
19 c - Restructured the code in order to create a package
20 c for the MITgcmUV.
21 c
22 c ==================================================================
23 c SUBROUTINE cost_hyd
24 c ==================================================================
25
26 implicit none
27
28 c == global variables ==
29 #include "EEPARAMS.h"
30 #include "SIZE.h"
31 #include "PARAMS.h"
32 #include "GRID.h"
33
34 #include "cal.h"
35 #include "ctrl.h"
36 #include "ctrl_dummy.h"
37 #include "ecco_cost.h"
38
39 c == routine arguments ==
40
41 integer myiter
42 _RL mytime
43 integer mythid
44
45 c == local variables ==
46 character*(max_len_mbuf) msgbuf
47
48 integer nnzbar
49 integer nnzobs
50 _RL spminloc
51 _RL spmaxloc
52 _RL spzeroloc
53 _RL localperiod
54
55 c == end of interface ==
56
57
58 #ifdef ALLOW_SST_COST_CONTRIBUTION
59 write(msgbuf,'(a)') 'ph-cost call cost_sst'
60 call print_message( msgbuf, standardmessageunit,
61 & SQUEEZE_RIGHT , mythid)
62 nnzbar = nr
63 nnzobs = 1
64 spminloc = -1.8
65 spmaxloc = 40.
66 spzeroloc = 0.
67 localperiod = 0.
68 call cost_generic(
69 & nnzbar, tbarfile, tbar, xx_tbar_mean_dummy,
70 & nnzobs, sstdatfile, sstdat,
71 & nmonsrec, modelstartdate, localperiod,
72 & maskC, wsst,
73 & spminloc, spmaxloc, spzeroloc,
74 & objf_sst, num_sst,
75 & myiter, mytime, mythid )
76 cph call cost_sst ( myiter, mytime, mythid )
77 #endif
78
79 #ifdef ALLOW_ARGO_THETA_COST_CONTRIBUTION
80 write(msgbuf,'(a)') 'ph-cost call cost_argo_theta'
81 call print_message( msgbuf, standardmessageunit,
82 & SQUEEZE_RIGHT , mythid)
83 call cost_argo_theta ( myiter, mytime, mythid )
84 #endif
85
86 #ifdef ALLOW_CTDT_COST_CONTRIBUTION
87 write(msgbuf,'(a)') 'ph-cost call cost_ctdt'
88 call print_message( msgbuf, standardmessageunit,
89 & SQUEEZE_RIGHT , mythid)
90 call cost_ctdt ( myiter, mytime, mythid )
91 #endif
92
93 #ifdef ALLOW_XBT_COST_CONTRIBUTION
94 write(msgbuf,'(a)') 'ph-cost call cost_xbt'
95 call print_message( msgbuf, standardmessageunit,
96 & SQUEEZE_RIGHT , mythid)
97 call cost_xbt ( myiter, mytime, mythid )
98 #endif
99
100 #ifdef ALLOW_TMI_SST_COST_CONTRIBUTION
101 write(msgbuf,'(a)') 'ph-cost call cost_tmi'
102 call print_message( msgbuf, standardmessageunit,
103 & SQUEEZE_RIGHT , mythid)
104 nnzbar = nr
105 nnzobs = 1
106 spminloc = -1.8
107 spmaxloc = 40.
108 spzeroloc = 0.
109 localperiod = 0.
110 call cost_generic(
111 & nnzbar, tbarfile, tbar, xx_tbar_mean_dummy,
112 & nnzobs, sstdatfile, sstdat,
113 & nmonsrec, modelstartdate, localperiod,
114 & maskC, wsst,
115 & spminloc, spmaxloc, spzeroloc,
116 & objf_tmi, num_tmi,
117 & myiter, mytime, mythid )
118 cph call cost_tmi( myiter, mytime, mythid )
119 #endif
120
121 #ifdef ALLOW_SSS_COST_CONTRIBUTION
122 write(msgbuf,'(a)') 'ph-cost call cost_sss'
123 call print_message( msgbuf, standardmessageunit,
124 & SQUEEZE_RIGHT , mythid)
125 nnzbar = nr
126 nnzobs = 1
127 spminloc = 20.
128 spmaxloc = 40.
129 spzeroloc = 0.
130 localperiod = 0.
131 call cost_generic(
132 & nnzbar, sbarfile, sbar, xx_sbar_mean_dummy,
133 & nnzobs, sssdatfile, sssdat,
134 & nmonsrec, modelstartdate, localperiod,
135 & maskC, wsss,
136 & spminloc, spmaxloc, spzeroloc,
137 & objf_sss, num_sss,
138 & myiter, mytime, mythid )
139 cph call cost_sss ( myiter, mytime, mythid )
140 #endif
141
142 #ifdef ALLOW_CTDS_COST_CONTRIBUTION
143 write(msgbuf,'(a)') 'ph-cost call cost_ctds'
144 call print_message( msgbuf, standardmessageunit,
145 & SQUEEZE_RIGHT , mythid)
146 call cost_ctds ( myiter, mytime, mythid )
147 #endif
148
149 #ifdef ALLOW_ARGO_SALT_COST_CONTRIBUTION
150 write(msgbuf,'(a)') 'ph-cost call cost_argo_salt'
151 call print_message( msgbuf, standardmessageunit,
152 & SQUEEZE_RIGHT , mythid)
153 call cost_argo_salt ( myiter, mytime, mythid )
154 #endif
155
156 #ifdef ALLOW_THETA0_COST_CONTRIBUTION
157 write(msgbuf,'(a)') 'ph-cost call cost_theta0'
158 call print_message( msgbuf, standardmessageunit,
159 & SQUEEZE_RIGHT , mythid)
160 call cost_theta0 ( myiter, mytime, mythid )
161 #endif
162
163 #ifdef ALLOW_SALT0_COST_CONTRIBUTION
164 write(msgbuf,'(a)') 'ph-cost call cost_salt0'
165 call print_message( msgbuf, standardmessageunit,
166 & SQUEEZE_RIGHT , mythid)
167 call cost_salt0 ( myiter, mytime, mythid )
168 #endif
169
170 #ifdef ALLOW_THETA_COST_CONTRIBUTION
171 write(msgbuf,'(a)') 'ph-cost call cost_theta'
172 call print_message( msgbuf, standardmessageunit,
173 & SQUEEZE_RIGHT , mythid)
174 call cost_theta ( myiter, mytime, mythid )
175 #endif
176
177 #ifdef ALLOW_SALT_COST_CONTRIBUTION
178 write(msgbuf,'(a)') 'ph-cost call cost_salt'
179 call print_message( msgbuf, standardmessageunit,
180 & SQUEEZE_RIGHT , mythid)
181 call cost_salt ( myiter, mytime, mythid )
182 #endif
183
184 end

  ViewVC Help
Powered by ViewVC 1.1.22