/[MITgcm]/MITgcm/pkg/obcs/obcs_prescribe_read.F
ViewVC logotype

Annotation of /MITgcm/pkg/obcs/obcs_prescribe_read.F

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


Revision 1.9 - (hide annotations) (download)
Wed Mar 22 19:21:58 2006 UTC (18 years, 2 months ago) by mlosch
Branch: MAIN
CVS Tags: checkpoint58l_post, checkpoint58e_post, checkpoint58u_post, checkpoint58w_post, checkpoint58r_post, checkpoint58n_post, checkpoint58x_post, checkpoint58t_post, checkpoint58h_post, checkpoint58q_post, checkpoint58j_post, checkpoint58f_post, checkpoint58d_post, checkpoint58c_post, checkpoint58i_post, checkpoint58g_post, checkpoint58o_post, checkpoint58y_post, checkpoint58k_post, checkpoint58v_post, checkpoint58s_post, checkpoint58p_post, checkpoint58m_post
Changes since 1.8: +2 -1 lines
bug fix: needs an #include "PARAMS.h" in the (unlikely (o: ) event of
ALLOW_EXF and ALLOW_PTRACERS and ALLOW_OBCS defined (this unlikely
event just occured)

1 mlosch 1.9 C $Header: /u/gcmpack/MITgcm/pkg/obcs/obcs_prescribe_read.F,v 1.8 2005/12/15 00:48:16 jmc Exp $
2 heimbach 1.1 C $Name: $
3    
4     # include "OBCS_OPTIONS.h"
5    
6     subroutine obcs_prescribe_read (
7     I mycurrenttime
8     I , mycurrentiter
9     I , mythid
10     & )
11     c |==================================================================|
12     c | SUBROUTINE obcs_prescribe_read |
13     c |==================================================================|
14     c | read open boundary conditions from file |
15     c | N.B.: * uses exf and cal routines for file/record handling |
16     c | * uses ctrl routines for control variable handling |
17     c |==================================================================|
18    
19     implicit none
20    
21     c == global variables ==
22    
23     #include "EEPARAMS.h"
24     #include "SIZE.h"
25     #include "GRID.h"
26     #include "OBCS.h"
27     #ifdef ALLOW_EXF
28     # include "exf_param.h"
29     #endif
30 mlosch 1.7 #ifdef ALLOW_PTRACERS.h
31 mlosch 1.9 # include "PARAMS.h"
32 mlosch 1.7 # include "PTRACERS_SIZE.h"
33     # include "PTRACERS.h"
34     # include "OBCS_PTRACERS.h"
35     #endif /* ALLOW_PTRACERS */
36 heimbach 1.1
37     c == routine arguments ==
38    
39     _RL mycurrenttime
40     integer mycurrentiter
41     integer mythid
42    
43     #if (defined (ALLOW_OBCS) && defined (ALLOW_OBCS_PRESCRIBE))
44    
45     c == local variables ==
46    
47 jmc 1.8 #ifdef ALLOW_EXF
48 heimbach 1.1 logical first, changed
49     integer count0, count1
50 heimbach 1.5 integer year0, year1
51 heimbach 1.1 _RL fac
52 mlosch 1.7 #ifdef ALLOW_PTRACERS
53     integer iTracer, i,j,k
54     #endif /* ALLOW_PTRACERS */
55 jmc 1.8 #endif /* ALLOW_EXF */
56 heimbach 1.1
57     c == end of interface ==
58    
59 mlosch 1.2 #ifdef ALLOW_EXF
60 heimbach 1.1 #ifdef ALLOW_OBCS_NORTH
61     call exf_getffieldrec(
62     I obcsNstartdate, obcsNperiod
63 heimbach 1.3 I , obcsNstartdate1, obcsNstartdate2
64 heimbach 1.4 I , .false.
65 adcroft 1.6 O , fac, first, changed
66 heimbach 1.3 O , count0, count1, year0, year1
67 heimbach 1.1 I , mycurrenttime, mycurrentiter, mythid
68     & )
69    
70     call exf_set_obcs_xz( OBNu, OBNu0, OBNu1, OBNufile, 'u'
71     I , fac, first, changed, count0, count1
72     I , mycurrenttime, mycurrentiter, mythid )
73     call exf_set_obcs_xz( OBNv, OBNv0, OBNv1, OBNvfile, 'v'
74     I , fac, first, changed, count0, count1
75     I , mycurrenttime, mycurrentiter, mythid )
76     call exf_set_obcs_xz( OBNt, OBNt0, OBNt1, OBNtfile, 's'
77     I , fac, first, changed, count0, count1
78     I , mycurrenttime, mycurrentiter, mythid )
79     call exf_set_obcs_xz( OBNs, OBNs0, OBNs1, OBNsfile, 's'
80     I , fac, first, changed, count0, count1
81     I , mycurrenttime, mycurrentiter, mythid )
82 mlosch 1.7 #ifdef ALLOW_PTRACERS
83     if ( usePTRACERS ) then
84     do itracer = 1, PTRACERS_numInUse
85     call exf_set_obcs_xz( OBNptr (1-Olx,1,1,1,iTracer)
86     I , OBNptr0(1-Olx,1,1,1,iTracer)
87     I , OBNptr1(1-Olx,1,1,1,iTracer)
88     I , OBNptrFile(iTracer), 's'
89     I , fac, first, changed, count0, count1
90     I , mycurrenttime, mycurrentiter, mythid )
91     enddo
92     endif
93     #endif /* ALLOW_PTRACERS */
94 heimbach 1.1 #endif
95    
96     #ifdef ALLOW_OBCS_SOUTH
97     call exf_getffieldrec(
98     I obcsSstartdate, obcsSperiod
99 heimbach 1.3 I , obcsSstartdate1, obcsSstartdate2
100 heimbach 1.4 I , .false.
101     O , fac, first, changed
102     O , count0, count1, year0, year1
103 heimbach 1.1 I , mycurrenttime, mycurrentiter, mythid
104     & )
105    
106     call exf_set_obcs_xz( OBSu, OBSu0, OBSu1, OBSufile, 'u'
107     I , fac, first, changed, count0, count1
108     I , mycurrenttime, mycurrentiter, mythid )
109     call exf_set_obcs_xz( OBSv, OBSv0, OBSv1, OBSvfile, 'v'
110     I , fac, first, changed, count0, count1
111     I , mycurrenttime, mycurrentiter, mythid )
112     call exf_set_obcs_xz( OBSt, OBSt0, OBSt1, OBStfile, 's'
113     I , fac, first, changed, count0, count1
114     I , mycurrenttime, mycurrentiter, mythid )
115     call exf_set_obcs_xz( OBSs, OBSs0, OBSs1, OBSsfile, 's'
116     I , fac, first, changed, count0, count1
117     I , mycurrenttime, mycurrentiter, mythid )
118    
119 mlosch 1.7 #ifdef ALLOW_PTRACERS
120     if ( usePTRACERS ) then
121     do itracer = 1, PTRACERS_numInUse
122     call exf_set_obcs_xz( OBSptr (1-Olx,1,1,1,iTracer)
123     I , OBSptr0(1-Olx,1,1,1,iTracer)
124     I , OBSptr1(1-Olx,1,1,1,iTracer)
125     I , OBSptrFile(iTracer), 's'
126     I , fac, first, changed, count0, count1
127     I , mycurrenttime, mycurrentiter, mythid )
128     enddo
129     endif
130     #endif /* ALLOW_PTRACERS */
131 heimbach 1.1 #endif
132    
133     #ifdef ALLOW_OBCS_EAST
134     call exf_getffieldrec(
135     I obcsEstartdate, obcsEperiod
136 heimbach 1.3 I , obcsEstartdate1, obcsEstartdate2
137 heimbach 1.4 I , .false.
138     O , fac, first, changed
139     O , count0, count1, year0, year1
140 heimbach 1.1 I , mycurrenttime, mycurrentiter, mythid
141     & )
142    
143     call exf_set_obcs_yz( OBEu, OBEu0, OBEu1, OBEufile, 'u'
144     I , fac, first, changed, count0, count1
145     I , mycurrenttime, mycurrentiter, mythid )
146     call exf_set_obcs_yz( OBEv, OBEv0, OBEv1, OBEvfile, 'v'
147     I , fac, first, changed, count0, count1
148     I , mycurrenttime, mycurrentiter, mythid )
149     call exf_set_obcs_yz( OBEt, OBEt0, OBEt1, OBEtfile, 's'
150     I , fac, first, changed, count0, count1
151     I , mycurrenttime, mycurrentiter, mythid )
152     call exf_set_obcs_yz( OBEs, OBEs0, OBEs1, OBEsfile, 's'
153     I , fac, first, changed, count0, count1
154     I , mycurrenttime, mycurrentiter, mythid )
155 mlosch 1.7 #ifdef ALLOW_PTRACERS
156     if ( usePTRACERS ) then
157     do itracer = 1, PTRACERS_numInUse
158     call exf_set_obcs_yz( OBEptr (1-Oly,1,1,1,iTracer)
159     I , OBEptr0(1-Oly,1,1,1,iTracer)
160     I , OBEptr1(1-Oly,1,1,1,iTracer)
161     I , OBEptrFile(iTracer), 's'
162     I , fac, first, changed, count0, count1
163     I , mycurrenttime, mycurrentiter, mythid )
164     enddo
165     endif
166     #endif /* ALLOW_PTRACERS */
167 heimbach 1.1 #endif
168    
169     #ifdef ALLOW_OBCS_WEST
170     call exf_getffieldrec(
171     I obcsWstartdate, obcsWperiod
172 heimbach 1.3 I , obcsWstartdate1, obcsWstartdate2
173 heimbach 1.4 I , .false.
174     O , fac, first, changed
175     O , count0, count1, year0, year1
176 heimbach 1.1 I , mycurrenttime, mycurrentiter, mythid
177     & )
178    
179     call exf_set_obcs_yz( OBWu, OBWu0, OBWu1, OBWufile, 'u'
180     I , fac, first, changed, count0, count1
181     I , mycurrenttime, mycurrentiter, mythid )
182     call exf_set_obcs_yz( OBWv, OBWv0, OBWv1, OBWvfile, 'v'
183     I , fac, first, changed, count0, count1
184     I , mycurrenttime, mycurrentiter, mythid )
185     call exf_set_obcs_yz( OBWt, OBWt0, OBWt1, OBWtfile, 's'
186     I , fac, first, changed, count0, count1
187     I , mycurrenttime, mycurrentiter, mythid )
188     call exf_set_obcs_yz( OBWs, OBWs0, OBWs1, OBWsfile, 's'
189     I , fac, first, changed, count0, count1
190     I , mycurrenttime, mycurrentiter, mythid )
191 mlosch 1.7 #ifdef ALLOW_PTRACERS
192     if ( usePTRACERS ) then
193     do itracer = 1, PTRACERS_numInUse
194     call exf_set_obcs_yz( OBWptr (1-Oly,1,1,1,iTracer)
195     I , OBWptr0(1-Oly,1,1,1,iTracer)
196     I , OBWptr1(1-Oly,1,1,1,iTracer)
197     I , OBWptrFile(iTracer), 's'
198     I , fac, first, changed, count0, count1
199     I , mycurrenttime, mycurrentiter, mythid )
200     enddo
201     endif
202     #endif /* ALLOW_PTRACERS */
203 heimbach 1.1 #endif
204    
205     #ifdef ALLOW_OBCS_CONTROL
206     cgg WARNING: Assuming North Open Boundary exists and has same
207     cgg calendar information as other boundaries.
208     call ctrl_obcsbal ( mycurrenttime,mycurrentiter,mythid )
209     #endif
210    
211     #ifdef ALLOW_OBCSN_CONTROL
212     call ctrl_getobcsn ( mycurrenttime, mycurrentiter, mythid )
213     #endif
214    
215     #ifdef ALLOW_OBCSS_CONTROL
216     call ctrl_getobcss ( mycurrenttime, mycurrentiter, mythid )
217     #endif
218    
219     #ifdef ALLOW_OBCSW_CONTROL
220     call ctrl_getobcsw ( mycurrenttime, mycurrentiter, mythid )
221     #endif
222    
223     #ifdef ALLOW_OBCSE_CONTROL
224     call ctrl_getobcse ( mycurrenttime, mycurrentiter, mythid )
225     #endif
226    
227 mlosch 1.2 #else /* not ALLOW_EXF */
228     CALL OBCS_EXTERNAL_FIELDS_LOAD(
229     & myCurrentTime, myCurrentIter, myThid )
230     #endif /* ALLOw_EXF */
231 heimbach 1.1
232     #endif /* ALLOW_OBCS */
233    
234 adcroft 1.6 RETURN
235     END

  ViewVC Help
Powered by ViewVC 1.1.22