1 |
% $Header$ |
% $Header$ |
2 |
% $Name$ |
% $Name$ |
3 |
|
|
|
\section{Simulating a Rotating Tank in Cylindrical Coordinates} |
|
|
\label{www:tutorials} |
|
|
\label{sect:eg-tank} |
|
|
|
|
4 |
\bodytext{bgcolor="#FFFFFFFF"} |
\bodytext{bgcolor="#FFFFFFFF"} |
5 |
|
|
6 |
%\begin{center} |
%\begin{center} |
7 |
%{\Large \bf Simulating a Rotating Tank in Cylindrical Coordinates} |
%{\Large \bf Using MITgcm to Simulate a Rotating Tank in Cylindrical |
8 |
% |
%Coordinates} |
9 |
% |
% |
10 |
%\vspace*{4mm} |
%\vspace*{4mm} |
11 |
% |
% |
12 |
%\vspace*{3mm} |
%\vspace*{3mm} |
13 |
%{\large June 2004} |
%{\large May 2001} |
14 |
%\end{center} |
%\end{center} |
15 |
|
|
16 |
\subsection{Introduction} |
This is the first in a series of tutorials describing |
17 |
\label{www:tutorials} |
example MITgcm numerical experiments. The example experiments |
18 |
|
include both straightforward examples of idealized geophysical |
19 |
This section illustrates an example of MITgcm simulating a laboratory |
fluid simulations and more involved cases encompassing |
20 |
experiment on much smaller scales than those common to geophysical |
large scale modeling and |
21 |
fluid dynamics. |
automatic differentiation. Both hydrostatic and non-hydrostatic |
22 |
|
experiments are presented, as well as experiments employing |
23 |
|
Cartesian, spherical-polar and cube-sphere coordinate systems. |
24 |
|
These ``case study'' documents include information describing |
25 |
|
the experimental configuration and detailed information on how to |
26 |
|
configure the MITgcm code and input files for each experiment. |
27 |
|
|
28 |
\subsection{Overview} |
\section{A Rotating Tank in Cylindrical Coordinates} |
29 |
|
\label{sect:eg-tank} |
30 |
\label{www:tutorials} |
\label{www:tutorials} |
31 |
|
|
32 |
|
|
33 |
This example experiment demonstrates using the MITgcm to simulate |
This example experiment demonstrates using the MITgcm to simulate |
34 |
a laboratory experiment with a rotating tank of water with an ice |
a Barotropic, wind-forced, ocean gyre circulation. The experiment |
35 |
bucket in the center. The simulation is configured for a laboratory |
is a numerical rendition of the gyre circulation problem similar |
36 |
scale on a 3^{\circ} \times 20cm cyclindrical grid with twenty-nine vertical |
to the problems described analytically by Stommel in 1966 |
37 |
levels. |
\cite{Stommel66} and numerically in Holland et. al \cite{Holland75}. |
38 |
\\ |
|
39 |
|
In this experiment the model |
40 |
The model is forced with climatological wind stress data and surface |
is configured to represent a rectangular enclosed box of fluid, |
41 |
flux data from DaSilva \cite{DaSilva94}. Climatological data |
$1200 \times 1200 $~km in lateral extent. The fluid is $5$~km deep and is forced |
42 |
from Levitus \cite{Levitus94} is used to initialize the model hydrography. |
by a constant in time zonal wind stress, $\tau_x$, that varies sinusoidally |
43 |
Levitus seasonal climatology data is also used throughout the calculation |
in the ``north-south'' direction. Topologically the grid is Cartesian and |
44 |
to provide additional air-sea fluxes. |
the coriolis parameter $f$ is defined according to a mid-latitude beta-plane |
45 |
These fluxes are combined with the DaSilva climatological estimates of |
equation |
46 |
surface heat flux and fresh water, resulting in a mixed boundary |
|
47 |
condition of the style described in Haney \cite{Haney}. |
\begin{equation} |
48 |
Altogether, this yields the following forcing applied |
\label{EQ:eg-baro-fcori} |
49 |
in the model surface layer. |
f(y) = f_{0}+\beta y |
50 |
|
\end{equation} |
51 |
|
|
52 |
\noindent where ${\cal F}_{u}$, ${\cal F}_{v}$, ${\cal F}_{\theta}$, |
\noindent where $y$ is the distance along the ``north-south'' axis of the |
53 |
${\cal F}_{s}$ are the forcing terms in the zonal and meridional |
simulated domain. For this experiment $f_{0}$ is set to $10^{-4}s^{-1}$ in |
54 |
momentum and in the potential temperature and salinity |
(\ref{EQ:eg-baro-fcori}) and $\beta = 10^{-11}s^{-1}m^{-1}$. |
55 |
equations respectively. |
\\ |
56 |
The term $\Delta z_{s}$ represents the top ocean layer thickness in |
\\ |
57 |
meters. |
The sinusoidal wind-stress variations are defined according to |
58 |
It is used in conjunction with a reference density, $\rho_{0}$ |
|
59 |
(here set to $999.8\,{\rm kg\,m^{-3}}$), a |
\begin{equation} |
60 |
reference salinity, $S_{0}$ (here set to 35~ppt), |
\label{EQ:eg-baro-taux} |
61 |
and a specific heat capacity, $C_{p}$ (here set to |
\tau_x(y) = \tau_{0}\sin(\pi \frac{y}{L_y}) |
62 |
$4000~{\rm J}~^{\circ}{\rm C}^{-1}~{\rm kg}^{-1}$), to convert |
\end{equation} |
63 |
input dataset values into time tendencies of |
|
64 |
potential temperature (with units of $^{\circ}{\rm C}~{\rm s}^{-1}$), |
\noindent where $L_{y}$ is the lateral domain extent ($1200$~km) and |
65 |
salinity (with units ${\rm ppt}~s^{-1}$) and |
$\tau_0$ is set to $0.1N m^{-2}$. |
66 |
velocity (with units ${\rm m}~{\rm s}^{-2}$). |
\\ |
67 |
The externally supplied forcing fields used in this |
\\ |
68 |
experiment are $\tau_{x}$, $\tau_{y}$, $\theta^{\ast}$, $S^{\ast}$, |
Figure \ref{FIG:eg-baro-simulation_config} |
69 |
$\cal{Q}$ and $\cal{E}-\cal{P}-\cal{R}$. The wind stress fields ($\tau_x$, $\tau_y$) |
summarizes the configuration simulated. |
70 |
have units of ${\rm N}~{\rm m}^{-2}$. The temperature forcing fields |
|
71 |
($\theta^{\ast}$ and $Q$) have units of $^{\circ}{\rm C}$ and ${\rm W}~{\rm m}^{-2}$ |
%% === eh3 === |
72 |
respectively. The salinity forcing fields ($S^{\ast}$ and |
\begin{figure} |
73 |
$\cal{E}-\cal{P}-\cal{R}$) have units of ${\rm ppt}$ and ${\rm m}~{\rm s}^{-1}$ |
%% \begin{center} |
74 |
respectively. |
%% \resizebox{7.5in}{5.5in}{ |
75 |
\\ |
%% \includegraphics*[0.2in,0.7in][10.5in,10.5in] |
76 |
|
%% {part3/case_studies/barotropic_gyre/simulation_config.eps} } |
77 |
|
%% \end{center} |
78 |
Figures (\ref{FIG:sim_config_tclim}-\ref{FIG:sim_config_empmr}) show the |
\centerline{ |
79 |
relaxation temperature ($\theta^{\ast}$) and salinity ($S^{\ast}$) fields, |
\scalefig{.95} |
80 |
the wind stress components ($\tau_x$ and $\tau_y$), the heat flux ($Q$) |
\epsfbox{part3/case_studies/barotropic_gyre/simulation_config.eps} |
81 |
and the net fresh water flux (${\cal E} - {\cal P} - {\cal R}$) used |
} |
82 |
in equations \ref{EQ:eg-hs-global_forcing_fu}-\ref{EQ:eg-hs-global_forcing_fs}. The figures |
\caption{Schematic of simulation domain and wind-stress forcing function |
83 |
also indicate the lateral extent and coastline used in the experiment. |
for barotropic gyre numerical experiment. The domain is enclosed bu solid |
84 |
Figure ({\ref{FIG:model_bathymetry}) shows the depth contours of the model |
walls at $x=$~0,1200km and at $y=$~0,1200km.} |
85 |
domain. |
\label{FIG:eg-baro-simulation_config} |
86 |
|
\end{figure} |
87 |
|
|
88 |
\subsection{Discrete Numerical Configuration} |
\subsection{Equations Solved} |
89 |
\label{www:tutorials} |
\label{www:tutorials} |
90 |
|
The model is configured in hydrostatic form. The implicit free surface form of the |
91 |
|
pressure equation described in Marshall et. al \cite{marshall:97a} is |
92 |
The model is configured in hydrostatic form. The domain is discretised with |
employed. |
93 |
a uniform grid spacing in latitude and longitude on the sphere |
A horizontal Laplacian operator $\nabla_{h}^2$ provides viscous |
94 |
$\Delta \phi=\Delta \lambda=4^{\circ}$, so |
dissipation. The wind-stress momentum input is added to the momentum equation |
95 |
that there are ninety grid cells in the zonal and forty in the |
for the ``zonal flow'', $u$. Other terms in the model |
96 |
meridional direction. The internal model coordinate variables |
are explicitly switched off for this experiment configuration (see section |
97 |
$x$ and $y$ are initialized according to |
\ref{SEC:code_config} ), yielding an active set of equations solved in this |
98 |
\begin{eqnarray} |
configuration as follows |
|
x=r\cos(\phi),~\Delta x & = &r\cos(\Delta \phi) \\ |
|
|
y=r\lambda,~\Delta x &= &r\Delta \lambda |
|
|
\end{eqnarray} |
|
|
|
|
|
Arctic polar regions are not |
|
|
included in this experiment. Meridionally the model extends from |
|
|
$80^{\circ}{\rm S}$ to $80^{\circ}{\rm N}$. |
|
|
Vertically the model is configured with twenty layers with the |
|
|
following thicknesses |
|
|
$\Delta z_{1} = 50\,{\rm m},\, |
|
|
\Delta z_{2} = 50\,{\rm m},\, |
|
|
\Delta z_{3} = 55\,{\rm m},\, |
|
|
\Delta z_{4} = 60\,{\rm m},\, |
|
|
\Delta z_{5} = 65\,{\rm m},\, |
|
|
$ |
|
|
$ |
|
|
\Delta z_{6}~=~70\,{\rm m},\, |
|
|
\Delta z_{7}~=~80\,{\rm m},\, |
|
|
\Delta z_{8}~=95\,{\rm m},\, |
|
|
\Delta z_{9}=120\,{\rm m},\, |
|
|
\Delta z_{10}=155\,{\rm m},\, |
|
|
$ |
|
|
$ |
|
|
\Delta z_{11}=200\,{\rm m},\, |
|
|
\Delta z_{12}=260\,{\rm m},\, |
|
|
\Delta z_{13}=320\,{\rm m},\, |
|
|
\Delta z_{14}=400\,{\rm m},\, |
|
|
\Delta z_{15}=480\,{\rm m},\, |
|
|
$ |
|
|
$ |
|
|
\Delta z_{16}=570\,{\rm m},\, |
|
|
\Delta z_{17}=655\,{\rm m},\, |
|
|
\Delta z_{18}=725\,{\rm m},\, |
|
|
\Delta z_{19}=775\,{\rm m},\, |
|
|
\Delta z_{20}=815\,{\rm m} |
|
|
$ (here the numeric subscript indicates the model level index number, ${\tt k}$). |
|
|
The implicit free surface form of the pressure equation described in Marshall et. al |
|
|
\cite{marshall:97a} is employed. A Laplacian operator, $\nabla^2$, provides viscous |
|
|
dissipation. Thermal and haline diffusion is also represented by a Laplacian operator. |
|
|
|
|
|
Wind-stress forcing is added to the momentum equations for both |
|
|
the zonal flow, $u$ and the meridional flow $v$, according to equations |
|
|
(\ref{EQ:eg-hs-global_forcing_fu}) and (\ref{EQ:eg-hs-global_forcing_fv}). |
|
|
Thermodynamic forcing inputs are added to the equations for |
|
|
potential temperature, $\theta$, and salinity, $S$, according to equations |
|
|
(\ref{EQ:eg-hs-global_forcing_ft}) and (\ref{EQ:eg-hs-global_forcing_fs}). |
|
|
This produces a set of equations solved in this configuration as follows: |
|
99 |
|
|
100 |
\begin{eqnarray} |
\begin{eqnarray} |
101 |
\label{EQ:eg-hs-model_equations} |
\label{EQ:eg-baro-model_equations} |
102 |
\frac{Du}{Dt} - fv + |
\frac{Du}{Dt} - fv + |
103 |
\frac{1}{\rho}\frac{\partial p^{'}}{\partial x} - |
g\frac{\partial \eta}{\partial x} - |
104 |
\nabla_{h}\cdot A_{h}\nabla_{h}u - |
A_{h}\nabla_{h}^2u |
105 |
\frac{\partial}{\partial z}A_{z}\frac{\partial u}{\partial z} |
& = & |
106 |
& = & |
\frac{\tau_{x}}{\rho_{0}\Delta z} |
|
\begin{cases} |
|
|
{\cal F}_u & \text{(surface)} \\ |
|
|
0 & \text{(interior)} |
|
|
\end{cases} |
|
107 |
\\ |
\\ |
108 |
\frac{Dv}{Dt} + fu + |
\frac{Dv}{Dt} + fu + g\frac{\partial \eta}{\partial y} - |
109 |
\frac{1}{\rho}\frac{\partial p^{'}}{\partial y} - |
A_{h}\nabla_{h}^2v |
|
\nabla_{h}\cdot A_{h}\nabla_{h}v - |
|
|
\frac{\partial}{\partial z}A_{z}\frac{\partial v}{\partial z} |
|
110 |
& = & |
& = & |
111 |
\begin{cases} |
0 |
|
{\cal F}_v & \text{(surface)} \\ |
|
|
0 & \text{(interior)} |
|
|
\end{cases} |
|
112 |
\\ |
\\ |
113 |
\frac{\partial \eta}{\partial t} + \nabla_{h}\cdot \vec{u} |
\frac{\partial \eta}{\partial t} + \nabla_{h}\cdot \vec{u} |
114 |
&=& |
&=& |
115 |
0 |
0 |
|
\\ |
|
|
\frac{D\theta}{Dt} - |
|
|
\nabla_{h}\cdot K_{h}\nabla_{h}\theta |
|
|
- \frac{\partial}{\partial z}\Gamma(K_{z})\frac{\partial\theta}{\partial z} |
|
|
& = & |
|
|
\begin{cases} |
|
|
{\cal F}_\theta & \text{(surface)} \\ |
|
|
0 & \text{(interior)} |
|
|
\end{cases} |
|
|
\\ |
|
|
\frac{D s}{Dt} - |
|
|
\nabla_{h}\cdot K_{h}\nabla_{h}s |
|
|
- \frac{\partial}{\partial z}\Gamma(K_{z})\frac{\partial s}{\partial z} |
|
|
& = & |
|
|
\begin{cases} |
|
|
{\cal F}_s & \text{(surface)} \\ |
|
|
0 & \text{(interior)} |
|
|
\end{cases} |
|
|
\\ |
|
|
g\rho_{0} \eta + \int^{0}_{-z}\rho^{'} dz & = & p^{'} |
|
116 |
\end{eqnarray} |
\end{eqnarray} |
117 |
|
|
118 |
\noindent where $u=\frac{Dx}{Dt}=r \cos(\phi)\frac{D \lambda}{Dt}$ and |
\noindent where $u$ and $v$ and the $x$ and $y$ components of the |
119 |
$v=\frac{Dy}{Dt}=r \frac{D \phi}{Dt}$ |
flow vector $\vec{u}$. |
|
are the zonal and meridional components of the |
|
|
flow vector, $\vec{u}$, on the sphere. As described in |
|
|
MITgcm Numerical Solution Procedure \ref{chap:discretization}, the time |
|
|
evolution of potential temperature, $\theta$, equation is solved prognostically. |
|
|
The total pressure, $p$, is diagnosed by summing pressure due to surface |
|
|
elevation $\eta$ and the hydrostatic pressure. |
|
120 |
\\ |
\\ |
121 |
|
|
122 |
|
|
123 |
|
\subsection{Discrete Numerical Configuration} |
124 |
|
\label{www:tutorials} |
125 |
|
|
126 |
|
The domain is discretised with |
127 |
|
a uniform grid spacing in the horizontal set to |
128 |
|
$\Delta x=\Delta y=20$~km, so |
129 |
|
that there are sixty grid cells in the $x$ and $y$ directions. Vertically the |
130 |
|
model is configured with a single layer with depth, $\Delta z$, of $5000$~m. |
131 |
|
|
132 |
\subsubsection{Numerical Stability Criteria} |
\subsubsection{Numerical Stability Criteria} |
133 |
\label{www:tutorials} |
\label{www:tutorials} |
134 |
|
|
135 |
The Laplacian dissipation coefficient, $A_{h}$, is set to $5 \times 10^5 m s^{-1}$. |
The Laplacian dissipation coefficient, $A_{h}$, is set to $400 m s^{-1}$. |
136 |
This value is chosen to yield a Munk layer width \cite{adcroft:95}, |
This value is chosen to yield a Munk layer width \cite{adcroft:95}, |
137 |
|
|
138 |
\begin{eqnarray} |
\begin{eqnarray} |
139 |
\label{EQ:eg-hs-munk_layer} |
\label{EQ:eg-baro-munk_layer} |
140 |
M_{w} = \pi ( \frac { A_{h} }{ \beta } )^{\frac{1}{3}} |
M_{w} = \pi ( \frac { A_{h} }{ \beta } )^{\frac{1}{3}} |
141 |
\end{eqnarray} |
\end{eqnarray} |
142 |
|
|
143 |
\noindent of $\approx 600$km. This is greater than the model |
\noindent of $\approx 100$km. This is greater than the model |
144 |
resolution in low-latitudes, $\Delta x \approx 400{\rm km}$, ensuring that the frictional |
resolution $\Delta x$, ensuring that the frictional boundary |
145 |
boundary layer is adequately resolved. |
layer is well resolved. |
146 |
\\ |
\\ |
147 |
|
|
148 |
\noindent The model is stepped forward with a |
\noindent The model is stepped forward with a |
149 |
time step $\delta t_{\theta}=30~{\rm hours}$ for thermodynamic variables and |
time step $\delta t=1200$secs. With this time step the stability |
|
$\delta t_{v}=40~{\rm minutes}$ for momentum terms. With this time step, the stability |
|
150 |
parameter to the horizontal Laplacian friction \cite{adcroft:95} |
parameter to the horizontal Laplacian friction \cite{adcroft:95} |
|
\begin{eqnarray} |
|
|
\label{EQ:eg-hs-laplacian_stability} |
|
|
S_{l} = 4 \frac{A_{h} \delta t_{v}}{{\Delta x}^2} |
|
|
\end{eqnarray} |
|
151 |
|
|
|
\noindent evaluates to 0.16 at a latitude of $\phi=80^{\circ}$, which is below the |
|
|
0.3 upper limit for stability. The zonal grid spacing $\Delta x$ is smallest at |
|
|
$\phi=80^{\circ}$ where $\Delta x=r\cos(\phi)\Delta \phi\approx 77{\rm km}$. |
|
|
\\ |
|
152 |
|
|
153 |
\noindent The vertical dissipation coefficient, $A_{z}$, is set to |
|
|
$1\times10^{-3} {\rm m}^2{\rm s}^{-1}$. The associated stability limit |
|
154 |
\begin{eqnarray} |
\begin{eqnarray} |
155 |
\label{EQ:eg-hs-laplacian_stability_z} |
\label{EQ:eg-baro-laplacian_stability} |
156 |
S_{l} = 4 \frac{A_{z} \delta t_{v}}{{\Delta z}^2} |
S_{l} = 4 \frac{A_{h} \delta t}{{\Delta x}^2} |
157 |
\end{eqnarray} |
\end{eqnarray} |
158 |
|
|
159 |
\noindent evaluates to $0.015$ for the smallest model |
\noindent evaluates to 0.012, which is well below the 0.3 upper limit |
160 |
level spacing ($\Delta z_{1}=50{\rm m}$) which is again well below |
for stability. |
|
the upper stability limit. |
|
161 |
\\ |
\\ |
162 |
|
|
163 |
The values of the horizontal ($K_{h}$) and vertical ($K_{z}$) diffusion coefficients |
\noindent The numerical stability for inertial oscillations |
|
for both temperature and salinity are set to $1 \times 10^{3}~{\rm m}^{2}{\rm s}^{-1}$ |
|
|
and $3 \times 10^{-5}~{\rm m}^{2}{\rm s}^{-1}$ respectively. The stability limit |
|
|
related to $K_{h}$ will be at $\phi=80^{\circ}$ where $\Delta x \approx 77 {\rm km}$. |
|
|
Here the stability parameter |
|
|
\begin{eqnarray} |
|
|
\label{EQ:eg-hs-laplacian_stability_xtheta} |
|
|
S_{l} = \frac{4 K_{h} \delta t_{\theta}}{{\Delta x}^2} |
|
|
\end{eqnarray} |
|
|
evaluates to $0.07$, well below the stability limit of $S_{l} \approx 0.5$. The |
|
|
stability parameter related to $K_{z}$ |
|
|
\begin{eqnarray} |
|
|
\label{EQ:eg-hs-laplacian_stability_ztheta} |
|
|
S_{l} = \frac{4 K_{z} \delta t_{\theta}}{{\Delta z}^2} |
|
|
\end{eqnarray} |
|
|
evaluates to $0.005$ for $\min(\Delta z)=50{\rm m}$, well below the stability limit |
|
|
of $S_{l} \approx 0.5$. |
|
|
\\ |
|
|
|
|
|
\noindent The numerical stability for inertial oscillations |
|
164 |
\cite{adcroft:95} |
\cite{adcroft:95} |
165 |
|
|
166 |
\begin{eqnarray} |
\begin{eqnarray} |
167 |
\label{EQ:eg-hs-inertial_stability} |
\label{EQ:eg-baro-inertial_stability} |
168 |
S_{i} = f^{2} {\delta t_v}^2 |
S_{i} = f^{2} {\delta t}^2 |
169 |
\end{eqnarray} |
\end{eqnarray} |
170 |
|
|
171 |
\noindent evaluates to $0.24$ for $f=2\omega\sin(80^{\circ})=1.43\times10^{-4}~{\rm s}^{-1}$, which is close to |
\noindent evaluates to $0.0144$, which is well below the $0.5$ upper |
172 |
the $S_{i} < 1$ upper limit for stability. |
limit for stability. |
173 |
\\ |
\\ |
174 |
|
|
175 |
\noindent The advective CFL \cite{adcroft:95} for a extreme maximum |
\noindent The advective CFL \cite{adcroft:95} for an extreme maximum |
176 |
horizontal flow |
horizontal flow speed of $ | \vec{u} | = 2 ms^{-1}$ |
|
speed of $ | \vec{u} | = 2 ms^{-1}$ |
|
177 |
|
|
178 |
\begin{eqnarray} |
\begin{eqnarray} |
179 |
\label{EQ:eg-hs-cfl_stability} |
\label{EQ:eg-baro-cfl_stability} |
180 |
S_{a} = \frac{| \vec{u} | \delta t_{v}}{ \Delta x} |
S_{a} = \frac{| \vec{u} | \delta t}{ \Delta x} |
181 |
\end{eqnarray} |
\end{eqnarray} |
182 |
|
|
183 |
\noindent evaluates to $6 \times 10^{-2}$. This is well below the stability |
\noindent evaluates to 0.12. This is approaching the stability limit |
184 |
limit of 0.5. |
of 0.5 and limits $\delta t$ to $1200s$. |
|
\\ |
|
|
|
|
|
\noindent The stability parameter for internal gravity waves propagating |
|
|
with a maximum speed of $c_{g}=10~{\rm ms}^{-1}$ |
|
|
\cite{adcroft:95} |
|
185 |
|
|
186 |
\begin{eqnarray} |
\subsection{Code Configuration} |
|
\label{EQ:eg-hs-gfl_stability} |
|
|
S_{c} = \frac{c_{g} \delta t_{v}}{ \Delta x} |
|
|
\end{eqnarray} |
|
|
|
|
|
\noindent evaluates to $3 \times 10^{-1}$. This is close to the linear |
|
|
stability limit of 0.5. |
|
|
|
|
|
\subsection{Experiment Configuration} |
|
187 |
\label{www:tutorials} |
\label{www:tutorials} |
188 |
\label{SEC:eg-hs_examp_exp_config} |
\label{SEC:eg-baro-code_config} |
189 |
|
|
190 |
The model configuration for this experiment resides under the |
The model configuration for this experiment resides under the |
191 |
directory {\it verification/hs94.128x64x5}. The experiment files |
directory {\it verification/exp0/}. The experiment files |
192 |
\begin{itemize} |
\begin{itemize} |
193 |
\item {\it input/data} |
\item {\it input/data} |
194 |
\item {\it input/data.pkg} |
\item {\it input/data.pkg} |
195 |
\item {\it input/eedata}, |
\item {\it input/eedata}, |
196 |
\item {\it input/windx.bin}, |
\item {\it input/windx.sin\_y}, |
197 |
\item {\it input/windy.bin}, |
\item {\it input/topog.box}, |
|
\item {\it input/salt.bin}, |
|
|
\item {\it input/theta.bin}, |
|
|
\item {\it input/SSS.bin}, |
|
|
\item {\it input/SST.bin}, |
|
|
\item {\it input/topog.bin}, |
|
198 |
\item {\it code/CPP\_EEOPTIONS.h} |
\item {\it code/CPP\_EEOPTIONS.h} |
199 |
\item {\it code/CPP\_OPTIONS.h}, |
\item {\it code/CPP\_OPTIONS.h}, |
200 |
\item {\it code/SIZE.h}. |
\item {\it code/SIZE.h}. |
201 |
\end{itemize} |
\end{itemize} |
202 |
contain the code customizations and parameter settings for these |
contain the code customizations and parameter settings for this |
203 |
experiments. Below we describe the customizations |
experiments. Below we describe the customizations |
204 |
to these files associated with this experiment. |
to these files associated with this experiment. |
205 |
|
|
212 |
|
|
213 |
\begin{itemize} |
\begin{itemize} |
214 |
|
|
215 |
\item Lines 7-10 and 11-14 |
\item Line 7, \begin{verbatim} viscAh=4.E2, \end{verbatim} this line sets |
216 |
\begin{verbatim} tRef= 16.0 , 15.2 , 14.5 , 13.9 , 13.3 , \end{verbatim} |
the Laplacian friction coefficient to $400 m^2s^{-1}$ |
217 |
$\cdots$ \\ |
\item Line 10, \begin{verbatim} beta=1.E-11, \end{verbatim} this line sets |
218 |
set reference values for potential |
$\beta$ (the gradient of the coriolis parameter, $f$) to $10^{-11} s^{-1}m^{-1}$ |
219 |
temperature and salinity at each model level in units of $^{\circ}$C and |
|
220 |
${\rm ppt}$. The entries are ordered from surface to depth. |
\item Lines 15 and 16 |
221 |
Density is calculated from anomalies at each level evaluated |
\begin{verbatim} |
222 |
with respect to the reference values set here.\\ |
rigidLid=.FALSE., |
223 |
\fbox{ |
implicitFreeSurface=.TRUE., |
224 |
\begin{minipage}{5.0in} |
\end{verbatim} |
225 |
{\it S/R INI\_THETA}({\it ini\_theta.F}) |
these lines suppress the rigid lid formulation of the surface |
226 |
\end{minipage} |
pressure inverter and activate the implicit free surface form |
227 |
} |
of the pressure inverter. |
|
|
|
|
|
|
|
\item Line 15, |
|
|
\begin{verbatim} viscAz=1.E-3, \end{verbatim} |
|
|
this line sets the vertical Laplacian dissipation coefficient to |
|
|
$1 \times 10^{-3} {\rm m^{2}s^{-1}}$. Boundary conditions |
|
|
for this operator are specified later. This variable is copied into |
|
|
model general vertical coordinate variable {\bf viscAr}. |
|
|
|
|
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R CALC\_DIFFUSIVITY}({\it calc\_diffusivity.F}) |
|
|
\end{minipage} |
|
|
} |
|
|
|
|
|
\item Line 16, |
|
|
\begin{verbatim} |
|
|
viscAh=5.E5, |
|
|
\end{verbatim} |
|
|
this line sets the horizontal Laplacian frictional dissipation coefficient to |
|
|
$5 \times 10^{5} {\rm m^{2}s^{-1}}$. Boundary conditions |
|
|
for this operator are specified later. |
|
|
|
|
|
\item Lines 17, |
|
|
\begin{verbatim} |
|
|
no_slip_sides=.FALSE. |
|
|
\end{verbatim} |
|
|
this line selects a free-slip lateral boundary condition for |
|
|
the horizontal Laplacian friction operator |
|
|
e.g. $\frac{\partial u}{\partial y}$=0 along boundaries in $y$ and |
|
|
$\frac{\partial v}{\partial x}$=0 along boundaries in $x$. |
|
|
|
|
|
\item Lines 9, |
|
|
\begin{verbatim} |
|
|
no_slip_bottom=.TRUE. |
|
|
\end{verbatim} |
|
|
this line selects a no-slip boundary condition for bottom |
|
|
boundary condition in the vertical Laplacian friction operator |
|
|
e.g. $u=v=0$ at $z=-H$, where $H$ is the local depth of the domain. |
|
|
|
|
|
\item Line 19, |
|
|
\begin{verbatim} |
|
|
diffKhT=1.E3, |
|
|
\end{verbatim} |
|
|
this line sets the horizontal diffusion coefficient for temperature |
|
|
to $1000\,{\rm m^{2}s^{-1}}$. The boundary condition on this |
|
|
operator is $\frac{\partial}{\partial x}=\frac{\partial}{\partial y}=0$ on |
|
|
all boundaries. |
|
|
|
|
|
\item Line 20, |
|
|
\begin{verbatim} |
|
|
diffKzT=3.E-5, |
|
|
\end{verbatim} |
|
|
this line sets the vertical diffusion coefficient for temperature |
|
|
to $3 \times 10^{-5}\,{\rm m^{2}s^{-1}}$. The boundary |
|
|
condition on this operator is $\frac{\partial}{\partial z}=0$ at both |
|
|
the upper and lower boundaries. |
|
|
|
|
|
\item Line 21, |
|
|
\begin{verbatim} |
|
|
diffKhS=1.E3, |
|
|
\end{verbatim} |
|
|
this line sets the horizontal diffusion coefficient for salinity |
|
|
to $1000\,{\rm m^{2}s^{-1}}$. The boundary condition on this |
|
|
operator is $\frac{\partial}{\partial x}=\frac{\partial}{\partial y}=0$ on |
|
|
all boundaries. |
|
|
|
|
|
\item Line 22, |
|
|
\begin{verbatim} |
|
|
diffKzS=3.E-5, |
|
|
\end{verbatim} |
|
|
this line sets the vertical diffusion coefficient for salinity |
|
|
to $3 \times 10^{-5}\,{\rm m^{2}s^{-1}}$. The boundary |
|
|
condition on this operator is $\frac{\partial}{\partial z}=0$ at both |
|
|
the upper and lower boundaries. |
|
|
|
|
|
\item Lines 23-26 |
|
|
\begin{verbatim} |
|
|
beta=1.E-11, |
|
|
\end{verbatim} |
|
|
\vspace{-5mm}$\cdots$\\ |
|
|
These settings do not apply for this experiment. |
|
228 |
|
|
229 |
\item Line 27, |
\item Line 27, |
230 |
\begin{verbatim} |
\begin{verbatim} |
231 |
gravity=9.81, |
startTime=0, |
232 |
\end{verbatim} |
\end{verbatim} |
233 |
Sets the gravitational acceleration coefficient to $9.81{\rm m}{\rm s}^{-1}$.\\ |
this line indicates that the experiment should start from $t=0$ |
234 |
\fbox{ |
and implicitly suppresses searching for checkpoint files associated |
235 |
\begin{minipage}{5.0in} |
with restarting an numerical integration from a previously saved state. |
|
{\it S/R CALC\_PHI\_HYD}~({\it calc\_phi\_hyd.F})\\ |
|
|
{\it S/R INI\_CG2D}~({\it ini\_cg2d.F})\\ |
|
|
{\it S/R INI\_CG3D}~({\it ini\_cg3d.F})\\ |
|
|
{\it S/R INI\_PARMS}~({\it ini\_parms.F})\\ |
|
|
{\it S/R SOLVE\_FOR\_PRESSURE}~({\it solve\_for\_pressure.F}) |
|
|
\end{minipage} |
|
|
} |
|
236 |
|
|
237 |
|
\item Line 29, |
|
\item Line 28-29, |
|
238 |
\begin{verbatim} |
\begin{verbatim} |
239 |
rigidLid=.FALSE., |
endTime=12000, |
|
implicitFreeSurface=.TRUE., |
|
240 |
\end{verbatim} |
\end{verbatim} |
241 |
Selects the barotropic pressure equation to be the implicit free surface |
this line indicates that the experiment should start finish at $t=12000s$. |
242 |
formulation. |
A restart file will be written at this time that will enable the |
243 |
|
simulation to be continued from this point. |
244 |
|
|
245 |
\item Line 30, |
\item Line 30, |
246 |
\begin{verbatim} |
\begin{verbatim} |
247 |
eosType='POLY3', |
deltaTmom=1200, |
248 |
\end{verbatim} |
\end{verbatim} |
249 |
Selects the third order polynomial form of the equation of state.\\ |
This line sets the momentum equation timestep to $1200s$. |
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R FIND\_RHO}~({\it find\_rho.F})\\ |
|
|
{\it S/R FIND\_ALPHA}~({\it find\_alpha.F}) |
|
|
\end{minipage} |
|
|
} |
|
250 |
|
|
251 |
\item Line 31, |
\item Line 39, |
252 |
\begin{verbatim} |
\begin{verbatim} |
253 |
readBinaryPrec=32, |
usingCartesianGrid=.TRUE., |
254 |
\end{verbatim} |
\end{verbatim} |
255 |
Sets format for reading binary input datasets holding model fields to |
This line requests that the simulation be performed in a |
256 |
use 32-bit representation for floating-point numbers.\\ |
Cartesian coordinate system. |
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R READ\_WRITE\_FLD}~({\it read\_write\_fld.F})\\ |
|
|
{\it S/R READ\_WRITE\_REC}~({\it read\_write\_rec.F}) |
|
|
\end{minipage} |
|
|
} |
|
257 |
|
|
258 |
\item Line 36, |
\item Line 41, |
259 |
\begin{verbatim} |
\begin{verbatim} |
260 |
cg2dMaxIters=1000, |
delX=60*20E3, |
261 |
\end{verbatim} |
\end{verbatim} |
262 |
Sets maximum number of iterations the two-dimensional, conjugate |
This line sets the horizontal grid spacing between each x-coordinate line |
263 |
gradient solver will use, {\bf irrespective of convergence |
in the discrete grid. The syntax indicates that the discrete grid |
264 |
criteria being met}.\\ |
should be comprise of $60$ grid lines each separated by $20 \times 10^{3}m$ |
265 |
\fbox{ |
($20$~km). |
|
\begin{minipage}{5.0in} |
|
|
{\it S/R CG2D}~({\it cg2d.F}) |
|
|
\end{minipage} |
|
|
} |
|
|
|
|
|
\item Line 37, |
|
|
\begin{verbatim} |
|
|
cg2dTargetResidual=1.E-13, |
|
|
\end{verbatim} |
|
|
Sets the tolerance which the two-dimensional, conjugate |
|
|
gradient solver will use to test for convergence in equation |
|
|
\ref{EQ:eg-hs-congrad_2d_resid} to $1 \times 10^{-13}$. |
|
|
Solver will iterate until |
|
|
tolerance falls below this value or until the maximum number of |
|
|
solver iterations is reached.\\ |
|
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R CG2D}~({\it cg2d.F}) |
|
|
\end{minipage} |
|
|
} |
|
266 |
|
|
267 |
\item Line 42, |
\item Line 42, |
268 |
\begin{verbatim} |
\begin{verbatim} |
269 |
startTime=0, |
delY=60*20E3, |
270 |
\end{verbatim} |
\end{verbatim} |
271 |
Sets the starting time for the model internal time counter. |
This line sets the horizontal grid spacing between each y-coordinate line |
272 |
When set to non-zero this option implicitly requests a |
in the discrete grid to $20 \times 10^{3}m$ ($20$~km). |
|
checkpoint file be read for initial state. |
|
|
By default the checkpoint file is named according to |
|
|
the integer number of time steps in the {\bf startTime} value. |
|
|
The internal time counter works in seconds. |
|
273 |
|
|
274 |
\item Line 43, |
\item Line 43, |
275 |
\begin{verbatim} |
\begin{verbatim} |
276 |
endTime=2808000., |
delZ=5000, |
|
\end{verbatim} |
|
|
Sets the time (in seconds) at which this simulation will terminate. |
|
|
At the end of a simulation a checkpoint file is automatically |
|
|
written so that a numerical experiment can consist of multiple |
|
|
stages. |
|
|
|
|
|
\item Line 44, |
|
|
\begin{verbatim} |
|
|
#endTime=62208000000, |
|
277 |
\end{verbatim} |
\end{verbatim} |
278 |
A commented out setting for endTime for a 2000 year simulation. |
This line sets the vertical grid spacing between each z-coordinate line |
279 |
|
in the discrete grid to $5000m$ ($5$~km). |
|
\item Line 45, |
|
|
\begin{verbatim} |
|
|
deltaTmom=2400.0, |
|
|
\end{verbatim} |
|
|
Sets the timestep $\delta t_{v}$ used in the momentum equations to |
|
|
$20~{\rm mins}$. |
|
|
See section \ref{SEC:mom_time_stepping}. |
|
|
|
|
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R TIMESTEP}({\it timestep.F}) |
|
|
\end{minipage} |
|
|
} |
|
280 |
|
|
281 |
\item Line 46, |
\item Line 46, |
282 |
\begin{verbatim} |
\begin{verbatim} |
|
tauCD=321428., |
|
|
\end{verbatim} |
|
|
Sets the D-grid to C-grid coupling time scale $\tau_{CD}$ used in the momentum equations. |
|
|
See section \ref{SEC:cd_scheme}. |
|
|
|
|
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R INI\_PARMS}({\it ini\_parms.F})\\ |
|
|
{\it S/R CALC\_MOM\_RHS}({\it calc\_mom\_rhs.F}) |
|
|
\end{minipage} |
|
|
} |
|
|
|
|
|
\item Line 47, |
|
|
\begin{verbatim} |
|
|
deltaTtracer=108000., |
|
|
\end{verbatim} |
|
|
Sets the default timestep, $\delta t_{\theta}$, for tracer equations to |
|
|
$30~{\rm hours}$. |
|
|
See section \ref{SEC:tracer_time_stepping}. |
|
|
|
|
|
\fbox{ |
|
|
\begin{minipage}{5.0in} |
|
|
{\it S/R TIMESTEP\_TRACER}({\it timestep\_tracer.F}) |
|
|
\end{minipage} |
|
|
} |
|
|
|
|
|
\item Line 47, |
|
|
\begin{verbatim} |
|
283 |
bathyFile='topog.box' |
bathyFile='topog.box' |
284 |
\end{verbatim} |
\end{verbatim} |
285 |
This line specifies the name of the file from which the domain |
This line specifies the name of the file from which the domain |
290 |
to high coordinate for both axes. The units and orientation of the |
to high coordinate for both axes. The units and orientation of the |
291 |
depths in this file are the same as used in the MITgcm code. In this |
depths in this file are the same as used in the MITgcm code. In this |
292 |
experiment, a depth of $0m$ indicates a solid wall and a depth |
experiment, a depth of $0m$ indicates a solid wall and a depth |
293 |
of $-2000m$ indicates open ocean. The matlab program |
of $-5000m$ indicates open ocean. The matlab program |
294 |
{\it input/gendata.m} shows an example of how to generate a |
{\it input/gendata.m} shows an example of how to generate a |
295 |
bathymetry file. |
bathymetry file. |
296 |
|
|
297 |
|
|
298 |
\item Line 50, |
\item Line 49, |
299 |
\begin{verbatim} |
\begin{verbatim} |
300 |
zonalWindFile='windx.sin_y' |
zonalWindFile='windx.sin_y' |
301 |
\end{verbatim} |
\end{verbatim} |
303 |
surface wind stress is read. This file is also a two-dimensional |
surface wind stress is read. This file is also a two-dimensional |
304 |
($x,y$) map and is enumerated and formatted in the same manner as the |
($x,y$) map and is enumerated and formatted in the same manner as the |
305 |
bathymetry file. The matlab program {\it input/gendata.m} includes example |
bathymetry file. The matlab program {\it input/gendata.m} includes example |
306 |
code to generate a valid |
code to generate a valid {\bf zonalWindFile} file. |
|
{\bf zonalWindFile} |
|
|
file. |
|
307 |
|
|
308 |
\end{itemize} |
\end{itemize} |
309 |
|
|
312 |
notes. |
notes. |
313 |
|
|
314 |
\begin{small} |
\begin{small} |
315 |
\input{part3/case_studies/climatalogical_ogcm/input/data} |
\input{part3/case_studies/barotropic_gyre/input/data} |
316 |
\end{small} |
\end{small} |
317 |
|
|
318 |
\subsubsection{File {\it input/data.pkg}} |
\subsubsection{File {\it input/data.pkg}} |
319 |
\label{www:tutorials} |
\label{www:tutorials} |
320 |
|
|
321 |
This file uses standard default values and does not contain |
This file uses standard default values and does not contain |
322 |
customisations for this experiment. |
customizations for this experiment. |
323 |
|
|
324 |
\subsubsection{File {\it input/eedata}} |
\subsubsection{File {\it input/eedata}} |
325 |
\label{www:tutorials} |
\label{www:tutorials} |
326 |
|
|
327 |
This file uses standard default values and does not contain |
This file uses standard default values and does not contain |
328 |
customisations for this experiment. |
customizations for this experiment. |
329 |
|
|
330 |
\subsubsection{File {\it input/windx.sin\_y}} |
\subsubsection{File {\it input/windx.sin\_y}} |
331 |
\label{www:tutorials} |
\label{www:tutorials} |
344 |
|
|
345 |
The {\it input/topog.box} file specifies a two-dimensional ($x,y$) |
The {\it input/topog.box} file specifies a two-dimensional ($x,y$) |
346 |
map of depth values. For this experiment values are either |
map of depth values. For this experiment values are either |
347 |
$0m$ or $-2000\,{\rm m}$, corresponding respectively to a wall or to deep |
$0m$ or {\bf -delZ}m, corresponding respectively to a wall or to deep |
348 |
ocean. The file contains a raw binary stream of data that is enumerated |
ocean. The file contains a raw binary stream of data that is enumerated |
349 |
in the same way as standard MITgcm two-dimensional, horizontal arrays. |
in the same way as standard MITgcm two-dimensional, horizontal arrays. |
350 |
The included matlab program {\it input/gendata.m} gives a complete |
The included matlab program {\it input/gendata.m} gives a complete |
367 |
the lateral domain extent in grid points for the |
the lateral domain extent in grid points for the |
368 |
axis aligned with the y-coordinate. |
axis aligned with the y-coordinate. |
369 |
|
|
|
\item Line 49, |
|
|
\begin{verbatim} Nr=4, \end{verbatim} this line sets |
|
|
the vertical domain extent in grid points. |
|
|
|
|
370 |
\end{itemize} |
\end{itemize} |
371 |
|
|
372 |
\begin{small} |
\begin{small} |
373 |
\input{part3/case_studies/climatalogical_ogcm/code/SIZE.h} |
\input{part3/case_studies/barotropic_gyre/code/SIZE.h} |
374 |
\end{small} |
\end{small} |
375 |
|
|
376 |
\subsubsection{File {\it code/CPP\_OPTIONS.h}} |
\subsubsection{File {\it code/CPP\_OPTIONS.h}} |
377 |
\label{www:tutorials} |
\label{www:tutorials} |
378 |
|
|
379 |
This file uses standard default values and does not contain |
This file uses standard default values and does not contain |
380 |
customisations for this experiment. |
customizations for this experiment. |
381 |
|
|
382 |
|
|
383 |
\subsubsection{File {\it code/CPP\_EEOPTIONS.h}} |
\subsubsection{File {\it code/CPP\_EEOPTIONS.h}} |
384 |
\label{www:tutorials} |
\label{www:tutorials} |
385 |
|
|
386 |
This file uses standard default values and does not contain |
This file uses standard default values and does not contain |
387 |
customisations for this experiment. |
customizations for this experiment. |
388 |
|
|
|
\subsubsection{Other Files } |
|
|
\label{www:tutorials} |
|
|
|
|
|
Other files relevant to this experiment are |
|
|
\begin{itemize} |
|
|
\item {\it model/src/ini\_cori.F}. This file initializes the model |
|
|
coriolis variables {\bf fCorU}. |
|
|
\item {\it model/src/ini\_spherical\_polar\_grid.F} |
|
|
\item {\it model/src/ini\_parms.F}, |
|
|
\item {\it input/windx.sin\_y}, |
|
|
\end{itemize} |
|
|
contain the code customisations and parameter settings for this |
|
|
experiments. Below we describe the customisations |
|
|
to these files associated with this experiment. |
|