/[MITgcm]/MITgcm/pkg/exf/exf_set_uv.F
ViewVC logotype

Diff of /MITgcm/pkg/exf/exf_set_uv.F

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

revision 1.1 by dimitri, Wed Dec 10 19:37:25 2003 UTC revision 1.19 by dimitri, Tue Jan 29 11:25:53 2008 UTC
# Line 1  Line 1 
1  C $Header$  C $Header$
2  C $Name$  C $Name$
3    
 #include "PACKAGES_CONFIG.h"  
4  #include "EXF_OPTIONS.h"  #include "EXF_OPTIONS.h"
5    
 #ifdef USE_EXF_INTERPOLATION  
   
6        subroutine exf_set_uv(        subroutine exf_set_uv(
7       &     uvecfile, uvecstartdate, uvecperiod,       &     uvecfile, uvecstartdate, uvecperiod,
8       &     exf_inscal_uvec, uvec, uvec0, uvec1, uvecmask,       &     exf_inscal_uvec, uvec, uvec0, uvec1, uvecmask,
9       &     uvec_lon0, uvec_lon_inc, uvec_lat0, uvec_lat_inc,       &     uvec_lon0, uvec_lon_inc, uvec_lat0, uvec_lat_inc,
10       &     uvec_nlon, uvec_nlat,       &     uvec_nlon, uvec_nlat,
11         &     uvec_remove_intercept, uvec_remove_slope,
12       &     vvecfile, vvecstartdate, vvecperiod,       &     vvecfile, vvecstartdate, vvecperiod,
13       &     exf_inscal_vvec, vvec, vvec0, vvec1, vvecmask,       &     exf_inscal_vvec, vvec, vvec0, vvec1, vvecmask,
14       &     vvec_lon0, vvec_lon_inc, vvec_lat0, vvec_lat_inc,       &     vvec_lon0, vvec_lon_inc, vvec_lat0, vvec_lat_inc,
15       &     vvec_nlon, vvec_nlat, output_xC_yC,       &     vvec_nlon, vvec_nlat,
16         &     vvec_remove_intercept, vvec_remove_slope,
17       &     mycurrenttime, mycurrentiter, mythid )       &     mycurrenttime, mycurrentiter, mythid )
18    
19  c     ==================================================================  c     ==================================================================
# Line 40  c     == global variables == Line 39  c     == global variables ==
39  #include "DYNVARS.h"  #include "DYNVARS.h"
40  #include "GRID.h"  #include "GRID.h"
41    
42  #include "exf_param.h"  #include "EXF_PARAM.h"
43  #include "exf_fields.h"  #include "EXF_FIELDS.h"
44  #include "exf_constants.h"  #include "EXF_CONSTANTS.h"
45    
46  #ifdef ALLOW_AUTODIFF  #ifdef ALLOW_AUTODIFF
47  # include "ctrl.h"  # include "ctrl.h"
# Line 56  c         *vec_lat_0          corner of Line 55  c         *vec_lat_0          corner of
55  c     *vec_nlon, *vec_nlat :: input x-grid and y-grid size for *vec  c     *vec_nlon, *vec_nlat :: input x-grid and y-grid size for *vec
56  c     *vec_lon_inc         :: scalar x-grid increment for *vec  c     *vec_lon_inc         :: scalar x-grid increment for *vec
57  c     *vec_lat_inc         :: vector y-grid increments for *vec  c     *vec_lat_inc         :: vector y-grid increments for *vec
 c     output_xC_yC         :: when true, output grid is (xC,yC)  
 c                             otherwise, uvec is at (xG,yC) and  
 c                             vvec is at (xC,yG).  
