/[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.3 - (hide annotations) (download)
Mon Oct 11 16:41:01 2004 UTC (19 years, 8 months ago) by heimbach
Branch: MAIN
CVS Tags: checkpoint55f_post, checkpoint55e_post, checkpoint55d_post
Changes since 1.2: +11 -2 lines
o enable to read exf forcing fields as either
  single file or yearly files (flag useExfYearlyFields)

1 heimbach 1.3 C $Header: /u/gcmpack/MITgcm/pkg/obcs/obcs_prescribe_read.F,v 1.2 2004/09/24 12:32:09 mlosch 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    
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 mlosch 1.2 #ifdef ALLOW_EXF
48 heimbach 1.1 #ifdef ALLOW_OBCS_NORTH
49     call exf_getffieldrec(
50     I obcsNstartdate, obcsNperiod
51 heimbach 1.3 I , obcsNstartdate1, obcsNstartdate2
52     I , false.
53     O , fac, first, changed,
54     O , count0, count1, year0, year1
55 heimbach 1.1 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 heimbach 1.3 I , obcsSstartdate1, obcsSstartdate2
76     I , false.
77 heimbach 1.1 O , fac, first, changed, count0, count1
78     I , mycurrenttime, mycurrentiter, mythid
79     & )
80    
81     call exf_set_obcs_xz( OBSu, OBSu0, OBSu1, OBSufile, 'u'
82     I , fac, first, changed, count0, count1
83     I , mycurrenttime, mycurrentiter, mythid )
84     call exf_set_obcs_xz( OBSv, OBSv0, OBSv1, OBSvfile, 'v'
85     I , fac, first, changed, count0, count1
86     I , mycurrenttime, mycurrentiter, mythid )
87     call exf_set_obcs_xz( OBSt, OBSt0, OBSt1, OBStfile, 's'
88     I , fac, first, changed, count0, count1
89     I , mycurrenttime, mycurrentiter, mythid )
90     call exf_set_obcs_xz( OBSs, OBSs0, OBSs1, OBSsfile, 's'
91     I , fac, first, changed, count0, count1
92     I , mycurrenttime, mycurrentiter, mythid )
93    
94     #endif
95    
96     #ifdef ALLOW_OBCS_EAST
97     call exf_getffieldrec(
98     I obcsEstartdate, obcsEperiod
99 heimbach 1.3 I , obcsEstartdate1, obcsEstartdate2
100     I , false.
101 heimbach 1.1 O , fac, first, changed, count0, count1
102     I , mycurrenttime, mycurrentiter, mythid
103     & )
104    
105     call exf_set_obcs_yz( OBEu, OBEu0, OBEu1, OBEufile, 'u'
106     I , fac, first, changed, count0, count1
107     I , mycurrenttime, mycurrentiter, mythid )
108     call exf_set_obcs_yz( OBEv, OBEv0, OBEv1, OBEvfile, 'v'
109     I , fac, first, changed, count0, count1
110     I , mycurrenttime, mycurrentiter, mythid )
111     call exf_set_obcs_yz( OBEt, OBEt0, OBEt1, OBEtfile, 's'
112     I , fac, first, changed, count0, count1
113     I , mycurrenttime, mycurrentiter, mythid )
114     call exf_set_obcs_yz( OBEs, OBEs0, OBEs1, OBEsfile, 's'
115     I , fac, first, changed, count0, count1
116     I , mycurrenttime, mycurrentiter, mythid )
117    
118     #endif
119    
120     #ifdef ALLOW_OBCS_WEST
121     call exf_getffieldrec(
122     I obcsWstartdate, obcsWperiod
123 heimbach 1.3 I , obcsWstartdate1, obcsWstartdate2
124     I , false.
125 heimbach 1.1 O , fac, first, changed, count0, count1
126     I , mycurrenttime, mycurrentiter, mythid
127     & )
128    
129     call exf_set_obcs_yz( OBWu, OBWu0, OBWu1, OBWufile, 'u'
130     I , fac, first, changed, count0, count1
131     I , mycurrenttime, mycurrentiter, mythid )
132     call exf_set_obcs_yz( OBWv, OBWv0, OBWv1, OBWvfile, 'v'
133     I , fac, first, changed, count0, count1
134     I , mycurrenttime, mycurrentiter, mythid )
135     call exf_set_obcs_yz( OBWt, OBWt0, OBWt1, OBWtfile, 's'
136     I , fac, first, changed, count0, count1
137     I , mycurrenttime, mycurrentiter, mythid )
138     call exf_set_obcs_yz( OBWs, OBWs0, OBWs1, OBWsfile, 's'
139     I , fac, first, changed, count0, count1
140     I , mycurrenttime, mycurrentiter, mythid )
141    
142     #endif
143    
144     #ifdef ALLOW_OBCS_CONTROL
145     cgg WARNING: Assuming North Open Boundary exists and has same
146     cgg calendar information as other boundaries.
147     call ctrl_obcsbal ( mycurrenttime,mycurrentiter,mythid )
148     #endif
149    
150     #ifdef ALLOW_OBCSN_CONTROL
151     call ctrl_getobcsn ( mycurrenttime, mycurrentiter, mythid )
152     #endif
153    
154     #ifdef ALLOW_OBCSS_CONTROL
155     call ctrl_getobcss ( mycurrenttime, mycurrentiter, mythid )
156     #endif
157    
158     #ifdef ALLOW_OBCSW_CONTROL
159     call ctrl_getobcsw ( mycurrenttime, mycurrentiter, mythid )
160     #endif
161    
162     #ifdef ALLOW_OBCSE_CONTROL
163     call ctrl_getobcse ( mycurrenttime, mycurrentiter, mythid )
164     #endif
165    
166 mlosch 1.2 #else /* not ALLOW_EXF */
167     CALL OBCS_EXTERNAL_FIELDS_LOAD(
168     & myCurrentTime, myCurrentIter, myThid )
169     #endif /* ALLOw_EXF */
170 heimbach 1.1
171     #endif /* ALLOW_OBCS */
172    
173     end
174    

  ViewVC Help
Powered by ViewVC 1.1.22