[987] | 1 | \chapter{Utilities} |
---|
| 2 | |
---|
| 3 | \label{sc:utilities} |
---|
| 4 | |
---|
| 5 | A few post-processing tools, which handle GCM outputs (files |
---|
| 6 | {\tt diagfi.nc} and {\tt stats.nc}) are available on the web at:\\ |
---|
| 7 | \verb+http://www.lmd.jussieu.fr/~forget/datagcm/Utilities/+\\ |
---|
| 8 | The directory contains compiled executables (\verb+*.e+ files) of the tools |
---|
| 9 | decribed below, along with some examples of input instruction |
---|
| 10 | (\verb+*.def+ files) and a \verb+README+.\\ |
---|
| 11 | There is also a \verb+SOURCES+ directory which contains the (Fortran) |
---|
| 12 | sources of the codes, if you should need to recompile them |
---|
| 13 | on your platform. |
---|
| 14 | |
---|
| 15 | \section{concatnc} |
---|
| 16 | This program concatenates consecutive |
---|
| 17 | output files ({\tt diagfi.nc} or even {\tt stats.nc} files) for a selection of |
---|
| 18 | variable, in order to obtain one single big file. |
---|
| 19 | The time dimension of the output can |
---|
| 20 | be "sols" or "Ls" (note that in that latter case, Ls values won't be |
---|
| 21 | evenly distributed, and |
---|
| 22 | software like Grads may not be able to use and plot the data).\\ |
---|
| 23 | To obtain an evenly sampled "Ls" |
---|
| 24 | timescale, you can use the {\tt lslin.e} program (described below).\\ |
---|
| 25 | The output file created by {\tt conctanc.e} is {\tt concat.nc} |
---|
| 26 | |
---|
| 27 | \section{lslin} |
---|
| 28 | |
---|
| 29 | This program is designed to interpolate data given |
---|
| 30 | in irregular Solar Longitude (Ls) into an evenly sampled |
---|
| 31 | linear time coordinate (usable with Grads). |
---|
| 32 | Input Netcdf files may be {\tt diagfi.nc} or {\tt concat.nc} |
---|
| 33 | files and the resulting |
---|
| 34 | output file is {\tt lslin.nc} |
---|
| 35 | lslin also create a {\tt lslin.ctl} file that can be read |
---|
| 36 | directly by grads (\verb+>xdfopen lslin.ctl+) to plot in Ls coordinate to |
---|
| 37 | avoid some problem with grads when Grads think that "the time interval |
---|
| 38 | is too small"... |
---|
| 39 | |
---|
| 40 | \section{localtime} |
---|
| 41 | |
---|
| 42 | The {\tt localtime.e} program is designed to re-interpolate data in order |
---|
| 43 | to yield values at the same given local time (useful to mimic satellite |
---|
| 44 | observations, or analyse day to day variations at given local time).\\ |
---|
| 45 | Input files may be of {\tt diagfi.nc}, {\tt stats.nc} or {\tt concat.nc} |
---|
| 46 | type and the output file name is build from the input one, to which |
---|
| 47 | {\tt \_LT.nc} is appened (e.g. if the input file is {\tt myfile.nc} then |
---|
| 48 | output file will be {\tt myfile\_LT.nc}). |
---|
| 49 | |
---|
| 50 | \section{zrecast} |
---|
| 51 | With this program you can recast atmospheric (i.e.: 4D-dimentional |
---|
| 52 | longitude-latitude-altitude-time) data from GCM outputs (e.g. as given in |
---|
| 53 | {\tt diagfi.nc}, {\tt concat.nc} and {\tt stats.nc} files) onto |
---|
| 54 | either {\it pressure} or {\it altitude above areoid} vertical coordinates.\\ |
---|
| 55 | Since integrating the hydrostatic equation is required to recast the data, |
---|
| 56 | the input file must contain surface pressure and atmospheric temperature, |
---|
| 57 | as well as the ground geopotential.\\ |
---|
| 58 | If recasting data onto {\it pressure} coordinates, then the output file name |
---|
| 59 | is given by the input file name to which {\tt\_P.nc} will be appened. |
---|
| 60 | If recasting data onto {\it altitude above areoid} coordinates, then a |
---|
| 61 | {\tt\_A.nc} will be appened. |
---|
| 62 | |
---|
| 63 | |
---|
| 64 | %\section{How to concat diagfi files?} |
---|
| 65 | %In the directory concatnc (available on the web at |
---|
| 66 | %http://www.lmd.jussieu.fr/\verb+~+forget/datagcm/Utilities/), |
---|
| 67 | %you will find a tool to concat the diagfi files. |
---|
| 68 | %To compile, juste type "make" |
---|
| 69 | %(make sure the makefile is updated: FC= pgf90 for PC and FC= f90 for suns).\\ \\ |
---|
| 70 | %run concatnc.e \\ \\ |
---|
| 71 | %Your data are in concat.nc |
---|
| 72 | % |
---|
| 73 | %\section{How to convert your output in pressure coordinates?} |
---|
| 74 | %In your working directory, compile at the correct grid resolution, which is |
---|
| 75 | %the same as the one of your output files (stats or diagfi).\\ \\ |
---|
| 76 | %makegcm -d 64x48x32 -p mars anl\_stats-diag \\ \\ |
---|
| 77 | %run anl\_stats-diag.e |
---|
| 78 | %Your data in pressure coordinate will be in the resuting diagfi.nc |
---|
| 79 | %(or stats.nc). \\ |
---|
| 80 | %If needed, you can change the source file anl\_stats-diag.F in |
---|
| 81 | %yourpath/LMDZ.MARS/libf/dyn3d |
---|