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

Annotation of /MITgcm/pkg/exf/exf_set_climsst.F

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


Revision 1.11 - (hide annotations) (download)
Thu Oct 9 04:19:19 2003 UTC (20 years, 8 months ago) by edhill
Branch: MAIN
CVS Tags: checkpoint51k_post, checkpoint51l_post, checkpoint52l_pre, checkpoint52e_pre, hrcube4, checkpoint52j_post, checkpoint51o_pre, checkpoint52e_post, checkpoint51n_pre, checkpoint52d_pre, checkpoint52j_pre, branch-netcdf, checkpoint51r_post, checkpoint52b_pre, checkpoint51i_post, checkpoint51l_pre, hrcube5, checkpoint51o_post, checkpoint51q_post, checkpoint52l_post, checkpoint52k_post, checkpoint52, checkpoint52d_post, checkpoint52a_post, checkpoint52b_post, checkpoint52f_post, checkpoint52c_post, ecco_c52_e35, checkpoint52a_pre, checkpoint51m_post, checkpoint51t_post, checkpoint52i_post, checkpoint51p_post, checkpoint51n_post, checkpoint52i_pre, checkpoint51u_post, checkpoint52h_pre, checkpoint52f_pre, hrcube_1, hrcube_2, hrcube_3, checkpoint51s_post
Branch point for: netcdf-sm0, branch-nonh, tg2-branch, checkpoint51n_branch
Changes since 1.10: +2 -2 lines
 o first check-in for the "branch-genmake2" merge
 o verification suite as run on shelley (gcc 3.2.2):

Wed Oct  8 23:42:29 EDT 2003
                T           S           U           V
G D M    c        m  s        m  s        m  s        m  s
E p a R  g  m  m  e  .  m  m  e  .  m  m  e  .  m  m  e  .
N n k u  2  i  a  a  d  i  a  a  d  i  a  a  d  i  a  a  d
2 d e n  d  n  x  n  .  n  x  n  .  n  x  n  .  n  x  n  .

OPTFILE=NONE

Y Y Y Y 13 16 16 16  0 16 16 16 16 16 16 16 16 13 12  0  0 pass  adjustment.128x64x1
Y Y Y Y 16 16 16 16  0 16 16 16 16 16 16  0  0 16 16  0  0 pass  adjustment.cs-32x32x1
Y Y Y Y 16 16 16 16  0 16 16 16 16 16 16 22  0 16 16 22  0 pass  adjust_nlfs.cs-32x32x1
Y Y Y Y -- 13 13 16 16 13 13 13 13 16 16 16 16 16 16 16 16 N/O   advect_cs
Y Y Y Y -- 22 16 16 16 16 16 16 13 16 16 16 16 16 16 16 16 N/O   advect_xy
Y Y Y Y -- 13 16 13 16 16 16 16 16 16 16 22 16 16 16 16 16 N/O   advect_xz
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 pass  aim.5l_cs
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 16 16 16 16 16 13 16 pass  aim.5l_Equatorial_Channel
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 13 16 16 13 13 16 pass  aim.5l_LatLon
Y Y Y Y 13 16 16 16 16 16 16 16 16 16 13 12 13 13 16 13 16 pass  exp0
Y Y Y Y 14 16 16 16 16 16 16 16 22 16 16 16 13 16 16 22 16 pass  exp1
Y Y Y Y 13 13 16 13 16 16 16 16 16 13 13 16 16 13 13 13 13 pass  exp2
Y Y Y Y 16 16 16 16 16 16 16 16 22 16 16 16 16 16 16 16 16 pass  exp4
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 22 16 16 16 22 16 pass  exp5
Y Y Y Y 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 16 pass  front_relax
Y Y Y Y 14 16 16 13 13 16 16 13 13 16 13 13 16 12 13 13 16 pass  global_ocean.90x40x15
Y Y Y Y 10 16 16 13 13 16 13 16 16 13 13 13 13 16 16 13 16 FAIL  global_ocean.cs32x15
Y Y Y Y  6 11 12 13 13 12 13 16 13  9  9  9  9 10  9  9 11 FAIL  global_ocean_pressure
Y Y Y Y 14 16 16 13 16 16 16 13 13 13 13 13 16 12 16 13 16 pass  global_with_exf
Y Y Y Y 14 16 16 16 16 16 16 16 16 11 13 22 13 16 16  9 16 pass  hs94.128x64x5
Y Y Y Y 13 16 16 16 16 16 16 16 16 11 16 16 16 13 16 22 13 pass  hs94.1x64x5
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 16 13 13 16 16 22 13 pass  hs94.cs-32x32x5
Y Y Y Y 10 10 16 13 13 16 16 16 22 16 13 13 13 13 13 22 13 FAIL  ideal_2D_oce
Y Y Y Y  8 16 16 16 16 16 16 16 16 13 13  8 16 16 16 16 16 FAIL  internal_wave
Y Y Y Y 14 16 16 16 16 16 16 16 16 13 13 22 13 13 13 22 16 pass  inverted_barometer
Y Y Y Y 12 16 16 16 16 16 16 16 16 16 13 12 13 13 13 13 13 FAIL  lab_sea
Y Y Y Y 11 16 16 16 16 16 16 16 13 13 13 12 13 16 13 12 13 FAIL  natl_box
Y Y Y Y 16 16 16 16 16 16 16 16 22 16 16 16 16 16 16 16 16 pass  plume_on_slope
Y Y Y Y 13 16 16 16 16 13 16 16 16 16 16 16 16 13 16 16 16 pass  solid-body.cs-32x32x1

