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

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

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

revision 1.1 by heimbach, Mon May 14 22:08:41 2001 UTC revision 1.1.4.1 by heimbach, Mon Apr 8 20:10:38 2002 UTC
# Line 65  c     == local variables == Line 65  c     == local variables ==
65    
66  c     == end of interface ==  c     == end of interface ==
67    
68    #ifdef ALLOW_CLIM_CYCLIC
69    c     record numbers are assumed 1 to 12 corresponding to
70    c     Jan. through Dec.
71          call cal_GetMonthsRec(
72         O                       fac, first, changed,
73         O                       count0, count1,
74         I                       mycurrenttime, mycurrentiter, mythid
75         &                     )
76    #else
77  c     get record numbers and interpolation factor for climsalt  c     get record numbers and interpolation factor for climsalt
78        call exf_GetFFieldRec(        call exf_GetFFieldRec(
79       I                       climsaltstartdate, climsaltperiod       I                       climsaltstartdate, climsaltperiod
# Line 72  c     get record numbers and interpolati Line 81  c     get record numbers and interpolati
81       O                     , count0, count1       O                     , count0, count1
82       I                     , mycurrenttime, mycurrentiter, mythid       I                     , mycurrenttime, mycurrentiter, mythid
83       &                     )       &                     )
84    #endif
85    
86    #ifndef ALLOW_AUTODIFF_TAMC
87        if ( first ) then        if ( first ) then
88    #endif
89          call mdsreadfield( climsaltfile, exf_clim_iprec          call mdsreadfield( climsaltfile, exf_clim_iprec
90       &                   , exf_clim_yftype, nr       &                   , exf_clim_yftype, nr
91       &                   , climsalt1, count0, mythid       &                   , climsalt1, count0, mythid
# Line 83  c     get record numbers and interpolati Line 95  c     get record numbers and interpolati
95          else          else
96             call exf_filter_rs( climsalt1, climsaltmask, mythid )             call exf_filter_rs( climsalt1, climsaltmask, mythid )
97          end if          end if
98    #ifndef ALLOW_AUTODIFF_TAMC
99        endif        endif
100    #endif
101    
102    #ifndef ALLOW_AUTODIFF_TAMC
103        if (( first ) .or. ( changed )) then        if (( first ) .or. ( changed )) then
104    #endif
105          call exf_SwapFFields_3d( climsalt0, climsalt1, mythid )          call exf_SwapFFields_3d( climsalt0, climsalt1, mythid )
106    
107          call mdsreadfield( climsaltfile, exf_clim_iprec          call mdsreadfield( climsaltfile, exf_clim_iprec
# Line 97  c     get record numbers and interpolati Line 113  c     get record numbers and interpolati
113          else          else
114             call exf_filter_rs( climsalt1, climsaltmask, mythid )             call exf_filter_rs( climsalt1, climsaltmask, mythid )
115          end if          end if
116    #ifndef ALLOW_AUTODIFF_TAMC
117        endif        endif
118    #endif
119    
120  c     Loop over tiles.  c     Loop over tiles.
121        do bj = mybylo(mythid),mybyhi(mythid)        do bj = mybylo(mythid),mybyhi(mythid)
# Line 107  c     Loop over tiles. Line 125  c     Loop over tiles.
125                do i = 1-olx,snx+olx                do i = 1-olx,snx+olx
126    
127  c             Set to freezing salterature if less  c             Set to freezing salterature if less
128                if (climsalt0(i,j,bi,bj) .lt. climsaltfreeze) then                if (climsalt0(i,j,k,bi,bj) .lt. climsaltfreeze) then
129                  climsalt0(i,j,bi,bj) = climsaltfreeze                    climsalt0(i,j,k,bi,bj) = climsaltfreeze
130                endif                endif
131                if (climsalt1(i,j,bi,bj) .lt. climsaltfreeze) then                if (climsalt1(i,j,k,bi,bj) .lt. climsaltfreeze) then
132                  climsalt1(i,j,bi,bj) = climsaltfreeze                    climsalt1(i,j,k,bi,bj) = climsaltfreeze
133                endif                endif
134    
135  c             Interpolate linearly onto the current time.  c             Interpolate linearly onto the current time.

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

  ViewVC Help
Powered by ViewVC 1.1.22