/[MITgcm]/manual/s_getstarted/text/getting_started.tex
ViewVC logotype

Diff of /manual/s_getstarted/text/getting_started.tex

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

revision 1.8 by cnh, Mon Oct 22 11:55:47 2001 UTC revision 1.16 by edhill, Thu Jan 29 03:02:33 2004 UTC
# Line 18  you are ready to try implementing the co Line 18  you are ready to try implementing the co
18  \section{Where to find information}  \section{Where to find information}
19  \label{sect:whereToFindInfo}  \label{sect:whereToFindInfo}
20    
21  A web site is maintained for release 1 (Sealion) of MITgcm:  A web site is maintained for release 2 (``Pelican'') of MITgcm:
22    \begin{rawhtml} <A href=http://mitgcm.org/pelican/ target="idontexist"> \end{rawhtml}
23  \begin{verbatim}  \begin{verbatim}
24  http://mitgcm.org/sealion  http://mitgcm.org/pelican
25  \end{verbatim}  \end{verbatim}
26    \begin{rawhtml} </A> \end{rawhtml}
27  Here you will find an on-line version of this document, a  Here you will find an on-line version of this document, a
28  ``browsable'' copy of the code and a searchable database of the model  ``browsable'' copy of the code and a searchable database of the model
29  and site, as well as links for downloading the model and  and site, as well as links for downloading the model and
30  documentation, to data-sources and other related sites.  documentation, to data-sources, and other related sites.
31    
32  There is also a support news group for the model that you can email at  There is also a web-archived support mailing list for the model that
33  \texttt{support@mitgcm.org} or browse at:  you can email at \texttt{MITgcm-support@mitgcm.org} or browse at:
34    \begin{rawhtml} <A href=http://mitgcm.org/mailman/listinfo/mitgcm-support/ target="idontexist"> \end{rawhtml}
35  \begin{verbatim}  \begin{verbatim}
36  news://mitgcm.org/mitgcm.support  http://mitgcm.org/mailman/listinfo/mitgcm-support/
37    http://mitgcm.org/pipermail/mitgcm-support/
38  \end{verbatim}  \end{verbatim}
39  A mail to the email list will reach all the developers and be archived  \begin{rawhtml} </A> \end{rawhtml}
40  on the newsgroup. A users email list will be established at some time  Essentially all of the MITgcm web pages can be searched using a
41  in the future.  popular web crawler such as Google or through our own search facility:
42    \begin{rawhtml} <A href=http://mitgcm.org/mailman/htdig/ target="idontexist"> \end{rawhtml}
43    \begin{verbatim}
44    http://mitgcm.org/htdig/
45    \end{verbatim}
46    \begin{rawhtml} </A> \end{rawhtml}
47    %%% http://www.google.com/search?q=hydrostatic+site%3Amitgcm.org
48    
49    
50    
51  \section{Obtaining the code}  \section{Obtaining the code}
52  \label{sect:obtainingCode}  \label{sect:obtainingCode}
53    
54  MITgcm can be downloaded from our system by following  MITgcm can be downloaded from our system by following
55  the instructions below. As a courtesy we ask that you send e-mail to us at  the instructions below. As a courtesy we ask that you send e-mail to us at
56  \begin{rawhtml} <A href=mailto:support@mitgcm.org> \end{rawhtml}  \begin{rawhtml} <A href=mailto:MITgcm-support@mitgcm.org> \end{rawhtml}
57  support@mitgcm.org  MITgcm-support@mitgcm.org
58  \begin{rawhtml} </A> \end{rawhtml}  \begin{rawhtml} </A> \end{rawhtml}
59  to enable us to keep track of who's using the model and in what application.  to enable us to keep track of who's using the model and in what application.
60  You can download the model two ways:  You can download the model two ways:
61    
62  \begin{enumerate}  \begin{enumerate}
63  \item Using CVS software. CVS is a freely available source code managment  \item Using CVS software. CVS is a freely available source code management
64  tool. To use CVS you need to have the software installed. Many systems  tool. To use CVS you need to have the software installed. Many systems
65  come with CVS pre-installed, otherwise good places to look for  come with CVS pre-installed, otherwise good places to look for
66  the software for a particular platform are  the software for a particular platform are
# Line 72  provides an efficient and elegant way of Line 84  provides an efficient and elegant way of
84  track of your changes. If CVS is not available on your machine, you can also  track of your changes. If CVS is not available on your machine, you can also
85  download a tar file.  download a tar file.
86    
87  Before you can use CVS, the following environment variable has to be set in  Before you can use CVS, the following environment variable(s) should
88  your .cshrc or .tcshrc:  be set within your shell.  For a csh or tcsh shell, put the following
89    \begin{verbatim}
90    % setenv CVSROOT :pserver:cvsanon@mitgcm.org:/u/gcmpack
91    \end{verbatim}
92    in your .cshrc or .tcshrc file.  For bash or sh shells, put:
93  \begin{verbatim}  \begin{verbatim}
94  % setenv CVSROOT :pserver:cvsanon@mitgcm.org:/u/u0/gcmpack  % export CVSROOT=':pserver:cvsanon@mitgcm.org:/u/gcmpack'
95  \end{verbatim}  \end{verbatim}
96    in your .profile or .bashrc file.
97    
98  To start using CVS, register with the MITgcm CVS server using command:  
99    To get MITgcm through CVS, first register with the MITgcm CVS server
100    using command:
101  \begin{verbatim}  \begin{verbatim}
102  % cvs login ( CVS password: cvsanon )  % cvs login ( CVS password: cvsanon )
103  \end{verbatim}  \end{verbatim}
104  You only need to do ``cvs login'' once.  You only need to do a ``cvs login'' once.
105    
106  To obtain the sources for release1 type:  To obtain the latest sources type:
107    \begin{verbatim}
108    % cvs co MITgcm
109    \end{verbatim}
110    or to get a specific release type:
111    \begin{verbatim}
112    % cvs co -P -r checkpoint52i_post  MITgcm
113    \end{verbatim}
114    The MITgcm web site contains further directions concerning the source
115    code and CVS.  It also contains a web interface to our CVS archive so
116    that one may easily view the state of files, revisions, and other
117    development milestones:
118    \begin{rawhtml} <A href=http://mitgcm.org/download target="idontexist"> \end{rawhtml}
119  \begin{verbatim}  \begin{verbatim}
120  % cvs co -d directory -P -r release1 MITgcmUV  http://mitgcm.org/source\_code.html
121  \end{verbatim}  \end{verbatim}
122    \begin{rawhtml} </A> \end{rawhtml}
123    
124    
125  This creates a directory called \textit{directory}. If \textit{directory}  The checkout process creates a directory called \textit{MITgcm}. If
126  exists this command updates your code based on the repository. Each  the directory \textit{MITgcm} exists this command updates your code
127  directory in the source tree contains a directory \textit{CVS}. This  based on the repository. Each directory in the source tree contains a
128  information is required by CVS to keep track of your file versions with  directory \textit{CVS}. This information is required by CVS to keep
129  respect to the repository. Don't edit the files in \textit{CVS}!  track of your file versions with respect to the repository. Don't edit
130  You can also use CVS to download code updates.  More extensive  the files in \textit{CVS}!  You can also use CVS to download code
131  information on using CVS for maintaining MITgcm code can be found  updates.  More extensive information on using CVS for maintaining
132    MITgcm code can be found
133  \begin{rawhtml} <A href=http://mitgcm.org/usingcvstoget.html target="idontexist"> \end{rawhtml}  \begin{rawhtml} <A href=http://mitgcm.org/usingcvstoget.html target="idontexist"> \end{rawhtml}
134  here  here
135  \begin{rawhtml} </A> \end{rawhtml}  \begin{rawhtml} </A> \end{rawhtml}
# Line 106  here Line 140  here
140  \label{sect:conventionalDownload}  \label{sect:conventionalDownload}
141    
142  If you do not have CVS on your system, you can download the model as a  If you do not have CVS on your system, you can download the model as a
143  tar file from the reference web site at:  tar file from the web site at:
144  \begin{rawhtml} <A href=http://mitgcm.org/download target="idontexist"> \end{rawhtml}  \begin{rawhtml} <A href=http://mitgcm.org/download target="idontexist"> \end{rawhtml}
145  \begin{verbatim}  \begin{verbatim}
146  http://mitgcm.org/download/  http://mitgcm.org/download/
# Line 114  http://mitgcm.org/download/ Line 148  http://mitgcm.org/download/
148  \begin{rawhtml} </A> \end{rawhtml}  \begin{rawhtml} </A> \end{rawhtml}
149  The tar file still contains CVS information which we urge you not to  The tar file still contains CVS information which we urge you not to
150  delete; even if you do not use CVS yourself the information can help  delete; even if you do not use CVS yourself the information can help
151  us if you should need to send us your copy of the code.  us if you should need to send us your copy of the code.  If a recent
152    tar file does not exist, then please contact the developers through
153    the MITgcm-support list.
154    
155    \paragraph*{Upgrading from an earlier version}
156    
157    If you already have an earlier version of the code you can ``upgrade''
158    your copy instead of downloading the entire repository again. First,
159    ``cd'' (change directory) to the top of your working copy:
160    \begin{verbatim}
161    % cd MITgcm
162    \end{verbatim}
163    and then issue the cvs update command such as:
164    \begin{verbatim}
165    % cvs -q update -r checkpoint52i_post -d -P
166    \end{verbatim}
167    This will update the ``tag'' to ``checkpoint52i\_post'', add any new
168    directories (-d) and remove any empty directories (-P). The -q option
169    means be quiet which will reduce the number of messages you'll see in
170    the terminal. If you have modified the code prior to upgrading, CVS
171    will try to merge your changes with the upgrades. If there is a
172    conflict between your modifications and the upgrade, it will report
173    that file with a ``C'' in front, e.g.:
174    \begin{verbatim}
175    C model/src/ini_parms.F
176    \end{verbatim}
177    If the list of conflicts scrolled off the screen, you can re-issue the
178    cvs update command and it will report the conflicts. Conflicts are
179    indicated in the code by the delimites ``$<<<<<<<$'', ``======='' and
180    ``$>>>>>>>$''. For example,
181    \begin{verbatim}
182    <<<<<<< ini_parms.F
183         & bottomDragLinear,myOwnBottomDragCoefficient,
184    =======
185         & bottomDragLinear,bottomDragQuadratic,
186    >>>>>>> 1.18
187    \end{verbatim}
188    means that you added ``myOwnBottomDragCoefficient'' to a namelist at
189    the same time and place that we added ``bottomDragQuadratic''. You
190    need to resolve this conflict and in this case the line should be
191    changed to:
192    \begin{verbatim}
193         & bottomDragLinear,bottomDragQuadratic,myOwnBottomDragCoefficient,
194    \end{verbatim}
195    and the lines with the delimiters ($<<<<<<$,======,$>>>>>>$) be deleted.
196    Unless you are making modifications which exactly parallel
197    developments we make, these types of conflicts should be rare.
198    
199    \paragraph*{Upgrading to the current pre-release version}
200    
201    We don't make a ``release'' for every little patch and bug fix in
202    order to keep the frequency of upgrades to a minimum. However, if you
203    have run into a problem for which ``we have already fixed in the
204    latest code'' and we haven't made a ``tag'' or ``release'' since that
205    patch then you'll need to get the latest code:
206    \begin{verbatim}
207    % cvs -q update -A -d -P
208    \end{verbatim}
209    Unlike, the ``check-out'' and ``update'' procedures above, there is no
210    ``tag'' or release name. The -A tells CVS to upgrade to the
211    very latest version. As a rule, we don't recommend this since you
212    might upgrade while we are in the processes of checking in the code so
213    that you may only have part of a patch. Using this method of updating
214    also means we can't tell what version of the code you are working
215    with. So please be sure you understand what you're doing.
216    
217  \section{Model and directory structure}  \section{Model and directory structure}
218    
219  The ``numerical'' model is contained within a execution environment support  The ``numerical'' model is contained within a execution environment
220  wrapper. This wrapper is designed to provide a general framework for  support wrapper. This wrapper is designed to provide a general
221  grid-point models. MITgcmUV is a specific numerical model that uses the  framework for grid-point models. MITgcmUV is a specific numerical
222  framework. Under this structure the model is split into execution  model that uses the framework. Under this structure the model is split
223  environment support code and conventional numerical model code. The  into execution environment support code and conventional numerical
224  execution environment support code is held under the \textit{eesupp}  model code. The execution environment support code is held under the
225  directory. The grid point model code is held under the \textit{model}  \textit{eesupp} directory. The grid point model code is held under the
226  directory. Code execution actually starts in the \textit{eesupp} routines  \textit{model} directory. Code execution actually starts in the
227  and not in the \textit{model} routines. For this reason the top-level  \textit{eesupp} routines and not in the \textit{model} routines. For
228    this reason the top-level
229  \textit{MAIN.F} is in the \textit{eesupp/src} directory. In general,  \textit{MAIN.F} is in the \textit{eesupp/src} directory. In general,
230  end-users should not need to worry about this level. The top-level routine  end-users should not need to worry about this level. The top-level routine
231  for the numerical part of the code is in \textit{model/src/THE\_MODEL\_MAIN.F%  for the numerical part of the code is in \textit{model/src/THE\_MODEL\_MAIN.F%
# Line 139  directory in which to compile the code. Line 238  directory in which to compile the code.
238    
239  \item \textit{diags}: contains the code relative to time-averaged  \item \textit{diags}: contains the code relative to time-averaged
240  diagnostics. It is subdivided into two subdirectories \textit{inc} and  diagnostics. It is subdivided into two subdirectories \textit{inc} and
241  \textit{src} that contain include files (*.\textit{h} files) and fortran  \textit{src} that contain include files (*.\textit{h} files) and Fortran
242  subroutines (*.\textit{F} files), respectively.  subroutines (*.\textit{F} files), respectively.
243    
244  \item \textit{doc}: contains brief documentation notes.  \item \textit{doc}: contains brief documentation notes.
# Line 160  relative to the atmospheric intermediate Line 259  relative to the atmospheric intermediate
259  in detail in section 3.  in detail in section 3.
260    
261  \item \textit{tools}: this directory contains various useful tools. For  \item \textit{tools}: this directory contains various useful tools. For
262  example, \textit{genmake} is a script written in csh (C-shell) that should  example, \textit{genmake2} is a script written in csh (C-shell) that should
263  be used to generate your makefile. The directory \textit{adjoint} contains  be used to generate your makefile. The directory \textit{adjoint} contains
264  the makefile specific to the Tangent linear and Adjoint Compiler (TAMC) that  the makefile specific to the Tangent linear and Adjoint Compiler (TAMC) that
265  generates the adjoint code. The latter is described in details in part V.  generates the adjoint code. The latter is described in details in part V.
# Line 180  section \ref{sect:modelExamples}. Line 279  section \ref{sect:modelExamples}.
279  \section{Example experiments}  \section{Example experiments}
280  \label{sect:modelExamples}  \label{sect:modelExamples}
281    
282  The MITgcm distribution comes with a set of twenty-four pre-configured  %% a set of twenty-four pre-configured numerical experiments
283  numerical experiments. Some of these examples experiments are tests of  
284  individual parts of the model code, but many are fully fledged numerical  The MITgcm distribution comes with more than a dozen pre-configured
285  simulations. A few of the examples are used for tutorial documentation  numerical experiments. Some of these example experiments are tests of
286  in sections \ref{sec:eg-baro} - \ref{sec:eg-global}. The other examples  individual parts of the model code, but many are fully fledged
287  follow the same general structure as the tutorial examples. However,  numerical simulations. A few of the examples are used for tutorial
288  they only include brief instructions in a text file called {\it README}.  documentation in sections \ref{sect:eg-baro} - \ref{sect:eg-global}.
289  The examples are located in subdirectories under  The other examples follow the same general structure as the tutorial
290  the directory \textit{verification}. Each  examples. However, they only include brief instructions in a text file
291  example is briefly described below.  called {\it README}.  The examples are located in subdirectories under
292    the directory \textit{verification}. Each example is briefly described
293    below.
294    
295  \subsection{Full list of model examples}  \subsection{Full list of model examples}
296    
297  \begin{enumerate}  \begin{enumerate}
298  \item \textit{exp0} - single layer, ocean double gyre (barotropic with  \item \textit{exp0} - single layer, ocean double gyre (barotropic with
299  free-surface). This experiment is described in detail in section    free-surface). This experiment is described in detail in section
300  \ref{sec:eg-baro}.    \ref{sect:eg-baro}.
   
 \item \textit{exp1} - Four layer, ocean double gyre. This experiment is described in detail in section  
 \ref{sec:eg-baroc}.  
301    
302    \item \textit{exp1} - Four layer, ocean double gyre. This experiment
303      is described in detail in section \ref{sect:eg-baroc}.
304      
305  \item \textit{exp2} - 4x4 degree global ocean simulation with steady  \item \textit{exp2} - 4x4 degree global ocean simulation with steady
306  climatological forcing. This experiment is described in detail in section    climatological forcing. This experiment is described in detail in
307  \ref{sec:eg-global}.    section \ref{sect:eg-global}.
308      
309  \item \textit{exp4} - Flow over a Gaussian bump in open-water or channel  \item \textit{exp4} - Flow over a Gaussian bump in open-water or
310  with open boundaries.    channel with open boundaries.
311      
312  \item \textit{exp5} - Inhomogenously forced ocean convection in a doubly  \item \textit{exp5} - Inhomogenously forced ocean convection in a
313  periodic box.    doubly periodic box.
314    
315  \item \textit{front\_relax} - Relaxation of an ocean thermal front (test for  \item \textit{front\_relax} - Relaxation of an ocean thermal front (test for
316  Gent/McWilliams scheme). 2D (Y-Z).  Gent/McWilliams scheme). 2D (Y-Z).
317    
318  \item \textit{internal wave} - Ocean internal wave forced by open boundary  \item \textit{internal wave} - Ocean internal wave forced by open
319  conditions.    boundary conditions.
320      
321  \item \textit{natl\_box} - Eastern subtropical North Atlantic with KPP  \item \textit{natl\_box} - Eastern subtropical North Atlantic with KPP
322  scheme; 1 month integration    scheme; 1 month integration
323      
324  \item \textit{hs94.1x64x5} - Zonal averaged atmosphere using Held and Suarez  \item \textit{hs94.1x64x5} - Zonal averaged atmosphere using Held and
325  '94 forcing.    Suarez '94 forcing.
326      
327  \item \textit{hs94.128x64x5} - 3D atmosphere dynamics using Held and Suarez  \item \textit{hs94.128x64x5} - 3D atmosphere dynamics using Held and
328  '94 forcing.    Suarez '94 forcing.
329      
330  \item \textit{hs94.cs-32x32x5} - 3D atmosphere dynamics using Held and  \item \textit{hs94.cs-32x32x5} - 3D atmosphere dynamics using Held and
331  Suarez '94 forcing on the cubed sphere.    Suarez '94 forcing on the cubed sphere.
332      
333  \item \textit{aim.5l\_zon-ave} - Intermediate Atmospheric physics. Global  \item \textit{aim.5l\_zon-ave} - Intermediate Atmospheric physics.
334  Zonal Mean configuration, 1x64x5 resolution.    Global Zonal Mean configuration, 1x64x5 resolution.
335      
336  \item \textit{aim.5l\_XZ\_Equatorial\_Slice} - Intermediate Atmospheric  \item \textit{aim.5l\_XZ\_Equatorial\_Slice} - Intermediate
337  physics, equatorial Slice configuration.    Atmospheric physics, equatorial Slice configuration.  2D (X-Z).
338  2D (X-Z).    
   
339  \item \textit{aim.5l\_Equatorial\_Channel} - Intermediate Atmospheric  \item \textit{aim.5l\_Equatorial\_Channel} - Intermediate Atmospheric
340  physics. 3D Equatorial Channel configuration.    physics. 3D Equatorial Channel configuration.
341      
342  \item \textit{aim.5l\_LatLon} - Intermediate Atmospheric physics.  \item \textit{aim.5l\_LatLon} - Intermediate Atmospheric physics.
343  Global configuration, on latitude longitude grid with 128x64x5 grid points    Global configuration, on latitude longitude grid with 128x64x5 grid
344  ($2.8^\circ{\rm degree}$ resolution).    points ($2.8^\circ{\rm degree}$ resolution).
345      
346  \item \textit{adjustment.128x64x1} Barotropic adjustment  \item \textit{adjustment.128x64x1} Barotropic adjustment problem on
347  problem on latitude longitude grid with 128x64 grid points ($2.8^\circ{\rm degree}$ resolution).    latitude longitude grid with 128x64 grid points ($2.8^\circ{\rm
348        degree}$ resolution).
349  \item \textit{adjustment.cs-32x32x1}    
350  Barotropic adjustment  \item \textit{adjustment.cs-32x32x1} Barotropic adjustment problem on
351  problem on cube sphere grid with 32x32 points per face ( roughly    cube sphere grid with 32x32 points per face ( roughly $2.8^\circ{\rm
352  $2.8^\circ{\rm degree}$ resolution).      degree}$ resolution).
353      
354  \item \textit{advect\_cs} Two-dimensional passive advection test on  \item \textit{advect\_cs} Two-dimensional passive advection test on
355  cube sphere grid.    cube sphere grid.
356      
357  \item \textit{advect\_xy} Two-dimensional (horizontal plane) passive advection  \item \textit{advect\_xy} Two-dimensional (horizontal plane) passive
358  test on cartesian grid.    advection test on Cartesian grid.
359      
360  \item \textit{advect\_yz} Two-dimensional (vertical plane) passive advection test on cartesian grid.  \item \textit{advect\_yz} Two-dimensional (vertical plane) passive
361      advection test on Cartesian grid.
362  \item \textit{carbon} Simple passive tracer experiment. Includes derivative    
363  calculation. Described in detail in section \ref{sec:eg-carbon-ad}.  \item \textit{carbon} Simple passive tracer experiment. Includes
364      derivative calculation. Described in detail in section
365      \ref{sect:eg-carbon-ad}.
366    
367  \item \textit{flt\_example} Example of using float package.  \item \textit{flt\_example} Example of using float package.
368      
369  \item \textit{global\_ocean.90x40x15} Global circulation with  \item \textit{global\_ocean.90x40x15} Global circulation with GM, flux
370  GM, flux boundary conditions and poles.    boundary conditions and poles.
371    
372  \item \textit{solid-body.cs-32x32x1} Solid body rotation test for cube sphere  \item \textit{global\_ocean\_pressure} Global circulation in pressure
373  grid.    coordinate (non-Boussinesq ocean model). Described in detail in
374      section \ref{sect:eg-globalpressure}.
375      
376    \item \textit{solid-body.cs-32x32x1} Solid body rotation test for cube
377      sphere grid.
378    
379  \end{enumerate}  \end{enumerate}
380    
# Line 278  Each example directory has the following Line 384  Each example directory has the following
384    
385  \begin{itemize}  \begin{itemize}
386  \item \textit{code}: contains the code particular to the example. At a  \item \textit{code}: contains the code particular to the example. At a
387  minimum, this directory includes the following files:    minimum, this directory includes the following files:
388    
389  \begin{itemize}    \begin{itemize}
390  \item \textit{code/CPP\_EEOPTIONS.h}: declares CPP keys relative to the    \item \textit{code/CPP\_EEOPTIONS.h}: declares CPP keys relative to
391  ``execution environment'' part of the code. The default version is located      the ``execution environment'' part of the code. The default
392  in \textit{eesupp/inc}.      version is located in \textit{eesupp/inc}.
393      
394  \item \textit{code/CPP\_OPTIONS.h}: declares CPP keys relative to the    \item \textit{code/CPP\_OPTIONS.h}: declares CPP keys relative to
395  ``numerical model'' part of the code. The default version is located in      the ``numerical model'' part of the code. The default version is
396  \textit{model/inc}.      located in \textit{model/inc}.
397      
398  \item \textit{code/SIZE.h}: declares size of underlying computational grid.    \item \textit{code/SIZE.h}: declares size of underlying
399  The default version is located in \textit{model/inc}.      computational grid.  The default version is located in
400  \end{itemize}      \textit{model/inc}.
401      \end{itemize}
402  In addition, other include files and subroutines might be present in \textit{%    
403  code} depending on the particular experiment. See section 2 for more details.    In addition, other include files and subroutines might be present in
404      \textit{code} depending on the particular experiment. See Section 2
405  \item \textit{input}: contains the input data files required to run the    for more details.
406  example. At a mimimum, the \textit{input} directory contains the following    
407  files:  \item \textit{input}: contains the input data files required to run
408      the example. At a minimum, the \textit{input} directory contains the
409  \begin{itemize}    following files:
410  \item \textit{input/data}: this file, written as a namelist, specifies the  
411  main parameters for the experiment.    \begin{itemize}
412      \item \textit{input/data}: this file, written as a namelist,
413  \item \textit{input/data.pkg}: contains parameters relative to the packages      specifies the main parameters for the experiment.
414  used in the experiment.    
415      \item \textit{input/data.pkg}: contains parameters relative to the
416  \item \textit{input/eedata}: this file contains ``execution environment''      packages used in the experiment.
417  data. At present, this consists of a specification of the number of threads    
418  to use in $X$ and $Y$ under multithreaded execution.    \item \textit{input/eedata}: this file contains ``execution
419  \end{itemize}      environment'' data. At present, this consists of a specification
420        of the number of threads to use in $X$ and $Y$ under multithreaded
421  In addition, you will also find in this directory the forcing and topography      execution.
422  files as well as the files describing the initial state of the experiment.    \end{itemize}
423  This varies from experiment to experiment. See section 2 for more details.  
424    In addition, you will also find in this directory the forcing and
425  \item \textit{results}: this directory contains the output file \textit{%  topography files as well as the files describing the initial state of
426  output.txt} produced by the simulation example. This file is useful for  the experiment.  This varies from experiment to experiment. See
427  comparison with your own output when you run the experiment.  section 2 for more details.
428    
429    \item \textit{results}: this directory contains the output file
430      \textit{output.txt} produced by the simulation example. This file is
431      useful for comparison with your own output when you run the
432      experiment.
433  \end{itemize}  \end{itemize}
434    
435  Once you have chosen the example you want to run, you are ready to compile  Once you have chosen the example you want to run, you are ready to compile
# Line 330  the code. Line 441  the code.
441  To compile the code, we use the {\em make} program. This uses a file  To compile the code, we use the {\em make} program. This uses a file
442  ({\em Makefile}) that allows us to pre-process source files, specify  ({\em Makefile}) that allows us to pre-process source files, specify
443  compiler and optimization options and also figures out any file  compiler and optimization options and also figures out any file
444  dependancies. We supply a script ({\em genmake}), described in section  dependencies. We supply a script ({\em genmake2}), described in
445  \ref{sect:genmake}, that automatically creates the {\em Makefile} for  section \ref{sect:genmake}, that automatically creates the {\em
446  you. You then need to build the dependancies and compile the code.    Makefile} for you. You then need to build the dependencies and
447    compile the code.
448    
449  As an example, let's assume that you want to build and run experiment  As an example, let's assume that you want to build and run experiment
450  \textit{verification/exp2}. The are multiple ways and places to actually  \textit{verification/exp2}. The are multiple ways and places to
451  do this but here let's build the code in  actually do this but here let's build the code in
452  \textit{verification/exp2/input}:  \textit{verification/exp2/input}:
453  \begin{verbatim}  \begin{verbatim}
454  % cd verification/exp2/input  % cd verification/exp2/input
455  \end{verbatim}  \end{verbatim}
456  First, build the {\em Makefile}:  First, build the {\em Makefile}:
457  \begin{verbatim}  \begin{verbatim}
458  % ../../../tools/genmake -mods=../code  % ../../../tools/genmake2 -mods=../code
459  \end{verbatim}  \end{verbatim}
460  The command line option tells {\em genmake} to override model source  The command line option tells {\em genmake} to override model source
461  code with any files in the directory {\em ./code/}.  code with any files in the directory {\em ./code/}.
462    
463  If there is no \textit{.genmakerc} in the \textit{input} directory, you have  On many systems, the {\em genmake2} program will be able to
464  to use the following options when invoking \textit{genmake}:  automatically recognize the hardware, find compilers and other tools
465    within the user's path (``echo \$PATH''), and then choose an
466    appropriate set of options from the files contained in the {\em
467      tools/build\_options} directory.  Under some circumstances, a user
468    may have to create a new ``optfile'' in order to specify the exact
469    combination of compiler, compiler flags, libraries, and other options
470    necessary to build a particular configuration of MITgcm.  In such
471    cases, it is generally helpful to read the existing ``optfiles'' and
472    mimic their syntax.
473    
474    Through the MITgcm-support list, the MITgcm developers are willing to
475    provide help writing or modifing ``optfiles''.  And we encourage users
476    to post new ``optfiles'' (particularly ones for new machines or
477    architectures) to the MITgcm-support list.
478    
479    To specify an optfile to {\em genmake2}, the syntax is:
480  \begin{verbatim}  \begin{verbatim}
481  % ../../../tools/genmake  -mods=../code  % ../../../tools/genmake2 -mods=../code -of /path/to/optfile
482  \end{verbatim}  \end{verbatim}
483    
484  Next, create the dependancies:  Once a {\em Makefile} has been generated, we create the dependencies:
485  \begin{verbatim}  \begin{verbatim}
486  % make depend  % make depend
487  \end{verbatim}  \end{verbatim}
488  This modifies {\em Makefile} by attaching a [long] list of files on  This modifies the {\em Makefile} by attaching a [long] list of files
489  which other files depend. The purpose of this is to reduce  upon which other files depend. The purpose of this is to reduce
490  re-compilation if and when you start to modify the code. {\tt make  re-compilation if and when you start to modify the code. The {\tt make
491  depend} also created links from the model source to this directory.    depend} command also creates links from the model source to this
492    directory.
493    
494  Now compile the code:  Next compile the code:
495  \begin{verbatim}  \begin{verbatim}
496  % make  % make
497  \end{verbatim}  \end{verbatim}
498  The {\tt make} command creates an executable called \textit{mitgcmuv}.  The {\tt make} command creates an executable called \textit{mitgcmuv}.
499    Additional make ``targets'' are defined within the makefile to aid in
500    the production of adjoint and other versions of MITgcm.
501    
502  Now you are ready to run the model. General instructions for doing so are  Now you are ready to run the model. General instructions for doing so are
503  given in section \ref{sect:runModel}. Here, we can run the model with:  given in section \ref{sect:runModel}. Here, we can run the model with:
# Line 385  executable in the {\em input} directory Line 515  executable in the {\em input} directory
515  convenience. You can also configure and compile the code in other  convenience. You can also configure and compile the code in other
516  locations, for example on a scratch disk with out having to copy the  locations, for example on a scratch disk with out having to copy the
517  entire source tree. The only requirement to do so is you have {\tt  entire source tree. The only requirement to do so is you have {\tt
518  genmake} in your path or you know the absolute path to {\tt genmake}.    genmake2} in your path or you know the absolute path to {\tt
519      genmake2}.
520    
521  The following sections outline some possible methods of organizing you  The following sections outline some possible methods of organizing
522  source and data.  your source and data.
523    
524  \subsubsection{Building from the {\em ../code directory}}  \subsubsection{Building from the {\em ../code directory}}
525    
526  This is just as simple as building in the {\em input/} directory:  This is just as simple as building in the {\em input/} directory:
527  \begin{verbatim}  \begin{verbatim}
528  % cd verification/exp2/code  % cd verification/exp2/code
529  % ../../../tools/genmake  % ../../../tools/genmake2
530  % make depend  % make depend
531  % make  % make
532  \end{verbatim}  \end{verbatim}
# Line 406  files must be in the same place. If you Line 537  files must be in the same place. If you
537  % cp ../code/mitgcmuv ./  % cp ../code/mitgcmuv ./
538  % ./mitgcmuv > output.txt  % ./mitgcmuv > output.txt
539  \end{verbatim}  \end{verbatim}
540  or if you will be making muliple runs with the same executable:  or if you will be making multiple runs with the same executable:
541  \begin{verbatim}  \begin{verbatim}
542  % cd ../  % cd ../
543  % cp -r input run1  % cp -r input run1
# Line 418  or if you will be making muliple runs wi Line 549  or if you will be making muliple runs wi
549  \subsubsection{Building from a new directory}  \subsubsection{Building from a new directory}
550    
551  Since the {\em input} directory contains input files it is often more  Since the {\em input} directory contains input files it is often more
552  useful to keep {\em input} prestine and build in a new directory  useful to keep {\em input} pristine and build in a new directory
553  within {\em verification/exp2/}:  within {\em verification/exp2/}:
554  \begin{verbatim}  \begin{verbatim}
555  % cd verification/exp2  % cd verification/exp2
556  % mkdir build  % mkdir build
557  % cd build  % cd build
558  % ../../../tools/genmake -mods=../code  % ../../../tools/genmake2 -mods=../code
559  % make depend  % make depend
560  % make  % make
561  \end{verbatim}  \end{verbatim}
# Line 446  running in a new directory each time mig Line 577  running in a new directory each time mig
577  % ./mitgcmuv > output.txt  % ./mitgcmuv > output.txt
578  \end{verbatim}  \end{verbatim}
579    
580  \subsubsection{Building from on a scratch disk}  \subsubsection{Building on a scratch disk}
581    
582  Model object files and output data can use up large amounts of disk  Model object files and output data can use up large amounts of disk
583  space so it is often the case that you will be operating on a large  space so it is often the case that you will be operating on a large
# Line 454  scratch disk. Assuming the model source Line 585  scratch disk. Assuming the model source
585  following commands will build the model in {\em /scratch/exp2-run1}:  following commands will build the model in {\em /scratch/exp2-run1}:
586  \begin{verbatim}  \begin{verbatim}
587  % cd /scratch/exp2-run1  % cd /scratch/exp2-run1
588  % ~/MITgcm/tools/genmake -rootdir=~/MITgcm -mods=~/MITgcm/verification/exp2/code  % ~/MITgcm/tools/genmake2 -rootdir=~/MITgcm \
589      -mods=~/MITgcm/verification/exp2/code
590  % make depend  % make depend
591  % make  % make
592  \end{verbatim}  \end{verbatim}
# Line 470  the one experiment: Line 602  the one experiment:
602  % cd /scratch/exp2  % cd /scratch/exp2
603  % mkdir build  % mkdir build
604  % cd build  % cd build
605  % ~/MITgcm/tools/genmake -rootdir=~/MITgcm -mods=~/MITgcm/verification/exp2/code  % ~/MITgcm/tools/genmake2 -rootdir=~/MITgcm \
606      -mods=~/MITgcm/verification/exp2/code
607  % make depend  % make depend
608  % make  % make
609  % cd ../  % cd ../
# Line 481  the one experiment: Line 614  the one experiment:
614    
615    
616    
617  \subsection{\textit{genmake}}  \subsection{Using \textit{genmake2}}
618  \label{sect:genmake}  \label{sect:genmake}
619    
620  To compile the code, use the script \textit{genmake} located in the \textit{%  To compile the code, first use the program \texttt{genmake2} (located
621  tools} directory. \textit{genmake} is a script that generates the makefile.  in the \textit{tools} directory) to generate a Makefile.
622  It has been written so that the code can be compiled on a wide diversity of  \texttt{genmake2} is a shell script written to work with all
623  machines and systems. However, if it doesn't work the first time on your  ``sh''--compatible shells including bash v1, bash v2, and Bourne.
624  platform, you might need to edit certain lines of \textit{genmake} in the  Internally, \texttt{genmake2} determines the locations of needed
625  section containing the setups for the different machines. The file is  files, the compiler, compiler options, libraries, and Unix tools.  It
626  structured like this:  relies upon a number of ``optfiles'' located in the {\em
627  \begin{verbatim}    tools/build\_options} directory.
628          .  
629          .  The purpose of the optfiles is to provide all the compilation options
630          .  for particular ``platforms'' (where ``platform'' roughly means the
631  general instructions (machine independent)  combination of the hardware and the compiler) and code configurations.
632          .  Given the combinations of possible compilers and library dependencies
633          .  ({\it eg.}  MPI and NetCDF) there may be numerous optfiles available
634          .  for a single machine.  The naming scheme for the majority of the
635      - setup machine 1  optfiles shipped with the code is
636      - setup machine 2  \begin{center}
637      - setup machine 3    {\bf OS\_HARDWARE\_COMPILER }
638      - setup machine 4  \end{center}
639         etc  where
640          .  \begin{description}
641          .  \item[OS] is the name of the operating system (generally the
642          .    lower-case output of the {\tt 'uname'} command)
643  \end{verbatim}  \item[HARDWARE] is a string that describes the CPU type and
644      corresponds to output from the  {\tt 'uname -m'} command:
645  For example, the setup corresponding to a DEC alpha machine is reproduced    \begin{description}
646  here:    \item[ia32] is for ``x86'' machines such as i386, i486, i586, i686,
647  \begin{verbatim}      and athlon
648    case OSF1+mpi:    \item[ia64] is for Intel IA64 systems (eg. Itanium, Itanium2)
649      echo "Configuring for DEC Alpha"    \item[amd64] is AMD x86\_64 systems
650      set CPP        = ( '/usr/bin/cpp -P' )    \item[ppc] is for Mac PowerPC systems
651      set DEFINES    = ( ${DEFINES}  '-DTARGET_DEC -DWORDLENGTH=1' )    \end{description}
652      set KPP        = ( 'kapf' )  \item[COMPILER] is the compiler name (generally, the name of the
653      set KPPFILES   = ( 'main.F' )    FORTRAN executable)
654      set KFLAGS1    = ( '-scan=132 -noconc -cmp=' )  \end{description}
655      set FC         = ( 'f77' )  
656      set FFLAGS     = ( '-convert big_endian -r8 -extend_source -automatic -call_shared -notransform_loops -align dcommons' )  In many cases, the default optfiles are sufficient and will result in
657      set FOPTIM     = ( '-O5 -fast -tune host -inline all' )  usable Makefiles.  However, for some machines or code configurations,
658      set NOOPTFLAGS = ( '-O0' )  new ``optfiles'' must be written. To create a new optfile, it is
659      set LIBS       = ( '-lfmpi -lmpi -lkmp_osfp10 -pthread' )  generally best to start with one of the defaults and modify it to suit
660      set NOOPTFILES = ( 'barrier.F different_multiple.F external_fields_load.F')  your needs.  Like \texttt{genmake2}, the optfiles are all written
661      set RMFILES    = ( '*.p.out' )  using a simple ``sh''--compatible syntax.  While nearly all variables
662      breaksw  used within \texttt{genmake2} may be specified in the optfiles, the
663  \end{verbatim}  critical ones that should be defined are:
664    
665  Typically, these are the lines that you might need to edit to make \textit{%  \begin{description}
666  genmake} work on your platform if it doesn't work the first time. \textit{%  \item[FC] the FORTRAN compiler (executable) to use
667  genmake} understands several options that are described here:  \item[DEFINES] the command-line DEFINE options passed to the compiler
668    \item[CPP] the C pre-processor to use
669  \begin{itemize}  \item[NOOPTFLAGS] options flags for special files that should not be
670  \item -rootdir=dir    optimized
671    \end{description}
672  indicates where the model root directory is relative to the directory where  
673  you are compiling. This option is not needed if you compile in the \textit{%  For example, the optfile for a typical Red Hat Linux machine (``ia32''
674  bin} directory (which is the default compilation directory) or within the  architecture) using the GCC (g77) compiler is
675  \textit{verification} tree.  \begin{verbatim}
676    FC=g77
677  \item -mods=dir1,dir2,...  DEFINES='-D_BYTESWAPIO -DWORDLENGTH=4'
678    CPP='cpp  -traditional -P'
679  indicates the relative or absolute paths directories where the sources  NOOPTFLAGS='-O0'
680  should take precedence over the default versions (located in \textit{model},  #  For IEEE, use the "-ffloat-store" option
681  \textit{eesupp},...). Typically, this option is used when running the  if test "x$IEEE" = x ; then
682  examples, see below.      FFLAGS='-Wimplicit -Wunused -Wuninitialized'
683        FOPTIM='-O3 -malign-double -funroll-loops'
684  \item -enable=pkg1,pkg2,...  else
685        FFLAGS='-Wimplicit -Wunused -ffloat-store'
686  enables packages source code \textit{pkg1}, \textit{pkg2},... when creating      FOPTIM='-O0 -malign-double'
687  the makefile.  fi
688    \end{verbatim}
689  \item -disable=pkg1,pkg2,...  
690    If you write an optfile for an unrepresented machine or compiler, you
691  disables packages source code \textit{pkg1}, \textit{pkg2},... when creating  are strongly encouraged to submit the optfile to the MITgcm project
692  the makefile.  for inclusion.  Please send the file to the
693    \begin{rawhtml} <A href="mail-to:MITgcm-support@mitgcm.org"> \end{rawhtml}
694  \item -platform=machine  \begin{center}
695      MITgcm-support@mitgcm.org
696  specifies the platform for which you want the makefile. In general, you  \end{center}
697  won't need this option. \textit{genmake} will select the right machine for  \begin{rawhtml} </A> \end{rawhtml}
698  you (the one you're working on!). However, this option is useful if you have  mailing list.
 a choice of several compilers on one machine and you want to use the one  
 that is not the default (ex: \texttt{pgf77} instead of \texttt{f77} under  
 Linux).  
   
 \item -mpi  
   
 this is used when you want to run the model in parallel processing mode  
 under mpi (see section on parallel computation for more details).  
699    
700  \item -jam  In addition to the optfiles, \texttt{genmake2} supports a number of
701    helpful command-line options.  A complete list of these options can be
702    obtained from:
703    \begin{verbatim}
704    % genmake2 -h
705    \end{verbatim}
706    
707    The most important command-line options are:
708    \begin{description}
709      
710    \item[--optfile=/PATH/FILENAME] specifies the optfile that should be
711      used for a particular build.
712      
713      If no "optfile" is specified (either through the command line or the
714      MITGCM\_OPTFILE environment variable), genmake2 will try to make a
715      reasonable guess from the list provided in {\em
716        tools/build\_options}.  The method used for making this guess is
717      to first determine the combination of operating system and hardware
718      (eg. "linux\_ia32") and then find a working FORTRAN compiler within
719      the user's path.  When these three items have been identified,
720      genmake2 will try to find an optfile that has a matching name.
721      
722    \item[--pdepend=/PATH/FILENAME] specifies the dependency file used for
723      packages.
724      
725      If not specified, the default dependency file {\em pkg/pkg\_depend}
726      is used.  The syntax for this file is parsed on a line-by-line basis
727      where each line containes either a comment ("\#") or a simple
728      "PKGNAME1 (+|-)PKGNAME2" pairwise rule where the "+" or "-" symbol
729      specifies a "must be used with" or a "must not be used with"
730      relationship, respectively.  If no rule is specified, then it is
731      assumed that the two packages are compatible and will function
732      either with or without each other.
733      
734    \item[--pdefault='PKG1 PKG2 PKG3 ...'] specifies the default set of
735      packages to be used.
736      
737      If not set, the default package list will be read from {\em
738        pkg/pkg\_default}
739      
740    \item[--adof=/path/to/file] specifies the "adjoint" or automatic
741      differentiation options file to be used.  The file is analogous to
742      the ``optfile'' defined above but it specifies information for the
743      AD build process.
744      
745      The default file is located in {\em
746        tools/adjoint\_options/adjoint\_default} and it defines the "TAF"
747      and "TAMC" compilers.  An alternate version is also available at
748      {\em tools/adjoint\_options/adjoint\_staf} that selects the newer
749      "STAF" compiler.  As with any compilers, it is helpful to have their
750      directories listed in your {\tt \$PATH} environment variable.
751      
752    \item[--mods='DIR1 DIR2 DIR3 ...'] specifies a list of directories
753      containing ``modifications''.  These directories contain files with
754      names that may (or may not) exist in the main MITgcm source tree but
755      will be overridden by any identically-named sources within the
756      ``MODS'' directories.
757      
758      The order of precedence for this "name-hiding" is as follows:
759      \begin{itemize}
760      \item ``MODS'' directories (in the order given)
761      \item Packages either explicitly specified or provided by default
762        (in the order given)
763      \item Packages included due to package dependencies (in the order
764        that that package dependencies are parsed)
765      \item The "standard dirs" (which may have been specified by the
766        ``-standarddirs'' option)
767      \end{itemize}
768      
769    \item[--make=/path/to/gmake] Due to the poor handling of soft-links and
770      other bugs common with the \texttt{make} versions provided by
771      commercial Unix vendors, GNU \texttt{make} (sometimes called
772      \texttt{gmake}) should be preferred.  This option provides a means
773      for specifying the make executable to be used.
774    
775  this is used when you want to run the model in parallel processing mode  \end{description}
 under jam (see section on parallel computation for more details).  
 \end{itemize}  
776    
 For some of the examples, there is a file called \textit{.genmakerc} in the  
 \textit{input} directory that has the relevant \textit{genmake} options for  
 that particular example. In this way you don't need to type the options when  
 invoking \textit{genmake}.  
777    
778    
779  \section{Running the model}  \section{Running the model}
# Line 804  here I think. To come soon...) Line 996  here I think. To come soon...)
996  \item time-discretization  \item time-discretization
997  \end{itemize}  \end{itemize}
998    
999  The time steps are set through the real variables \textbf{deltaTMom }and  The time steps are set through the real variables \textbf{deltaTMom}
1000  \textbf{deltaTtracer }(in s) which represent the time step for the momentum  and \textbf{deltaTtracer} (in s) which represent the time step for the
1001  and tracer equations, respectively. For synchronous integrations, simply set  momentum and tracer equations, respectively. For synchronous
1002  the two variables to the same value (or you can prescribe one time step only  integrations, simply set the two variables to the same value (or you
1003  through the variable \textbf{deltaT}). The Adams-Bashforth stabilizing  can prescribe one time step only through the variable
1004  parameter is set through the variable \textbf{abEps }(dimensionless). The  \textbf{deltaT}). The Adams-Bashforth stabilizing parameter is set
1005  stagger baroclinic time stepping can be activated by setting the logical  through the variable \textbf{abEps} (dimensionless). The stagger
1006  variable \textbf{staggerTimeStep }to '.\texttt{TRUE}.'.  baroclinic time stepping can be activated by setting the logical
1007    variable \textbf{staggerTimeStep} to '.\texttt{TRUE}.'.
1008    
1009  \subsection{Equation of state}  \subsection{Equation of state}
1010    
1011  First, because the model equations are written in terms of perturbations, a  First, because the model equations are written in terms of
1012  reference thermodynamic state needs to be specified. This is done through  perturbations, a reference thermodynamic state needs to be specified.
1013  the 1D arrays \textbf{tRef}\textit{\ }and \textbf{sRef}. \textbf{tRef }%  This is done through the 1D arrays \textbf{tRef} and \textbf{sRef}.
1014  specifies the reference potential temperature profile (in $^{o}$C for  \textbf{tRef} specifies the reference potential temperature profile
1015  the ocean and $^{o}$K for the atmosphere) starting from the level  (in $^{o}$C for the ocean and $^{o}$K for the atmosphere) starting
1016  k=1. Similarly, \textbf{sRef}\textit{\ }specifies the reference salinity  from the level k=1. Similarly, \textbf{sRef} specifies the reference
1017  profile (in ppt) for the ocean or the reference specific humidity profile  salinity profile (in ppt) for the ocean or the reference specific
1018  (in g/kg) for the atmosphere.  humidity profile (in g/kg) for the atmosphere.
1019    
1020  The form of the equation of state is controlled by the character variables  The form of the equation of state is controlled by the character
1021  \textbf{buoyancyRelation}\textit{\ }and \textbf{eosType}\textit{. }\textbf{%  variables \textbf{buoyancyRelation} and \textbf{eosType}.
1022  buoyancyRelation}\textit{\ }is set to '\texttt{OCEANIC}' by default and  \textbf{buoyancyRelation} is set to '\texttt{OCEANIC}' by default and
1023  needs to be set to '\texttt{ATMOSPHERIC}' for atmosphere simulations. In  needs to be set to '\texttt{ATMOSPHERIC}' for atmosphere simulations.
1024  this case, \textbf{eosType}\textit{\ }must be set to '\texttt{IDEALGAS}'.  In this case, \textbf{eosType} must be set to '\texttt{IDEALGAS}'.
1025  For the ocean, two forms of the equation of state are available: linear (set  For the ocean, two forms of the equation of state are available:
1026  \textbf{eosType}\textit{\ }to '\texttt{LINEAR}') and a polynomial  linear (set \textbf{eosType} to '\texttt{LINEAR}') and a polynomial
1027  approximation to the full nonlinear equation ( set \textbf{eosType}\textit{\  approximation to the full nonlinear equation ( set
1028  }to '\texttt{POLYNOMIAL}'). In the linear case, you need to specify the  \textbf{eosType}\textit{\ }to '\texttt{POLYNOMIAL}'). In the linear
1029  thermal and haline expansion coefficients represented by the variables  case, you need to specify the thermal and haline expansion
1030  \textbf{tAlpha}\textit{\ }(in K$^{-1}$) and \textbf{sBeta}\textit{\ }(in ppt$%  coefficients represented by the variables \textbf{tAlpha}\textit{\
1031  ^{-1}$). For the nonlinear case, you need to generate a file of polynomial    }(in K$^{-1}$) and \textbf{sBeta} (in ppt$^{-1}$). For the nonlinear
1032  coefficients called \textit{POLY3.COEFFS. }To do this, use the program  case, you need to generate a file of polynomial coefficients called
1033  \textit{utils/knudsen2/knudsen2.f }under the model tree (a Makefile is  \textit{POLY3.COEFFS}. To do this, use the program
1034  available in the same directory and you will need to edit the number and the  \textit{utils/knudsen2/knudsen2.f} under the model tree (a Makefile is
1035  values of the vertical levels in \textit{knudsen2.f }so that they match  available in the same directory and you will need to edit the number
1036  those of your configuration). \textit{\ }  and the values of the vertical levels in \textit{knudsen2.f} so that
1037    they match those of your configuration).
1038    
1039    There there are also higher polynomials for the equation of state:
1040    \begin{description}
1041    \item['\texttt{UNESCO}':] The UNESCO equation of state formula of
1042      Fofonoff and Millard \cite{fofonoff83}. This equation of state
1043      assumes in-situ temperature, which is not a model variable; \emph{its use
1044      is therefore discouraged, and it is only listed for completeness}.
1045    \item['\texttt{JMD95Z}':] A modified UNESCO formula by Jackett and
1046      McDougall \cite{jackett95}, which uses the model variable potential
1047      temperature as input. The '\texttt{Z}' indicates that this equation
1048      of state uses a horizontally and temporally constant pressure
1049      $p_{0}=-g\rho_{0}z$.
1050    \item['\texttt{JMD95P}':] A modified UNESCO formula by Jackett and
1051      McDougall \cite{jackett95}, which uses the model variable potential
1052      temperature as input. The '\texttt{P}' indicates that this equation
1053      of state uses the actual hydrostatic pressure of the last time
1054      step. Lagging the pressure in this way requires an additional pickup
1055      file for restarts.
1056    \item['\texttt{MDJWF}':] The new, more accurate and less expensive
1057      equation of state by McDougall et~al. \cite{mcdougall03}. It also
1058      requires lagging the pressure and therefore an additional pickup
1059      file for restarts.
1060    \end{description}
1061    For none of these options an reference profile of temperature or
1062    salinity is required.
1063    
1064  \subsection{Momentum equations}  \subsection{Momentum equations}
1065    
# Line 1073  fields can be written out by setting the Line 1292  fields can be written out by setting the
1292  The precision with which to write the binary data is controlled by the  The precision with which to write the binary data is controlled by the
1293  integer variable w\textbf{riteBinaryPrec }(set it to \texttt{32} or \texttt{%  integer variable w\textbf{riteBinaryPrec }(set it to \texttt{32} or \texttt{%
1294  64}).  64}).
1295    
1296    %%% Local Variables:
1297    %%% mode: latex
1298    %%% TeX-master: t
1299    %%% End:

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.16

  ViewVC Help
Powered by ViewVC 1.1.22