1 edhill 1.11 c $Header: /u/u3/gcmpack/MITgcm/pkg/exf/exf_set_climsst.F,v 1.10.2.1 2003/10/02 18:30:07 adcroft Exp $
2 heimbach 1.1
3 edhill 1.11 #include "EXF_OPTIONS.h"
4 heimbach 1.1
5    
6     subroutine exf_set_climsst(
7 heimbach 1.3 O mycurrenttime
8 heimbach 1.1 I , mycurrentiter
9     I , mythid
10     & )
11    
12     c ==================================================================
13     c SUBROUTINE exf_set_climsst
14     c ==================================================================
15     c
16     c o Get the current climatological sea surface salinity field.
17     c started: Christian Eckert eckert@mit.edu 27-Aug-1999
18     c changed: Christian Eckert eckert@mit.edu 11-Jan-2000
19     c - Restructured the code in order to create a package
20     c for the MITgcmUV.
21     c Christian Eckert eckert@mit.edu 12-Feb-2000
22     c - Changed Routine names (package prefix: exf_)
23 heimbach 1.3 c changed: heimbach@mit.edu 08-Feb-2002
24 dimitri 1.5 c mods for pkg/seaice: menemenlis@jpl.nasa.gov 20-Dec-2002
25 heimbach 1.1 c
26     c ==================================================================
27     c SUBROUTINE exf_set_climsst
28     c ==================================================================
29    
30     implicit none
31    
32     #include "EEPARAMS.h"
33     #include "SIZE.h"
34     #include "GRID.h"
35    
36     #include "exf_param.h"
37     #include "exf_constants.h"
38     #include "exf_clim_param.h"
39 heimbach 1.3 #include "exf_clim_fields.h"
40 heimbach 1.1
41     c == routine arguments ==
42    
43     _RL mycurrenttime
44     integer mycurrentiter
45     integer mythid
46    
47     #ifdef ALLOW_CLIMSST_RELAXATION
48    
49     c == local variables ==
50    
51     logical first, changed
52     integer count0, count1
53     _RL fac
54 dimitri 1.9 integer bi, bj, i, j, interp_method
55 heimbach 1.1
56     c == end of interface ==
57    
58 dimitri 1.5 if ( climsstfile .NE. ' ' ) then
59    
60 heimbach 1.2 #ifdef ALLOW_CLIM_CYCLIC
61     c record numbers are assumed 1 to 12 corresponding to
62     c Jan. through Dec.
63 dimitri 1.5 call cal_GetMonthsRec(
64     O fac, first, changed,
65     O count0, count1,
66     I mycurrenttime, mycurrentiter, mythid
67     & )
68     #else
69 heimbach 1.1 c get record numbers and interpolation factor for climsst
70 dimitri 1.5 call exf_GetFFieldRec(
71     I climsststartdate, climsstperiod
72     O , fac, first, changed
73     O , count0, count1
74     I , mycurrenttime, mycurrentiter, mythid
75     & )
76 heimbach 1.2 #endif
77 heimbach 1.1
78 dimitri 1.5 if ( first ) then
79 dimitri 1.7 #ifdef USE_EXF_INTERPOLATION
80 dimitri 1.9 interp_method = 2
81 dimitri 1.8 call exf_interp(
82 dimitri 1.7 & climsstfile, exf_clim_iprec
83     & , climsst1, count0, xC, yC
84     & ,climsst_lon0,climsst_lon_inc
85     & ,climsst_lat0,climsst_lat_inc
86 dimitri 1.9 & ,climsst_nlon,climsst_nlat,interp_method,mythid )
87 dimitri 1.7 #else
88 dimitri 1.5 call mdsreadfield( climsstfile, exf_clim_iprec
89     & , exf_clim_yftype, 1
90     & , climsst1, count0, mythid
91     & )
92 dimitri 1.7 #endif
93 dimitri 1.5 if (exf_clim_yftype .eq. 'RL') then
94     call exf_filter_rl( climsst1, climsstmask, mythid )
95     else
96     call exf_filter_rs( climsst1, climsstmask, mythid )
97     end if
98     endif
99    
100     if (( first ) .or. ( changed )) then
101     call exf_SwapFFields( climsst0, climsst1, mythid )
102 dimitri 1.7
103     #ifdef USE_EXF_INTERPOLATION
104 dimitri 1.10 interp_method = 2
105 dimitri 1.8 call exf_interp(
106 dimitri 1.7 & climsstfile, exf_iprec
107     & , climsst1, count1, xC, yC
108     & ,climsst_lon0,climsst_lon_inc
109     & ,climsst_lat0,climsst_lat_inc
110 dimitri 1.9 & ,climsst_nlon,climsst_nlat,interp_method,mythid )
111 dimitri 1.7 #else
112 dimitri 1.5 call mdsreadfield( climsstfile, exf_clim_iprec
113     & , exf_clim_yftype, 1
114     & , climsst1, count1, mythid
115     & )
116 dimitri 1.7 #endif
117 dimitri 1.5 if (exf_clim_yftype .eq. 'RL') then
118     call exf_filter_rl( climsst1, climsstmask, mythid )
119     else
120     call exf_filter_rs( climsst1, climsstmask, mythid )
121     end if
122     endif
123 heimbach 1.1
124     c Loop over tiles.
125 dimitri 1.5 do bj = mybylo(mythid),mybyhi(mythid)
126     do bi = mybxlo(mythid),mybxhi(mythid)
127     do j = 1,sny
128     do i = 1,snx
129    
130     c Set to freezing temperature if less
131     if (climsst0(i,j,bi,bj) .lt. climtempfreeze) then
132     climsst0(i,j,bi,bj) = climtempfreeze
133     endif
134     if (climsst1(i,j,bi,bj) .lt. climtempfreeze) then
135     climsst1(i,j,bi,bj) = climtempfreeze
136     endif
137    
138     c Interpolate linearly onto the current time.
139     climsst(i,j,bi,bj) = exf_inscal_sst * (
140     & fac * climsst0(i,j,bi,bj) +
141     & (exf_one - fac) * climsst1(i,j,bi,bj) )
142 heimbach 1.1
143 dimitri 1.5 enddo
144     enddo
145 heimbach 1.1 enddo
146 dimitri 1.5 enddo
147    
148     endif
149 heimbach 1.1
150     #endif /* ALLOW_CLIMSST_RELAXATION */
151    
152     end
153    
154    
155     subroutine exf_init_climsst(
156     I mythid
157     & )
158    
159     c ==================================================================
160     c SUBROUTINE exf_init_climsst
161     c ==================================================================
162     c
163     c o
164     c
165     c started: Ralf.Giering@FastOpt.de 25-Mai-2000
166     c
167     c ==================================================================
168     c SUBROUTINE exf_init_climsst
169     c ==================================================================
170    
171     implicit none
172    
173     c == global variables ==
174    
175     #include "EEPARAMS.h"
176     #include "SIZE.h"
177    
178     #include "exf_fields.h"
179     #include "exf_param.h"
180     #include "exf_clim_param.h"
181     #include "exf_clim_fields.h"
182    
183     c == routine arguments ==
184    
185     integer mythid
186    
187     #ifdef ALLOW_CLIMSST_RELAXATION
188    
189     c == local variables ==
190    
191     integer bi, bj
192     integer i, j
193    
194     c == end of interface ==
195    
196     do bj = mybylo(mythid), mybyhi(mythid)
197     do bi = mybxlo(mythid), mybxhi(mythid)
198     do j = 1, sny
199     do i = 1, snx
200 heimbach 1.6 climsst (i,j,bi,bj) = climsstconst
201 heimbach 1.1 climsst0(i,j,bi,bj) = 0. _d 0
202     climsst1(i,j,bi,bj) = 0. _d 0
203     enddo
204     enddo
205     enddo
206     enddo
207    
208     #endif /* ALLOW_CLIMSSST_RELAXATION */
209    
210     end

  ViewVC Help
Powered by ViewVC 1.1.22