58    
59        character*(128) uvecfile        character*(128) uvecfile, uvecfile0, uvecfile1
60        _RL     uvecstartdate, uvecperiod        _RL     uvecstartdate, uvecperiod
61        _RL     exf_inscal_uvec        _RL     exf_inscal_uvec
62          _RL     uvec_remove_intercept, uvec_remove_slope
63        _RL     uvec  (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     uvec  (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
64        _RL     uvec0 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     uvec0 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
65        _RL     uvec1 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     uvec1 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
# Line 70  c                             vvec is at Line 67  c                             vvec is at
67        _RL uvec_lon0, uvec_lon_inc        _RL uvec_lon0, uvec_lon_inc
68        _RL uvec_lat0, uvec_lat_inc(MAX_LAT_INC)        _RL uvec_lat0, uvec_lat_inc(MAX_LAT_INC)
69        INTEGER uvec_nlon, uvec_nlat        INTEGER uvec_nlon, uvec_nlat
70        character*(128) vvecfile        character*(128) vvecfile, vvecfile0, vvecfile1
71        _RL     vvecstartdate, vvecperiod        _RL     vvecstartdate, vvecperiod
72        _RL     exf_inscal_vvec        _RL     exf_inscal_vvec
73          _RL     vvec_remove_intercept, vvec_remove_slope
74        _RL     vvec  (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     vvec  (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
75        _RL     vvec0 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     vvec0 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
76        _RL     vvec1 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     vvec1 (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
# Line 80  c                             vvec is at Line 78  c                             vvec is at
78        _RL vvec_lon0, vvec_lon_inc        _RL vvec_lon0, vvec_lon_inc
79        _RL vvec_lat0, vvec_lat_inc(MAX_LAT_INC)        _RL vvec_lat0, vvec_lat_inc(MAX_LAT_INC)
80        INTEGER vvec_nlon, vvec_nlat        INTEGER vvec_nlon, vvec_nlat
       logical output_xC_yC  
81        _RL     mycurrenttime        _RL     mycurrenttime
82        integer mycurrentiter        integer mycurrentiter
83        integer mythid        integer mythid
84    
85    #ifdef USE_EXF_INTERPOLATION
86  c     == local variables ==  c     == local variables ==
87    
88        logical first, changed        logical first, changed
# Line 93  c     == local variables == Line 91  c     == local variables ==
91        _RL     tmp_v (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)        _RL     tmp_v (1-olx:snx+olx,1-oly:sny+oly,nsx,nsy)
92        integer count0, count1        integer count0, count1
93        integer i, j, bi, bj        integer i, j, bi, bj
94        integer   interp_method        integer   il, interp_method
95        parameter(interp_method=2)        integer year0, year1
96    
97  c     == end of interface ==  c     == external ==
98    
99        IF ( useCubedSphereExchange ) THEN        integer  ilnblnk
100          external ilnblnk
101    
102           if ( uvecfile .NE. ' ' .and. vvecfile .NE. ' ' ) then  c     == end of interface ==
103    
104          IF ( usingCurvilinearGrid ) THEN
105    
106  c     some restrictions that can be relaxed later on          if ( uvecfile .NE. ' ' .and. vvecfile .NE. ' ' ) then
             if ( uvecstartdate .ne. vvecstartdate .or.  
      &           uvecperiod    .ne. vvecperiod ) then  
                print*,'For useCubedSphereExchange, S/R exf_set_uv.F'  
                print*,'assumes that the u and v wind or wind stress'  
                print*,'files have the same startdate and period.'  
                stop  
             endif  
             if ( .not. output_xC_yC ) then  
                print*,'For useCubedSphereExchange, S/R exf_set_uv.F'  
                print*,'assumes that the output grid is (xC,yC).'  
                stop  
             endif  
107    
108  c     get record numbers and interpolation factor  c     get record numbers and interpolation factor
109              call exf_GetFFieldRec(            call exf_GetFFieldRec(
110       I           uvecstartdate, uvecperiod       I        uvecstartdate, uvecperiod
111       O           , fac, first, changed       I        , useExfYearlyFields
112       O           , count0, count1       O        , fac, first, changed
113       I           , mycurrenttime, mycurrentiter, mythid       O        , count0, count1, year0, year1
114       &           )       I        , mycurrenttime, mycurrentiter, mythid
115         &        )
116    
117              if ( first ) then
118    
119                call exf_GetYearlyFieldName(
120         I         useExfYearlyFields, twoDigitYear, uvecperiod, year0,
121         I         uvecfile,
122         O         uvecfile0,
123         I         mycurrenttime, mycurrentiter, mythid )
124                call exf_GetYearlyFieldName(
125         I         useExfYearlyFields, twoDigitYear, vvecperiod, year0,
126         I         vvecfile,
127         O         vvecfile0,
128         I         mycurrenttime, mycurrentiter, mythid )
129    
             if ( first ) then  
130  c     scalar interpolation to (xC,yC) locations  c     scalar interpolation to (xC,yC) locations
131                 call exf_interp( uvecfile, exf_iprec              interp_method=12
132       &              , tmp_u, count0, xC, yC              call exf_interp( uvecfile0, exf_iprec
133       &              , uvec_lon0,uvec_lon_inc       &          , tmp_u, count0, xC, yC
134       &              , uvec_lat0,uvec_lat_inc       &          , uvec_lon0,uvec_lon_inc
135       &              , uvec_nlon,uvec_nlat,interp_method,mythid       &          , uvec_lat0,uvec_lat_inc
136       &              )       &          , uvec_nlon,uvec_nlat,interp_method,mythid
137                 call exf_interp( vvecfile, exf_iprec       &          )
138       &              , tmp_v, count0, xC, yC              interp_method=22
139       &              , vvec_lon0,vvec_lon_inc              call exf_interp( vvecfile0, exf_iprec
140       &              , vvec_lat0,vvec_lat_inc       &          , tmp_v, count0, xC, yC
141       &              , vvec_nlon,vvec_nlat,interp_method,mythid       &          , vvec_lon0,vvec_lon_inc
142       &              )       &          , vvec_lat0,vvec_lat_inc
143  c     apply scaling factor       &          , vvec_nlon,vvec_nlat,interp_method,mythid
144                 do bj = mybylo(mythid),mybyhi(mythid)       &          )
145                  do bi = mybxlo(mythid),mybxhi(mythid)  c     vector rotation
146                   do j = 1,sny              do bj = mybylo(mythid),mybyhi(mythid)
147                  do bi = mybxlo(mythid),mybxhi(mythid)
148                    do j = 1,sny
149                    do i = 1,snx                    do i = 1,snx
150                     tmp_u(i,j,bi,bj)=exf_inscal_uvec*tmp_u(i,j,bi,bj)                      x1=xG(i,j,bi,bj)
151                     tmp_v(i,j,bi,bj)=exf_inscal_vvec*tmp_v(i,j,bi,bj)                      x2=xG(i+1,j,bi,bj)
152                        x3=xG(i,j+1,bi,bj)
153                        x4=xG(i+1,j+1,bi,bj)
154                        if ((x2-x1).gt.180) x2=x2-360
155                        if ((x1-x2).gt.180) x2=x2+360
156                        if ((x3-x1).gt.180) x3=x3-360
157                        if ((x1-x3).gt.180) x3=x3+360
158                        if ((x4-x1).gt.180) x4=x4-360
159                        if ((x1-x4).gt.180) x4=x4+360
160                        y1=yG(i,j,bi,bj)
161                        y2=yG(i+1,j,bi,bj)
162                        y3=yG(i,j+1,bi,bj)
163                        y4=yG(i+1,j+1,bi,bj)
164                        dx=0.5*(x3+x4-x1-x2)
165                        dx=dx*
166         &                  cos(deg2rad*yC(i,j,bi,bj))
167                        dy=0.5*(y3+y4-y1-y2)
168                        vvec1(i,j,bi,bj)=
169         &                  (tmp_u(i,j,bi,bj)*dx+
170         &                  tmp_v(i,j,bi,bj)*dy)/
171         &                  sqrt(dx*dx+dy*dy)
172                        dx=0.5*(x2+x4-x1-x3)
173                        dx=dx*
174         &                  cos(deg2rad*yC(i,j,bi,bj))
175                        dy=0.5*(y2+y4-y1-y3)
176                        uvec1(i,j,bi,bj)=
177         &                  (tmp_u(i,j,bi,bj)*dx+
178         &                  tmp_v(i,j,bi,bj)*dy)/
179         &                  sqrt(dx*dx+dy*dy)
180                    enddo                    enddo
                  enddo  
181                  enddo                  enddo
182                 enddo                enddo
183  c     vector rotation              enddo
                do bj = mybylo(mythid),mybyhi(mythid)  
                   do bi = mybxlo(mythid),mybxhi(mythid)  
                      do j = 1,sny  
                         do i = 1,snx  
                            x1=xG(i,j,bi,bj)  
                            x2=xG(i+1,j,bi,bj)  
                            x3=xG(i,j+1,bi,bj)  
                            x4=xG(i+1,j+1,bi,bj)  
                            if ((x2-x1).gt.180) x2=x2-360  
                            if ((x1-x2).gt.180) x2=x2+360  
                            if ((x3-x1).gt.180) x3=x3-360  
                            if ((x1-x3).gt.180) x3=x3+360  
                            if ((x4-x1).gt.180) x4=x4-360  
                            if ((x1-x4).gt.180) x4=x4+360  
                            y1=yG(i,j,bi,bj)  
                            y2=yG(i+1,j,bi,bj)  
                            y3=yG(i,j+1,bi,bj)  
                            y4=yG(i+1,j+1,bi,bj)  
                            dx=0.5*(x3+x4-x1-x2)  
                            dx=dx*cos(deg2rad*yC(i,j,bi,bj))  
                            dy=0.5*(y3+y4-y1-y2)  
                            vvec1(i,j,bi,bj)=(tmp_u(i,j,bi,bj)*dx+  
      &                          tmp_v(i,j,bi,bj)*dy)/sqrt(dx*dx+dy*dy)  
                            dx=0.5*(x2+x4-x1-x3)  
                            dx=dx*cos(deg2rad*yC(i,j,bi,bj))  
                            dy=0.5*(y2+y4-y1-y3)  
                            uvec1(i,j,bi,bj)=(tmp_u(i,j,bi,bj)*dx+  
      &                          tmp_v(i,j,bi,bj)*dy)/sqrt(dx*dx+dy*dy)  
                         enddo  
                      enddo  
                   enddo  
                enddo  
184  c     apply mask  c     apply mask
185                 if (exf_yftype .eq. 'RL') then              if (exf_yftype .eq. 'RL') then
186                    call exf_filter_rl( uvec1, uvecmask, mythid )                call exf_filter_rl( uvec1, uvecmask, mythid )
187                    call exf_filter_rl( vvec1, vvecmask, mythid )                call exf_filter_rl( vvec1, vvecmask, mythid )
188                 else              else
189                    call exf_filter_rs( uvec1, uvecmask, mythid )                call exf_filter_rs( uvec1, uvecmask, mythid )
190                    call exf_filter_rs( vvec1, vvecmask, mythid )                call exf_filter_rs( vvec1, vvecmask, mythid )
191                 end if              end if
192              endif            endif
193    
194              if (( first ) .or. ( changed )) then            if (( first ) .or. ( changed )) then
195                 call exf_SwapFFields( uvec0, uvec1, mythid )              call exf_SwapFFields( uvec0, uvec1, mythid )
196                 call exf_SwapFFields( vvec0, vvec1, mythid )              call exf_SwapFFields( vvec0, vvec1, mythid )
197    
198                call exf_GetYearlyFieldName(
199         I         useExfYearlyFields, twoDigitYear, uvecperiod, year1,
200         I         uvecfile,
201         O         uvecfile1,
202         I         mycurrenttime, mycurrentiter, mythid )
203                call exf_GetYearlyFieldName(
204         I         useExfYearlyFields, twoDigitYear, vvecperiod, year1,
205         I         vvecfile,
206         O         vvecfile1,
207         I         mycurrenttime, mycurrentiter, mythid )
208    
209  c     scalar interpolation to (xC,yC) locations  c     scalar interpolation to (xC,yC) locations
210                 call exf_interp( uvecfile, exf_iprec              interp_method=12
211       &              , tmp_u, count1, xC, yC              call exf_interp( uvecfile1, exf_iprec
212       &              , uvec_lon0,uvec_lon_inc       &          , tmp_u, count1, xC, yC
213       &              , uvec_lat0,uvec_lat_inc       &          , uvec_lon0,uvec_lon_inc
214       &              , uvec_nlon,uvec_nlat,interp_method,mythid       &          , uvec_lat0,uvec_lat_inc
215       &              )       &          , uvec_nlon,uvec_nlat,interp_method,mythid
216                 call exf_interp( vvecfile, exf_iprec       &          )
217       &              , tmp_v, count1, xC, yC              interp_method=22
218       &              , vvec_lon0,vvec_lon_inc              call exf_interp( vvecfile1, exf_iprec
219       &              , vvec_lat0,vvec_lat_inc       &          , tmp_v, count1, xC, yC
220       &              , vvec_nlon,vvec_nlat,interp_method,mythid       &          , vvec_lon0,vvec_lon_inc
221       &              )       &          , vvec_lat0,vvec_lat_inc
222  c     apply scaling factor       &          , vvec_nlon,vvec_nlat,interp_method,mythid
223                 do bj = mybylo(mythid),mybyhi(mythid)       &          )
224                  do bi = mybxlo(mythid),mybxhi(mythid)  c     vector rotation
225                   do j = 1,sny              do bj = mybylo(mythid),mybyhi(mythid)
226                  do bi = mybxlo(mythid),mybxhi(mythid)
227                    do j = 1,sny
228                    do i = 1,snx                    do i = 1,snx
229                     tmp_u(i,j,bi,bj)=exf_inscal_uvec*tmp_u(i,j,bi,bj)                      x1=xG(i,j,bi,bj)
230                     tmp_v(i,j,bi,bj)=exf_inscal_vvec*tmp_v(i,j,bi,bj)                      x2=xG(i+1,j,bi,bj)
231                        x3=xG(i,j+1,bi,bj)
232                        x4=xG(i+1,j+1,bi,bj)
233                        if ((x2-x1).gt.180) x2=x2-360
234                        if ((x1-x2).gt.180) x2=x2+360
235                        if ((x3-x1).gt.180) x3=x3-360
236                        if ((x1-x3).gt.180) x3=x3+360
237                        if ((x4-x1).gt.180) x4=x4-360
238                        if ((x1-x4).gt.180) x4=x4+360
239                        y1=yG(i,j,bi,bj)
240                        y2=yG(i+1,j,bi,bj)
241                        y3=yG(i,j+1,bi,bj)
242                        y4=yG(i+1,j+1,bi,bj)
243                        dx=0.5*(x3+x4-x1-x2)
244                        dx=dx*
245         &                  cos(deg2rad*yC(i,j,bi,bj))
246                        dy=0.5*(y3+y4-y1-y2)
247                        vvec1(i,j,bi,bj)=
248         &                  (tmp_u(i,j,bi,bj)*dx+
249         &                  tmp_v(i,j,bi,bj)*dy)/
250         &                  sqrt(dx*dx+dy*dy)
251                        dx=0.5*(x2+x4-x1-x3)
252                        dx=dx*
253         &                  cos(deg2rad*yC(i,j,bi,bj))
254                        dy=0.5*(y2+y4-y1-y3)
255                        uvec1(i,j,bi,bj)=
256         &                  (tmp_u(i,j,bi,bj)*dx+
257         &                  tmp_v(i,j,bi,bj)*dy)/
258         &                  sqrt(dx*dx+dy*dy)
259                    enddo                    enddo
                  enddo  
260                  enddo                  enddo
261                 enddo                enddo
262  c     vector rotation              enddo
                do bj = mybylo(mythid),mybyhi(mythid)  
                   do bi = mybxlo(mythid),mybxhi(mythid)  
                      do j = 1,sny  
                         do i = 1,snx  
                            x1=xG(i,j,bi,bj)  
                            x2=xG(i+1,j,bi,bj)  
                            x3=xG(i,j+1,bi,bj)  
                            x4=xG(i+1,j+1,bi,bj)  
                            if ((x2-x1).gt.180) x2=x2-360  
                            if ((x1-x2).gt.180) x2=x2+360  
                            if ((x3-x1).gt.180) x3=x3-360  
                            if ((x1-x3).gt.180) x3=x3+360  
                            if ((x4-x1).gt.180) x4=x4-360  
                            if ((x1-x4).gt.180) x4=x4+360  
                            y1=yG(i,j,bi,bj)  
                            y2=yG(i+1,j,bi,bj)  
                            y3=yG(i,j+1,bi,bj)  
                            y4=yG(i+1,j+1,bi,bj)  
                            dx=0.5*(x3+x4-x1-x2)  
                            dx=dx*cos(deg2rad*yC(i,j,bi,bj))  
                            dy=0.5*(y3+y4-y1-y2)  
                            vvec1(i,j,bi,bj)=(tmp_u(i,j,bi,bj)*dx+  
      &                          tmp_v(i,j,bi,bj)*dy)/sqrt(dx*dx+dy*dy)  
                            dx=0.5*(x2+x4-x1-x3)  
                            dx=dx*cos(deg2rad*yC(i,j,bi,bj))  
                            dy=0.5*(y2+y4-y1-y3)  
                            uvec1(i,j,bi,bj)=(tmp_u(i,j,bi,bj)*dx+  
      &                          tmp_v(i,j,bi,bj)*dy)/sqrt(dx*dx+dy*dy)  
                         enddo  
                      enddo  
                   enddo  
                enddo  
263  c     apply mask  c     apply mask
264                 if (exf_yftype .eq. 'RL') then              if (exf_yftype .eq. 'RL') then
265                    call exf_filter_rl( uvec1, uvecmask, mythid )                call exf_filter_rl( uvec1, uvecmask, mythid )
266                    call exf_filter_rl( vvec1, vvecmask, mythid )                call exf_filter_rl( vvec1, vvecmask, mythid )
267                 else              else
268                    call exf_filter_rs( uvec1, uvecmask, mythid )                call exf_filter_rs( uvec1, uvecmask, mythid )
269                    call exf_filter_rs( vvec1, vvecmask, mythid )                call exf_filter_rs( vvec1, vvecmask, mythid )
270                 end if              end if
271              endif            endif
272    
273  c     Interpolate linearly onto the current time.  c     Interpolate linearly onto the current time.
274              do bj = mybylo(mythid),mybyhi(mythid)            do bj = mybylo(mythid),mybyhi(mythid)
275                 do bi = mybxlo(mythid),mybxhi(mythid)              do bi = mybxlo(mythid),mybxhi(mythid)
276                    do j = 1,sny                do j = 1,sny
277                       do i = 1,snx                  do i = 1,snx
278                          uvec(i,j,bi,bj) = exf_inscal_uvec * (                    uvec(i,j,bi,bj) = exf_inscal_uvec * (
279       &                       fac * uvec0(i,j,bi,bj) +       &                fac * uvec0(i,j,bi,bj) +
280       &                       (exf_one - fac) * uvec1(i,j,bi,bj) )       &                (exf_one - fac) * uvec1(i,j,bi,bj) )
281                          vvec(i,j,bi,bj) = exf_inscal_vvec * (                    vvec(i,j,bi,bj) = exf_inscal_vvec * (
282       &                       fac * vvec0(i,j,bi,bj) +       &                fac * vvec0(i,j,bi,bj) +
283       &                       (exf_one - fac) * vvec1(i,j,bi,bj) )       &                (exf_one - fac) * vvec1(i,j,bi,bj) )
284                       enddo                  enddo
285                    enddo                enddo
                enddo  
286              enddo              enddo
287              enddo
288           endif            
289            endif
290    
291        ELSE        ELSE
292  c     IF ( .NOT. useCubedSphereExchange )  c     IF ( .NOT. usingCurvilinearGrid )
   
          IF ( output_xC_yC ) THEN  
             call exf_set_gen(  
      &           uvecfile, uvecstartdate, uvecperiod,  
      &           exf_inscal_uvec,  
      &           uvec, uvec0, uvec1, uvecmask,  
      &           uvec_lon0, uvec_lon_inc, uvec_lat0, uvec_lat_inc,  
      &           uvec_nlon, uvec_nlat, xC, yC,  
      &           mycurrenttime, mycurrentiter, mythid )  
             call exf_set_gen(  
      &           vvecfile, vvecstartdate, vvecperiod,  
      &           exf_inscal_vvec,  
      &           vvec, vvec0, vvec1, vvecmask,  
      &           vvec_lon0, vvec_lon_inc, vvec_lat0, vvec_lat_inc,  
      &           vvec_nlon, vvec_nlat, xC, yC,  
      &           mycurrenttime, mycurrentiter, mythid )  
          ELSE  
             call exf_set_gen(  
      &           uvecfile, uvecstartdate, uvecperiod,  
      &           exf_inscal_uvec,  
      &           uvec, uvec0, uvec1, uvecmask,  
      &           uvec_lon0, uvec_lon_inc, uvec_lat0, uvec_lat_inc,  
      &           uvec_nlon, uvec_nlat, xG, yC,  
      &           mycurrenttime, mycurrentiter, mythid )  
             call exf_set_gen(  
      &           vvecfile, vvecstartdate, vvecperiod,  
      &           exf_inscal_vvec,  
      &           vvec, vvec0, vvec1, vvecmask,  
      &           vvec_lon0, vvec_lon_inc, vvec_lat0, vvec_lat_inc,  
      &           vvec_nlon, vvec_nlat, xC, yG,  
      &           mycurrenttime, mycurrentiter, mythid )  
          ENDIF  
293    
294           interp_method=12
295            call exf_set_gen(
296         &      uvecfile, uvecstartdate, uvecperiod,
297         &      exf_inscal_uvec,
298         &      uvec_remove_intercept, uvec_remove_slope,
299         &      uvec, uvec0, uvec1, uvecmask,
300         &      uvec_lon0, uvec_lon_inc, uvec_lat0, uvec_lat_inc,
301         &      uvec_nlon, uvec_nlat, xC, yC, interp_method,
302         &      mycurrenttime, mycurrentiter, mythid )
303            interp_method=22
304            call exf_set_gen(
305         &      vvecfile, vvecstartdate, vvecperiod,
306         &      exf_inscal_vvec,
307         &      vvec_remove_intercept, vvec_remove_slope,
308         &      vvec, vvec0, vvec1, vvecmask,
309         &      vvec_lon0, vvec_lon_inc, vvec_lat0, vvec_lat_inc,
310         &      vvec_nlon, vvec_nlat, xC, yC, interp_method,
311         &      mycurrenttime, mycurrentiter, mythid )
312            
313        ENDIF        ENDIF
314    
315    #endif /* USE_EXF_INTERPOLATION */
316    
317        return        return
318        end        end
   
 #endif /* USE_EXF_INTERPOLATION */  

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

  ViewVC Help
Powered by ViewVC 1.1.22