1 |
% $Header: /u/gcmpack/manual/part3/case_studies/rotating_tank/tank.tex,v 1.14 2006/04/08 01:50:50 edhill Exp $ |
2 |
% $Name: $ |
3 |
|
4 |
\bodytext{bgcolor="#FFFFFFFF"} |
5 |
|
6 |
%\begin{center} |
7 |
%{\Large \bf Using MITgcm to Simulate a Rotating Tank in Cylindrical |
8 |
%Coordinates} |
9 |
% |
10 |
%\vspace*{4mm} |
11 |
% |
12 |
%\vspace*{3mm} |
13 |
%{\large May 2001} |
14 |
%\end{center} |
15 |
|
16 |
\section{A Rotating Tank in Cylindrical Coordinates} |
17 |
\label{sect:eg-tank} |
18 |
\label{www:tutorials} |
19 |
\begin{rawhtml} |
20 |
<!-- CMIREDIR:eg-tank: --> |
21 |
\end{rawhtml} |
22 |
|
23 |
\subsection{Overview} |
24 |
\label{www:tutorials} |
25 |
|
26 |
This example configuration demonstrates using the MITgcm to simulate a |
27 |
laboratory demonstration using a differentially heated rotating |
28 |
annulus of water. The simulation is configured for a laboratory scale |
29 |
on a $3^{\circ}\times1\mathrm{cm}$ cyclindrical grid with twenty-nine |
30 |
vertical levels of 0.5cm each. This is a typical laboratory setup for |
31 |
illustration principles of GFD, as well as for a laboratory data |
32 |
assimilation project. The files for this experiment can be found in |
33 |
the verification directory under rotating\_tank. |
34 |
\\ |
35 |
|
36 |
example illustration from GFD lab here |
37 |
\\ |
38 |
|
39 |
|
40 |
|
41 |
|
42 |
|
43 |
\subsection{Equations Solved} |
44 |
\label{www:tutorials} |
45 |
|
46 |
|
47 |
\subsection{Discrete Numerical Configuration} |
48 |
\label{www:tutorials} |
49 |
|
50 |
The domain is discretised with a uniform cylindrical grid spacing in |
51 |
the horizontal set to $\Delta a=1$~cm and $\Delta \phi=3^{\circ}$, so |
52 |
that there are 120 grid cells in the azimuthal direction and |
53 |
thirty-one grid cells in the radial, representing a tank 62cm in |
54 |
diameter. The bathymetry file sets the depth=0 in the nine lowest |
55 |
radial rows to represent the central of the annulus. Vertically the |
56 |
model is configured with twenty-nine layers of uniform 0.5cm |
57 |
thickness. |
58 |
\\ |
59 |
something about heat flux |
60 |
|
61 |
\subsection{Code Configuration} |
62 |
\label{www:tutorials} |
63 |
\label{SEC:eg-baro-code_config} |
64 |
|
65 |
The model configuration for this experiment resides under the |
66 |
directory {\it verification/rotatingi\_tank/}. The experiment files |
67 |
\begin{itemize} |
68 |
\item {\it input/data} |
69 |
\item {\it input/data.pkg} |
70 |
\item {\it input/eedata}, |
71 |
\item {\it input/bathyPol.bin}, |
72 |
\item {\it input/thetaPol.bin}, |
73 |
\item {\it code/CPP\_EEOPTIONS.h} |
74 |
\item {\it code/CPP\_OPTIONS.h}, |
75 |
\item {\it code/SIZE.h}. |
76 |
\end{itemize} |
77 |
|
78 |
contain the code customizations and parameter settings for this |
79 |
experiments. Below we describe the customizations |
80 |
to these files associated with this experiment. |
81 |
|
82 |
\subsubsection{File {\it input/data}} |
83 |
\label{www:tutorials} |
84 |
|
85 |
This file, reproduced completely below, specifies the main parameters |
86 |
for the experiment. The parameters that are significant for this configuration |
87 |
are |
88 |
|
89 |
\begin{itemize} |
90 |
|
91 |
\item Lines 9-10, \begin{verbatim} |
92 |
viscAh=5.0E-6, |
93 |
viscAz=5.0E-6, |
94 |
\end{verbatim} |
95 |
|
96 |
|
97 |
These lines set the Laplacian friction coefficient in the horizontal |
98 |
and vertical, respectively. Note that they are several orders of |
99 |
magnitude smaller than the other examples due to the small scale of |
100 |
this example. |
101 |
|
102 |
\item Lines 13-16, \begin{verbatim} |
103 |
diffKhT=2.5E-6, |
104 |
diffKzT=2.5E-6, |
105 |
diffKhS=1.0E-6, |
106 |
diffKzS=1.0E-6, |
107 |
|
108 |
\end{verbatim} |
109 |
|
110 |
|
111 |
These lines set horizontal and vertical diffusion coefficients for |
112 |
temperature and salinity. Similarly to the friction coefficients, the |
113 |
values are a couple of orders of magnitude less than most |
114 |
configurations. |
115 |
|
116 |
|
117 |
\item Line 17, \begin{verbatim}f0=0.5 , \end{verbatim} this line sets the |
118 |
coriolis term, and represents a tank spinning at about 2.4 rpm. |
119 |
|
120 |
\item Lines 23 and 24 |
121 |
\begin{verbatim} |
122 |
rigidLid=.TRUE., |
123 |
implicitFreeSurface=.FALSE., |
124 |
\end{verbatim} |
125 |
|
126 |
These lines activate the rigid lid formulation of the surface |
127 |
pressure inverter and suppress the implicit free surface form |
128 |
of the pressure inverter. |
129 |
|
130 |
\item Line 40, |
131 |
\begin{verbatim} |
132 |
nIter=0, |
133 |
\end{verbatim} |
134 |
This line indicates that the experiment should start from $t=0$ and |
135 |
implicitly suppresses searching for checkpoint files associated with |
136 |
restarting an numerical integration from a previously saved state. |
137 |
Instead, the file thetaPol.bin will be loaded to initialized the |
138 |
temperature fields as indicated below, and other variables will be |
139 |
initialized to their defaults. |
140 |
|
141 |
|
142 |
\item Line 43, |
143 |
\begin{verbatim} |
144 |
deltaT=0.1, |
145 |
\end{verbatim} |
146 |
This line sets the integration timestep to $0.1s$. This is an |
147 |
unsually small value among the examples due to the small physical |
148 |
scale of the experiment. Using the ensemble Kalman filter to produce |
149 |
input fields can necessitate even shorter timesteps. |
150 |
|
151 |
\item Line 56, |
152 |
\begin{verbatim} |
153 |
usingCylindricalGrid=.TRUE., |
154 |
\end{verbatim} |
155 |
This line requests that the simulation be performed in a |
156 |
cylindrical coordinate system. |
157 |
|
158 |
\item Line 57, |
159 |
\begin{verbatim} |
160 |
dXspacing=3, |
161 |
\end{verbatim} |
162 |
This line sets the azimuthal grid spacing between each $x$-coordinate line |
163 |
in the discrete grid. The syntax indicates that the discrete grid |
164 |
should be comprised of $120$ grid lines each separated by $3^{\circ}$. |
165 |
|
166 |
|
167 |
\item Line 58, |
168 |
\begin{verbatim} |
169 |
dYspacing=0.01, |
170 |
\end{verbatim} |
171 |
|
172 |
This line sets the radial cylindrical grid spacing between each |
173 |
$a$-coordinate line in the discrete grid to $1cm$. |
174 |
|
175 |
\item Line 59, |
176 |
\begin{verbatim} |
177 |
delZ=29*0.005, |
178 |
\end{verbatim} |
179 |
|
180 |
This line sets the vertical grid spacing between each of 29 |
181 |
z-coordinate lines in the discrete grid to $0.005m$ ($5$~mm). |
182 |
|
183 |
\item Line 64, |
184 |
\begin{verbatim} |
185 |
bathyFile='bathyPol.bin', |
186 |
\end{verbatim} |
187 |
This line specifies the name of the file from which the domain |
188 |
``bathymetry'' (tank depth) is read. This file is a two-dimensional |
189 |
($a,\phi$) map of |
190 |
depths. This file is assumed to contain 64-bit binary numbers |
191 |
giving the depth of the model at each grid cell, ordered with the $\phi$ |
192 |
coordinate varying fastest. The points are ordered from low coordinate |
193 |
to high coordinate for both axes. The units and orientation of the |
194 |
depths in this file are the same as used in the MITgcm code. In this |
195 |
experiment, a depth of $0m$ indicates an area outside of the tank |
196 |
and a depth |
197 |
f $-0.145m$ indicates the tank itself. |
198 |
|
199 |
\item Line 65, |
200 |
\begin{verbatim} |
201 |
hydrogThetaFile='thetaPol.bin', |
202 |
\end{verbatim} |
203 |
This line specifies the name of the file from which the initial values |
204 |
of temperature |
205 |
are read. This file is a three-dimensional |
206 |
($x,y,z$) map and is enumerated and formatted in the same manner as the |
207 |
bathymetry file. |
208 |
|
209 |
\item Lines 66 and 67 |
210 |
\begin{verbatim} |
211 |
tCylIn = 0 |
212 |
tCylOut = 20 |
213 |
\end{verbatim} |
214 |
These line specify the temperatures in degrees Celsius of the interior |
215 |
and exterior walls of the tank -- typically taken to be icewater on |
216 |
the inside and room temperature on the outside. |
217 |
|
218 |
|
219 |
\end{itemize} |
220 |
|
221 |
\noindent Other lines in the file {\it input/data} are standard values |
222 |
that are described in the MITgcm Getting Started and MITgcm Parameters |
223 |
notes. |
224 |
|
225 |
\begin{small} |
226 |
\input{part3/case_studies/rotating_tank/input/data} |
227 |
\end{small} |
228 |
|
229 |
\subsubsection{File {\it input/data.pkg}} |
230 |
\label{www:tutorials} |
231 |
|
232 |
This file uses standard default values and does not contain |
233 |
customizations for this experiment. |
234 |
|
235 |
\subsubsection{File {\it input/eedata}} |
236 |
\label{www:tutorials} |
237 |
|
238 |
This file uses standard default values and does not contain |
239 |
customizations for this experiment. |
240 |
|
241 |
\subsubsection{File {\it input/thetaPol.bin}} |
242 |
\label{www:tutorials} |
243 |
|
244 |
The {\it input/thetaPol.bin} file specifies a three-dimensional ($x,y,z$) |
245 |
map of initial values of $\theta$ in degrees Celsius. This particular |
246 |
experiment is set to random values x around 20C to provide initial |
247 |
perturbations. |
248 |
|
249 |
\subsubsection{File {\it input/bathyPol.bin}} |
250 |
\label{www:tutorials} |
251 |
|
252 |
|
253 |
The {\it input/bathyPol.bin} file specifies a two-dimensional ($x,y$) |
254 |
map of depth values. For this experiment values are either |
255 |
$0m$ or {\bf -delZ}m, corresponding respectively to outside or inside of |
256 |
the tank. The file contains a raw binary stream of data that is enumerated |
257 |
in the same way as standard MITgcm two-dimensional, horizontal arrays. |
258 |
|
259 |
\subsubsection{File {\it code/SIZE.h}} |
260 |
\label{www:tutorials} |
261 |
|
262 |
Two lines are customized in this file for the current experiment |
263 |
|
264 |
\begin{itemize} |
265 |
|
266 |
\item Line 39, |
267 |
\begin{verbatim} sNx=120, \end{verbatim} this line sets |
268 |
the lateral domain extent in grid points for the |
269 |
axis aligned with the x-coordinate. |
270 |
|
271 |
\item Line 40, |
272 |
\begin{verbatim} sNy=31, \end{verbatim} this line sets |
273 |
the lateral domain extent in grid points for the |
274 |
axis aligned with the y-coordinate. |
275 |
|
276 |
\end{itemize} |
277 |
|
278 |
\begin{small} |
279 |
\input{part3/case_studies/rotating_tank/code/SIZE.h} |
280 |
\end{small} |
281 |
|
282 |
\subsubsection{File {\it code/CPP\_OPTIONS.h}} |
283 |
\label{www:tutorials} |
284 |
|
285 |
This file uses standard default values and does not contain |
286 |
customizations for this experiment. |
287 |
|
288 |
|
289 |
\subsubsection{File {\it code/CPP\_EEOPTIONS.h}} |
290 |
\label{www:tutorials} |
291 |
|
292 |
This file uses standard default values and does not contain |
293 |
customizations for this experiment. |
294 |
|