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

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

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


Revision 1.4 - (show annotations) (download)
Thu Oct 14 11:53:20 2004 UTC (19 years, 8 months ago) by heimbach
Branch: MAIN
Changes since 1.3: +11 -8 lines
fix for new exf_getffieldrec format.

1 C $Header: /u/gcmpack/MITgcm/pkg/obcs/obcs_prescribe_read.F,v 1.3 2004/10/11 16:41:01 heimbach Exp $
2 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
31 c == routine arguments ==
32
33 _RL mycurrenttime
34 integer mycurrentiter
35 integer mythid
36
37 #if (defined (ALLOW_OBCS) && defined (ALLOW_OBCS_PRESCRIBE))
38
39 c == local variables ==
40
41 logical first, changed
42 integer count0, count1
43 _RL fac
44
45 c == end of interface ==
46
47 #ifdef ALLOW_EXF
48 #ifdef ALLOW_OBCS_NORTH
49 call exf_getffieldrec(
50 I obcsNstartdate, obcsNperiod
51 I , obcsNstartdate1, obcsNstartdate2
52 I , .false.
53 O , fac, first, changed,
54 O , count0, count1, year0, year1
55 I , mycurrenttime, mycurrentiter, mythid
56 & )
57
58 call exf_set_obcs_xz( OBNu, OBNu0, OBNu1, OBNufile, 'u'
59 I , fac, first, changed, count0, count1
60 I , mycurrenttime, mycurrentiter, mythid )
61 call exf_set_obcs_xz( OBNv, OBNv0, OBNv1, OBNvfile, 'v'
62 I , fac, first, changed, count0, count1
63 I , mycurrenttime, mycurrentiter, mythid )
64 call exf_set_obcs_xz( OBNt, OBNt0, OBNt1, OBNtfile, 's'
65 I , fac, first, changed, count0, count1
66 I , mycurrenttime, mycurrentiter, mythid )
67 call exf_set_obcs_xz( OBNs, OBNs0, OBNs1, OBNsfile, 's'
68 I , fac, first, changed, count0, count1
69 I , mycurrenttime, mycurrentiter, mythid )
70 #endif
71
72 #ifdef ALLOW_OBCS_SOUTH
73 call exf_getffieldrec(
74 I obcsSstartdate, obcsSperiod
75 I , obcsSstartdate1, obcsSstartdate2
76 I , .false.
77 O , fac, first, changed
78 O , count0, count1, year0, year1
79 I , mycurrenttime, mycurrentiter, mythid
80 & )
81
82 call exf_set_obcs_xz( OBSu, OBSu0, OBSu1, OBSufile, 'u'
83 I , fac, first, changed, count0, count1
84 I , mycurrenttime, mycurrentiter, mythid )
85 call exf_set_obcs_xz( OBSv, OBSv0, OBSv1, OBSvfile, 'v'
86 I , fac, first, changed, count0, count1
87 I , mycurrenttime, mycurrentiter, mythid )
88 call exf_set_obcs_xz( OBSt, OBSt0, OBSt1, OBStfile, 's'
89 I , fac, first, changed, count0, count1
90 I , mycurrenttime, mycurrentiter, mythid )
91 call exf_set_obcs_xz( OBSs, OBSs0, OBSs1, OBSsfile, 's'
92 I , fac, first, changed, count0, count1
93 I , mycurrenttime, mycurrentiter, mythid )
94
95 #endif
96
97 #ifdef ALLOW_OBCS_EAST
98 call exf_getffieldrec(
99 I obcsEstartdate, obcsEperiod
100 I , obcsEstartdate1, obcsEstartdate2
101 I , .false.
102 O , fac, first, changed
103 O , count0, count1, year0, year1
104 I , mycurrenttime, mycurrentiter, mythid
105 & )
106
107 call exf_set_obcs_yz( OBEu, OBEu0, OBEu1, OBEufile, 'u'
108 I , fac, first, changed, count0, count1
109 I , mycurrenttime, mycurrentiter, mythid )
110 call exf_set_obcs_yz( OBEv, OBEv0, OBEv1, OBEvfile, 'v'
111 I , fac, first, changed, count0, count1
112 I , mycurrenttime, mycurrentiter, mythid )
113 call exf_set_obcs_yz( OBEt, OBEt0, OBEt1, OBEtfile, 's'
114 I , fac, first, changed, count0, count1
115 I , mycurrenttime, mycurrentiter, mythid )
116 call exf_set_obcs_yz( OBEs, OBEs0, OBEs1, OBEsfile, 's'
117 I , fac, first, changed, count0, count1
118 I , mycurrenttime, mycurrentiter, mythid )
119
120 #endif
121
122 #ifdef ALLOW_OBCS_WEST
123 call exf_getffieldrec(
124 I obcsWstartdate, obcsWperiod
125 I , obcsWstartdate1, obcsWstartdate2
126 I , .false.
127 O , fac, first, changed
128 O , count0, count1, year0, year1
129 I , mycurrenttime, mycurrentiter, mythid
130 & )
131
132 call exf_set_obcs_yz( OBWu, OBWu0, OBWu1, OBWufile, 'u'
133 I , fac, first, changed, count0, count1
134 I , mycurrenttime, mycurrentiter, mythid )
135 call exf_set_obcs_yz( OBWv, OBWv0, OBWv1, OBWvfile, 'v'
136 I , fac, first, changed, count0, count1
137 I , mycurrenttime, mycurrentiter, mythid )
138 call exf_set_obcs_yz( OBWt, OBWt0, OBWt1, OBWtfile, 's'
139 I , fac, first, changed, count0, count1
140 I , mycurrenttime, mycurrentiter, mythid )
141 call exf_set_obcs_yz( OBWs, OBWs0, OBWs1, OBWsfile, 's'
142 I , fac, first, changed, count0, count1
143 I , mycurrenttime, mycurrentiter, mythid )
144
145 #endif
146
147 #ifdef ALLOW_OBCS_CONTROL
148 cgg WARNING: Assuming North Open Boundary exists and has same
149 cgg calendar information as other boundaries.
150 call ctrl_obcsbal ( mycurrenttime,mycurrentiter,mythid )
151 #endif
152
153 #ifdef ALLOW_OBCSN_CONTROL
154 call ctrl_getobcsn ( mycurrenttime, mycurrentiter, mythid )
155 #endif
156
157 #ifdef ALLOW_OBCSS_CONTROL
158 call ctrl_getobcss ( mycurrenttime, mycurrentiter, mythid )
159 #endif
160
161 #ifdef ALLOW_OBCSW_CONTROL
162 call ctrl_getobcsw ( mycurrenttime, mycurrentiter, mythid )
163 #endif
164
165 #ifdef ALLOW_OBCSE_CONTROL
166 call ctrl_getobcse ( mycurrenttime, mycurrentiter, mythid )
167 #endif
168
169 #else /* not ALLOW_EXF */
170 CALL OBCS_EXTERNAL_FIELDS_LOAD(
171 & myCurrentTime, myCurrentIter, myThid )
172 #endif /* ALLOw_EXF */
173
174 #endif /* ALLOW_OBCS */
175
176 end
177

  ViewVC Help
Powered by ViewVC 1.1.22