/[MITgcm]/MITgcm/pkg/ctrl/ctrl_init_variables.F
ViewVC logotype

Diff of /MITgcm/pkg/ctrl/ctrl_init_variables.F

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

revision 1.1 by heimbach, Mon Mar 25 22:50:46 2002 UTC revision 1.2 by heimbach, Mon Jun 23 22:29:05 2003 UTC
# Line 0  Line 1 
1    
2    #include "CTRL_CPPOPTIONS.h"
3    
4    
5          subroutine ctrl_init_variables( mythid )
6    
7    c     ==================================================================
8    c     SUBROUTINE ctrl_init_variables
9    c     ==================================================================
10    c
11    c     o Set parts of the vector of control variables and initialize the
12    c       rest to zero.
13    c
14    c     started: heimbach@mit.edu 25-Mar-2002
15    c
16    c     ==================================================================
17    c     SUBROUTINE ctrl_init_variables
18    c     ==================================================================
19    
20          implicit none
21    
22    c     == global variables ==
23    
24    #include "EEPARAMS.h"
25    #include "SIZE.h"
26    #include "PARAMS.h"
27    #include "GRID.h"
28    #include "ctrl.h"
29    #ifdef ALLOW_CALENDAR
30    # include "cal.h"
31    #endif
32    
33    c     == routine arguments ==
34    
35          integer mythid
36    
37    c     == local variables ==
38    
39          integer bi,bj
40          integer i,j,k
41          integer itlo,ithi
42          integer jtlo,jthi
43          integer jmin,jmax
44          integer imin,imax
45          integer ntmp
46          integer ivarindex
47    
48    c     == end of interface ==
49    
50          jtlo = mybylo(mythid)
51          jthi = mybyhi(mythid)
52          itlo = mybxlo(mythid)
53          ithi = mybxhi(mythid)
54          jmin = 1-oly
55          jmax = sny+oly
56          imin = 1-olx
57          imax = snx+olx
58    
59    #ifdef ALLOW_HFLUX_CONTROL
60          do bj = jtlo,jthi
61            do bi = itlo,ithi
62              do j = jmin,jmax
63                do i = imin,imax
64                  xx_hflux0(i,j,bi,bj) = 0. _d 0
65                  xx_hflux1(i,j,bi,bj) = 0. _d 0
66                enddo
67              enddo
68            enddo
69          enddo
70    #endif
71    
72    #ifdef ALLOW_SFLUX_CONTROL
73          do bj = jtlo,jthi
74            do bi = itlo,ithi
75              do j = jmin,jmax
76                do i = imin,imax
77                  xx_sflux0(i,j,bi,bj) = 0. _d 0
78                  xx_sflux1(i,j,bi,bj) = 0. _d 0
79                enddo
80              enddo
81            enddo
82          enddo
83    #endif
84    
85    #ifdef ALLOW_USTRESS_CONTROL
86          do bj = jtlo,jthi
87            do bi = itlo,ithi
88              do j = jmin,jmax
89                do i = imin,imax
90                  xx_tauu0(i,j,bi,bj) = 0. _d 0
91                  xx_tauu1(i,j,bi,bj) = 0. _d 0
92                enddo
93              enddo
94            enddo
95          enddo
96    #endif
97    
98    #ifdef ALLOW_VSTRESS_CONTROL
99          do bj = jtlo,jthi
100            do bi = itlo,ithi
101              do j = jmin,jmax
102                do i = imin,imax
103                  xx_tauv0(i,j,bi,bj) = 0. _d 0
104                  xx_tauv1(i,j,bi,bj) = 0. _d 0
105                enddo
106              enddo
107            enddo
108          enddo
109    #endif
110    
111    #ifdef ALLOW_UWIND_CONTROL
112          do bj = jtlo,jthi
113            do bi = itlo,ithi
114              do j = jmin,jmax
115                do i = imin,imax
116                  xx_uwind0(i,j,bi,bj) = 0. _d 0
117                  xx_uwind1(i,j,bi,bj) = 0. _d 0
118                enddo
119              enddo
120            enddo
121          enddo
122    #endif
123    
124    #ifdef ALLOW_VWIND_CONTROL
125          do bj = jtlo,jthi
126            do bi = itlo,ithi
127              do j = jmin,jmax
128                do i = imin,imax
129                  xx_vwind0(i,j,bi,bj) = 0. _d 0
130                  xx_vwind1(i,j,bi,bj) = 0. _d 0
131                enddo
132              enddo
133            enddo
134          enddo
135    #endif
136    
137    #ifdef ALLOW_ATEMP_CONTROL
138          do bj = jtlo,jthi
139            do bi = itlo,ithi
140              do j = jmin,jmax
141                do i = imin,imax
142                  xx_atemp0(i,j,bi,bj) = 0. _d 0
143                  xx_atemp1(i,j,bi,bj) = 0. _d 0
144                enddo
145              enddo
146            enddo
147          enddo
148    #endif
149    
150    #ifdef ALLOW_AQH_CONTROL
151          do bj = jtlo,jthi
152            do bi = itlo,ithi
153              do j = jmin,jmax
154                do i = imin,imax
155                  xx_aqh0(i,j,bi,bj) = 0. _d 0
156                  xx_aqh1(i,j,bi,bj) = 0. _d 0
157                enddo
158              enddo
159            enddo
160          enddo
161    #endif
162    
163    #ifdef ALLOW_OBCS_CONTROL
164          IF (useOBCS) CALL CTRL_INIT_OBCS_VARIABLES( mythid )
165    #endif
166    
167          return
168          end
169    

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.22