1 | \chapter{Input/Output} |
---|
2 | \label{sc:io} |
---|
3 | |
---|
4 | \section{NetCDF format} |
---|
5 | |
---|
6 | %%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
7 | GCM input/output data are written in {\bf NetCDF} format |
---|
8 | (Network Common Data Form). NetCDF is an interface used to store and access |
---|
9 | geophysical data, and a library that provides an implementation of this |
---|
10 | interface. The NetCDF library also defines a machine-independent format for |
---|
11 | representing scientific data. |
---|
12 | Together, the interface, library and format support the creation, access and |
---|
13 | sharing of scientific data. NetCDF was developed at the Unidata Program Center |
---|
14 | in Boulder, Colorado. The freely available source can be obtained from |
---|
15 | {the Unidata website}{http://www.unidata.ucar.edu/software/netcdf}. |
---|
16 | |
---|
17 | A data set in NetCDF format is a single file, as it is self-descriptive. |
---|
18 | |
---|
19 | \subsection{NetCDF file editor: ncdump} |
---|
20 | |
---|
21 | The editor is included in the NetCDF library. |
---|
22 | By default it generates an ASCII representation as standard output |
---|
23 | from the NetCDF file specified at the input. |
---|
24 | |
---|
25 | \paragraph{Main commands for ncdump} |
---|
26 | |
---|
27 | \begin{center} |
---|
28 | {\it ncdump diagfi.nc} |
---|
29 | \end{center} |
---|
30 | |
---|
31 | \noindent |
---|
32 | dump contents of NetCDF file {\tt diagfi.nc} to standard output |
---|
33 | (i.e. the screen). |
---|
34 | |
---|
35 | \begin{center} |
---|
36 | {\it ncdump -c diagfi.nc} |
---|
37 | \end{center} |
---|
38 | |
---|
39 | \noindent |
---|
40 | Displays the {\bf coordinate} variable values (variables which are also |
---|
41 | dimensions), as well as the declarations, variables and attribute values. |
---|
42 | The values of the non-coordinate variable data are not displayed at |
---|
43 | the output. |
---|
44 | |
---|
45 | \begin{center} |
---|
46 | {\it ncdump -h diagfi.nc} |
---|
47 | \end{center} |
---|
48 | |
---|
49 | \noindent |
---|
50 | Shows only the informative header of the file, which is the declaration |
---|
51 | of the dimensions, variables and attributes, but not the values of these |
---|
52 | variables. The output is identical to that in option {\bf -c} except for |
---|
53 | the fact that the coordinated variable values are not included. |
---|
54 | |
---|
55 | \begin{center} |
---|
56 | {\it ncdump -v var1,...,varn diagfi.nc} |
---|
57 | \end{center} |
---|
58 | |
---|
59 | \noindent |
---|
60 | The output includes the specific variable values, |
---|
61 | as well as all the dimensions, variables and attributes. |
---|
62 | More that one variable can be specified in the list following this option. |
---|
63 | The list must be a simple argument for the command, and must not contain any |
---|
64 | spaces. If no variable is specified, the command displays all the values of |
---|
65 | the variables in the file by default. |
---|
66 | |
---|
67 | |
---|
68 | \subsection{Graphic visualization of the NetCDF files using GrAds} |
---|
69 | |
---|
70 | GrAdS (The Grid Analysis and Display System) is a graphic software developed |
---|
71 | by Brian Doty at the "Center for Ocean-Land-Atmosphere (COLA)". |
---|
72 | |
---|
73 | One of its functions is to enable data stored in NetCDF format to be |
---|
74 | visualized directly. In figure~\ref{fg:grads} for example, we can see the |
---|
75 | GrADS visualization of the temperature data at a given moment. |
---|
76 | % |
---|
77 | \begin{figure} |
---|
78 | \centering |
---|
79 | \includegraphics[width=0.5\textwidth,angle=270]{Fig/grads.eps} |
---|
80 | \caption{Example of temperature data (in this case for present-day Mars) at a given time using |
---|
81 | GrADS visualization\label{fg:grads}} |
---|
82 | \end{figure} |
---|
83 | % |
---|
84 | However, unlike NetCDF, GrADS only recognizes files where all the variables are stored on the same horizontal grid. |
---|
85 | These variables can be in 1, 2, 3 or 4 dimensions (X,Y,Z and t).\\ |
---|
86 | |
---|
87 | GrADS can also be obtained on the {WWW}{http://grads.iges.org/grads/}. |
---|
88 | |
---|
89 | \section{Input and parameter files} |
---|
90 | |
---|
91 | %{\bf \it Examples of initialization files can be found in directory |
---|
92 | %\begin{verbatim}$PATH1/LMDZ.MARS/deftank \end{verbatim}} |
---|
93 | \label{loc:entrees} |
---|
94 | |
---|
95 | The (3D version of the) GCM requires |
---|
96 | the input of two initialization files (in NetCDF format):\\ |
---|
97 | -{\bf start.nc} |
---|
98 | contains the initial states of the dynamical variables.\\ |
---|
99 | -{\bf startfi.nc} |
---|
100 | contains the initial states of the physical variables.\\ |
---|
101 | Note that collections of initial states can be retreived at:\\ |
---|
102 | \verb+http://www.lmd.jussieu.fr/~forget/datagcm/Starts+ \\ |
---|
103 | Extracting {\tt start.nc} and {\tt startfi.nc} from these archived |
---|
104 | requires using program {\tt newstart}, as described in |
---|
105 | section~\ref{sc:newstart}.\\ |
---|
106 | |
---|
107 | \noindent |
---|
108 | To run, the GCM also requires the four following |
---|
109 | parameter files (ascii text files):\\ |
---|
110 | -{\bf run.def} the parameters of the dynamical part of the program, |
---|
111 | and the temporal integration of the model.\\ |
---|
112 | -{\bf callphys.def} the parameters for calling the physical part.\\ |
---|
113 | -{\bf traceur.def} the names of the tracer to use.\\ |
---|
114 | -{\bf z2sig.def} |
---|
115 | the vertical distribution of the atmospheric layers.\\ |
---|
116 | Examples of these parameter files can be found in the |
---|
117 | \verb+LMDZ.MARS/deftank+ directory. |
---|
118 | |
---|
119 | \subsection{run.def} |
---|
120 | \label{vb:run.def} |
---|
121 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
122 | % run.def: les param sont lus dans dyn3d/defrun.F |
---|
123 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
124 | |
---|
125 | A typical {\tt run.def} file is given as an example below. |
---|
126 | The choice of variables to be set is simple (e.g. |
---|
127 | {\tt nday} number of modeled days to run), |
---|
128 | while the others do not need to be changed for normal use.\\ |
---|
129 | The format of the {\tt run.def} file is quite straightforward |
---|
130 | (and flexible): values given to parameters must be given as: |
---|
131 | \begin{verbatim} |
---|
132 | parameter = value |
---|
133 | \end{verbatim} |
---|
134 | Any blank line or line beginning with symbol {\bf \#} is |
---|
135 | a comment, and instruction lines may be written in any order. |
---|
136 | Moreover, not specifying a parameter/value set (e.g. deleting it |
---|
137 | or commenting it out) means you want the GCM to use a default built-in value. |
---|
138 | Additionally, one may use a specific keyword {\bf INCLUDEDEF} to specify |
---|
139 | another (text) file in which to also read values of parameters; e.g.: |
---|
140 | \begin{verbatim} |
---|
141 | INCLUDEDEF=callphys.def |
---|
142 | \end{verbatim} |
---|
143 | |
---|
144 | |
---|
145 | \noindent Here are some details about some of the parameters which may be |
---|
146 | set in {\tt run.def}: |
---|
147 | \begin{itemize} |
---|
148 | \item {\bf day\_step}, the number of dynamical steps per day to use for |
---|
149 | the time integration. This needs to be large enough for the model |
---|
150 | to remain stable (this is related to the CFL stability criterion |
---|
151 | which essentially depends on the horizontal resolution of the model). |
---|
152 | On Mars, in theory, the GCM can run with |
---|
153 | {\tt day\_step}=480 using the 64$\times$48 grid, but model stability |
---|
154 | improves when this number is higher: {\tt day\_step}=960 is recommended |
---|
155 | when using the 64$\times$48 grid. According to the CFL criterion, |
---|
156 | {\tt day\_step} should vary in proportion with the resolution: for example |
---|
157 | {\tt day\_step}=480 using the 32$\times$24 horizontal resolution. |
---|
158 | Note that {\tt day\_step} must also be divisible by {\tt iperiod}. For other planets... [FINISH] |
---|
159 | |
---|
160 | \item {\bf tetagdiv, tetagrot, tetatemp} control the dissipation intensity. |
---|
161 | It is better to limit the dissipation intensity |
---|
162 | (tetagdiv, tetagrot, tetatemp should not be too low). |
---|
163 | However the model diverges if tetagdiv, tetagrot, tetatemp are too high, |
---|
164 | especially if there is a lot of dust in the atmosphere. \\ |
---|
165 | Example used with nitergdiv=1 and nitergrot=niterh=2 : \\ |
---|
166 | - using the 32$\times$24 grid tetagdiv=6000~s ; tetagrot=tetatemp=30000~s \\ |
---|
167 | - using the 64$\times$48 grid: tetagdiv=3000~s ; tetagrot=tetatemp=9000~s |
---|
168 | |
---|
169 | \item {\bf idissip} is the time step used for the dissipation: |
---|
170 | dissipation is computed and added every {\tt idissip} dynamical |
---|
171 | time step. If {\tt idissip} is |
---|
172 | too short, the model waste time in these calculations. But if idissip is too |
---|
173 | long, the dissipation will not be parametrized correctly and the model will |
---|
174 | be more likely to diverge. |
---|
175 | A check must be made, so that: |
---|
176 | {\tt idissip}~$<$~{\tt tetagdiv}$\times${\tt daystep}/86400 |
---|
177 | (same rule for {\tt tetagrot} and {\tt tetatemp}). |
---|
178 | This is tested automatically during the run. |
---|
179 | |
---|
180 | \item {\bf iphysiq} is the time step used for the physics: |
---|
181 | physical tendencies are computed every {\tt iphysiq} dynamical time step. |
---|
182 | In practice, we |
---|
183 | usually set the physical time step to be of the order of half an hour. |
---|
184 | We thus generally set {\tt iphysiq}= {\tt day\_step}/48 |
---|
185 | |
---|
186 | \end{itemize} |
---|
187 | |
---|
188 | \noindent |
---|
189 | {\it Example of run.def file: } |
---|
190 | \input{input/run.tex} |
---|
191 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
192 | |
---|
193 | |
---|
194 | \subsection{callphys.def} |
---|
195 | \label{sc:callphys.def} |
---|
196 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
197 | % callphys.def: les param sont lus dans phymars/inifis.F |
---|
198 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
199 | The {\tt callphys.def} file (along the same format |
---|
200 | as the {\tt run.def} file) contains parameter/value sets |
---|
201 | for the physics.\\ |
---|
202 | |
---|
203 | |
---|
204 | \noindent |
---|
205 | {\it Example of callphys.def file: } |
---|
206 | \input{input/callphys.tex} |
---|
207 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
208 | |
---|
209 | \subsection{traceur.def} |
---|
210 | \label{sc:traceur.def} |
---|
211 | Tracers in input ({\tt start.nc} and {\tt startfi.nc}) and output |
---|
212 | files ({\tt restart.nc} and {\tt restartfi.nc}) are stored using |
---|
213 | individual tracer names (e.g. {\tt co2} for CO2 gas, {\tt h2o\_vap} |
---|
214 | for water vapour, {\tt h2o\_ice} for water ice, ...).\\ |
---|
215 | The first line of the {\tt traceur.def} file (an ASCII file) must |
---|
216 | contain the number of tracers to load and use (this number should |
---|
217 | be the same as given to the {\tt -t} option of the {\tt makegcm} |
---|
218 | script when the GCM was compiled), followed by the tracer names |
---|
219 | (one per line). Note that if the corresponding tracers are not |
---|
220 | found in input files {\tt start.nc} and {\tt startfi.nc}, then the |
---|
221 | tracer is initialized to zero.\\ |
---|
222 | |
---|
223 | |
---|
224 | \noindent {\it Example of a traceur.def file: |
---|
225 | (with water vapour and ice tracers)} |
---|
226 | {\footnotesize |
---|
227 | \begin{verbatim} |
---|
228 | 2 |
---|
229 | h2o_ice |
---|
230 | h2o_vap |
---|
231 | \end{verbatim} |
---|
232 | } |
---|
233 | |
---|
234 | \subsection{z2sig.def} |
---|
235 | The {\tt z2sig.def} file contains the pseudo-altitudes |
---|
236 | (in km) at which the user wants to set the vertical levels.\\ |
---|
237 | Note that levels should be unevenly spread, with a higher resolution |
---|
238 | near the surface in order to capture the rapid variations of variables |
---|
239 | there. It is recommended to use the altitude levels as set in the |
---|
240 | {\tt z2sig.def} file provided in the {\tt deftank} directory.\\ |
---|
241 | |
---|
242 | \noindent |
---|
243 | {\it Example of z2sig.def file} |
---|
244 | \input{input/z2sig.tex} |
---|
245 | |
---|
246 | \subsection{Initialization files: start and startfi} |
---|
247 | |
---|
248 | % |
---|
249 | \begin{figure}[h] |
---|
250 | \centering |
---|
251 | \framebox[0.8\textwidth][c]{\includegraphics[width=0.7\textwidth]{Fig/netcdf.eps}} |
---|
252 | \caption{Organization of NetCDF files \label{fg:netcdf}} |
---|
253 | \end{figure} |
---|
254 | % |
---|
255 | Files {\tt start.nc} and {\tt startfi.nc}, like all the NetCDF files of |
---|
256 | the GCM, |
---|
257 | are constructed on the same model (see NetCDF file composition, |
---|
258 | figure~\ref{fg:netcdf}). They contain:\\ |
---|
259 | - a header with a ``control'' variable followed by a series of variables |
---|
260 | defining the (physical and dynamical) grids \\ |
---|
261 | - a series of non temporal variables that give information about surface |
---|
262 | conditions on the planet.\\ |
---|
263 | - a ``time'' variable giving the values of the different instants at which |
---|
264 | the temporal variables are stored |
---|
265 | (a single time value (t=0) for start, |
---|
266 | as it describes the dynamical initial states, |
---|
267 | and no time values for startfi, as it describes only a physical state).\\ |
---|
268 | |
---|
269 | To visualize the contents of a {\tt start.nc} file using the |
---|
270 | {\tt ncdump} command:\\ |
---|
271 | |
---|
272 | \noindent |
---|
273 | {\it ncdump -h start.nc}\\ |
---|
274 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
275 | % List START |
---|
276 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
277 | \input{input/dyn_list.tex} |
---|
278 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
279 | |
---|
280 | \noindent |
---|
281 | List of contents of a {\tt startfi.nc} file:\\ |
---|
282 | |
---|
283 | \noindent |
---|
284 | {\it ncdump -h startfi.nc}\\ |
---|
285 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
286 | % List startfi |
---|
287 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
288 | \input{input/fi_list.tex} |
---|
289 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
290 | |
---|
291 | |
---|
292 | |
---|
293 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
294 | % Description des start et startfi |
---|
295 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
296 | |
---|
297 | \paragraph{Physical and dynamical headers} |
---|
298 | |
---|
299 | There are two types of headers: one for the physical headers, |
---|
300 | and one for the dynamical headers. |
---|
301 | The headers always begin with a ``control' variable |
---|
302 | (described below), that is allocated differently in the physical and |
---|
303 | dynamical parts. |
---|
304 | The other variables in the header concern the (physical and dynamical) grids. |
---|
305 | They are the following:\\ |
---|
306 | |
---|
307 | \noindent |
---|
308 | the horizontal coordinates\\ |
---|
309 | - {\bf rlonu}, {\bf rlatu}, {\bf rlonv}, {\bf rlatv} for the dynamical part,\\ |
---|
310 | - {\bf lati}, {\bf long} for the physical part,\\ |
---|
311 | |
---|
312 | \noindent |
---|
313 | the coefficients for passing from the physical grid to the dynamical grid\\ |
---|
314 | - {\bf cu},{\bf cv} only in the dynamical header\\ |
---|
315 | |
---|
316 | \noindent |
---|
317 | and finally, the grid box areas\\ |
---|
318 | - {\bf aire} for the dynamical part,\\ |
---|
319 | - {\bf area} for the physical part.\\ |
---|
320 | |
---|
321 | \paragraph{Surface conditions} |
---|
322 | |
---|
323 | The surface conditions are mostly given in the physical NetCDF files by |
---|
324 | variables:\\ |
---|
325 | - {\bf phisfi} for the initial state of surface geopotential,\\ |
---|
326 | - {\bf albedodat} for the bare ground albedo,\\ |
---|
327 | - {\bf inertiedat} for the surface thermal inertia,\\ |
---|
328 | - {\bf zmea}, {\bf zstd}, {\bf zsig}, {\bf zgam} and {\bf zthe} for |
---|
329 | the subgrid scale topography.\\ |
---|
330 | |
---|
331 | \noindent |
---|
332 | For the dynamics:\\ |
---|
333 | - {\bf physinit} for the initial state of surface geopotential\\ |
---|
334 | |
---|
335 | \noindent |
---|
336 | Remark: variables {\bf phisfi} and {\bf physinit} contain the same information |
---|
337 | (surface geopotential), but {\bf phisfi} gives the geopotential values on the |
---|
338 | physical grid, while {\bf physinit} give the values on the dynamical grid.\\ |
---|
339 | |
---|
340 | \paragraph{Physical and dynamical state variables} |
---|
341 | To save disk space, the initialization files store the variables used by |
---|
342 | the model, rather than the ``natural'' variables.\\ |
---|
343 | |
---|
344 | \noindent |
---|
345 | For the dynamics: |
---|
346 | \begin{description} |
---|
347 | \item - {\bf ucov} and {\bf vcov} the covariant winds\\ |
---|
348 | These variables are linked to the ``natural'' winds by\\ |
---|
349 | \verb+ucov = cu * u+ and \verb+vcov = cv * v+ |
---|
350 | \item - {\bf teta} the potential temperature,\\ |
---|
351 | or more precisely, the potential enthalpy linked to temperature {\bf T} by |
---|
352 | $\theta = T\dep{\frac{P}{Pref}}^{-K}$ |
---|
353 | \item - the tracers, |
---|
354 | \item - {\bf ps} surface pressure. |
---|
355 | \item - {\bf masse} the atmosphere mass in each grid box. |
---|
356 | \end{description} |
---|
357 | |
---|
358 | \noindent |
---|
359 | ``Vectorial'' variables {\bf ucov} and {\bf vcov} are stored on |
---|
360 | ``staggered'' grids u and v respectively (in the dynamics) |
---|
361 | (see section \ref{fg:grid}).\\ |
---|
362 | Scalar variables {\bf h}, {\bf q} (tracers), {\bf ps}, {\bf masse} are stored |
---|
363 | on the ``scalar'' grid of the dynamical part.\\ |
---|
364 | |
---|
365 | \noindent |
---|
366 | For the physics: |
---|
367 | \begin{description} |
---|
368 | \item - {\bf co2ice} surface dry ice, |
---|
369 | \item - {\bf tsurf} surface temperature, |
---|
370 | \item - {\bf tsoil} temperatures at different layers under the surface, |
---|
371 | \item - {\bf emis} surface emissivity, |
---|
372 | \item - {\bf q2} wind variance,\\ |
---|
373 | or more precisely, the square root of the turbulent kinetic energy. |
---|
374 | \item - the surface ``tracer'' budget |
---|
375 | (kg.m$^{-2}$),\\ |
---|
376 | \end{description} |
---|
377 | |
---|
378 | \noindent |
---|
379 | All these variables are stored on the ``physical'' grid |
---|
380 | (see section \ref{fg:grid}).\\ |
---|
381 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
382 | |
---|
383 | \paragraph{The ``control'' array} |
---|
384 | |
---|
385 | \indent |
---|
386 | Both physical and dynamical headers of the GCM NetCDF files start with |
---|
387 | a {\bf controle} variable. This variable is an array of 100 reals (the vector |
---|
388 | called {\tt tab\_cntrl} in the program), which contains the program control |
---|
389 | parameters. |
---|
390 | Parameters differ between the physical and dynamical sections, and examples |
---|
391 | of both are listed below. The contents of table {\tt tab\_cntrl} can also |
---|
392 | be checked with the command {\tt ncdump -ff -v controle}.\\ |
---|
393 | |
---|
394 | \noindent |
---|
395 | {\bf The "control" array in the header of a dynamical NetCDF file: |
---|
396 | start} |
---|
397 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
398 | % tab_cntrl (dynamique) dans dyn3d/inimomo.F |
---|
399 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
400 | \input{input/dyn_cntl.tex} |
---|
401 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
402 | |
---|
403 | \noindent |
---|
404 | {\bf The "controle" array in the header of a physical NetCDF file: |
---|
405 | startfi.nc} |
---|
406 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
407 | % tab_cntrl (physique) dans phymars/iniwritefi.F |
---|
408 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
409 | \input{input/fi_cntl.tex} |
---|
410 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
411 | |
---|
412 | \newpage |
---|
413 | \section{Output files} |
---|
414 | |
---|
415 | \subsection{NetCDF restart files - restart.nc and restartfi.nc} |
---|
416 | These files are of the exact same format as {\tt start.nc} and |
---|
417 | {\tt startfi.nc} |
---|
418 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
419 | % Description des fichiers de Sortie |
---|
420 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
421 | |
---|
422 | \subsection{ NetCDF file - diagfi.nc} |
---|
423 | NetCDF file {\tt diagfi.nc} stores the instantaneous physical variables |
---|
424 | throughout the simulation at regular intervals |
---|
425 | (set by the value of parameter {\tt ecritphy} in |
---|
426 | parameter file {\tt run.def}; note that {\tt ecritphy} should be a |
---|
427 | multiple of {\tt iphysiq} as well as a divisor of {\tt day\_step}). |
---|
428 | |
---|
429 | \noindent |
---|
430 | {\bf Any variable from any sub-routine of the physics can be stored |
---|
431 | by calling subroutine} |
---|
432 | \verb+ writediagfi+ |
---|
433 | |
---|
434 | |
---|
435 | \noindent |
---|
436 | Illustrative example of the contents of a {\tt diagfi.nc} |
---|
437 | file (using ncdump):\\ |
---|
438 | \noindent |
---|
439 | {\it ncdump -h diagfi.nc}\\ |
---|
440 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
441 | % List DIAGFI |
---|
442 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
443 | % temporaire!!! |
---|
444 | \input{input/diag_list.tex} |
---|
445 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
446 | |
---|
447 | \noindent |
---|
448 | The structure of the file is thus as follows: |
---|
449 | \begin{description} |
---|
450 | \item- the dimensions |
---|
451 | \item- variable ``time'' containing the time of the timestep stored in the |
---|
452 | file (in Martian days since the beginning of the run) |
---|
453 | \item- variable ``control'' containing many parameters, as described above. |
---|
454 | \item- from `` rhonu'' to 'phisinit'': a list of data describing the |
---|
455 | geometrical coordinates of the data file, plus the surface topography |
---|
456 | \item- finally, all the 2D or 3D data stored in the run. |
---|
457 | \end{description} |
---|
458 | |
---|
459 | |
---|
460 | \subsection{Stats files} |
---|
461 | |
---|
462 | As an option ({\tt stats} must be set to {\tt .true.} in {\tt callphys.def}), |
---|
463 | the model can accumulate any |
---|
464 | variable from any subroutine of the physics by calling |
---|
465 | subroutine \verb+ wstat+ |
---|
466 | \\ \\ |
---|
467 | \noindent |
---|
468 | This save is performed at regular intervals 12 times a day. |
---|
469 | An average of the daily evolutions over the whole run is calculated |
---|
470 | (for example, for a 10 day run, the averages of the variable values at |
---|
471 | 0hTU, 2hTU, 4hTU,...24hTU are calculated), along with RMS standard |
---|
472 | deviations of the variables. This ouput is given in |
---|
473 | file {\tt stats.nc}.\\ |
---|
474 | |
---|
475 | |
---|
476 | \noindent |
---|
477 | Illustrative example of the contents of a {\tt stats.nc} file (using ncdump):\\ |
---|
478 | \noindent |
---|
479 | {\it ncdump -h stats.nc}\\ |
---|
480 | \input{input/stats_list.tex} |
---|
481 | |
---|
482 | \noindent |
---|
483 | The structure of the file is simillar to the {\tt diagfi.nc} file, |
---|
484 | except that, as stated before, the average of variables are given for |
---|
485 | 12 times of the day and that RMS standard deviation are also provided. |
---|
486 | |
---|