source: trunk/SRC/Documentation/xmldoc/firststeps.xml @ 83

Last change on this file since 83 was 82, checked in by pinsard, 18 years ago

replace #anchor?format=raw by ?format=raw#anchor in xsl file

  • Property svn:executable set to *
File size: 33.1 KB
Line 
1<?xml version='1.0' encoding='iso-8859-1'?>
2<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
4[
5<!ENTITY promptidl "idl&gt;">
6<!ENTITY numb1 '<inlinemediaobject><imageobject><imagedata fileref="images/callouts/1.png?format=raw" format="PNG"/></imageobject><textobject><phrase>1</phrase></textobject></inlinemediaobject>'>
7<!ENTITY numb2 '<inlinemediaobject><imageobject><imagedata fileref="images/callouts/2.png?format=raw" format="PNG"/></imageobject><textobject><phrase>2</phrase></textobject></inlinemediaobject>'>
8<!ENTITY showfig '<inlinemediaobject><imageobject><imagedata fileref="images/showfig.png?format=raw" format="PNG"/></imageobject><textobject><phrase>show result</phrase></textobject></inlinemediaobject>'>
9]>
10
11<!--
12instructions to create html file
13xsltproc ?-?-param  section.autolabel 1 -output firststep.html /sw/share/xml/xsl/docbook-xsl/xhtml/docbook.xsl firststep.xml
14xsltproc -output firststep.html /sw/share/xml/xsl/docbook-xsl/xhtml/docbook.xsl firststep.xml
15xsltproc  /sw/share/xml/xsl/docbook-xsl/xhtml/chunk.xsl  firststep.xml
16xsltproc ?-?-param  section.autolabel 1 /sw/share/xml/xsl/docbook-xsl/xhtml/chunk.xsl firststep.xml
17
18wget http://www.lodyc.jussieu.fr/~smasson/japon.html
19curl -O  http://www.lodyc.jussieu.fr/~smasson/japon.html
20-->
21
22<!--
23module :
24first steps with SAXO...
25
26source :
27/Users/sebastie/SAXO_RD/Documentation/xmldoc/firststeps.xml
28
29mise à jour :
30
31-->
32<article lang="en">
33  <title>
34    First steps with <application>SAXO</application>
35  </title>
36 
37  <articleinfo>
38    <authorgroup>
39      <author><firstname>Sébastien</firstname> <surname>Masson</surname> <email>smasson_at_lodyc.jussieu.fr</email></author>
40      <author><firstname>Françoise</firstname> <surname>Pinsard</surname> <email>Francoise.Pinsard_at_lodyc.jussieu.fr</email></author>
41    </authorgroup>
42    <keywordset>
43      <keyword>idl</keyword>
44      <keyword>SAXO</keyword>
45    </keywordset>
46    <revhistory>
47      <revision>
48        <revnumber>0.0</revnumber>
49        <date>29 July 2005</date>
50        <revremark>First draft</revremark>
51      </revision>
52      <revision>
53        <revnumber>0.1</revnumber>
54        <date>29 August 2005</date>
55        <revremark>last japanese version!</revremark>
56      </revision>
57      <revision>
58        <revnumber>0.2</revnumber>
59        <date>May 2006</date>
60        <revremark>split with getsaxo</revremark>
61      </revision>
62     </revhistory> 
63  </articleinfo>
64 
65
66 
67  <sect1 id="first_plots">
68    <title>
69      First plots...
70    </title>
71    <sect2 id="start_with_init">
72      <title>
73        Start idl session: <userinput><command>@init</command></userinput>
74      </title>
75      <para>
76        Each idl session using <application>SAXO</application> must always start with: <prompt>&promptidl;</prompt> <userinput><command>@init</command></userinput>.     
77      </para>
78      <para>
79        <emphasis>The @ is equivalent to an include. It is used to execute a set of IDL commands that will be directly executed without any compilation (as it is the case for a procedure or a function). All variables defined and used in the @... file will still be accessible after the execution of the @... is finished (which is not the case for procedures and functions that ends with the return instruction).</emphasis>
80        <screen format="linespecific">
81  <prompt>$</prompt> <userinput><command>cd</command> <filename class="directory"><envar>${HOME}</envar>/My_IDL/</filename></userinput>
82  <prompt>$</prompt> <userinput><command>idl</command></userinput>
83  <computeroutput>IDL Version 6.0, Mac OS X (darwin ppc m32). (c) 2003, Research Systems, Inc.</computeroutput>
84  <computeroutput>Installation number: 35411.</computeroutput>
85  <computeroutput>Licensed for personal use by Jean-Philippe BOULANGER only.</computeroutput>
86  <computeroutput>All other use is strictly prohibited.</computeroutput>
87  <prompt>&promptidl;</prompt> <userinput><command>@init</command></userinput>
88  <computeroutput>% Compiled module: KEEP_COMPATIBILITY.</computeroutput>
89  <computeroutput>% Compiled module: FIND.</computeroutput>
90  <computeroutput>% Compiled module: PATH_SEP.</computeroutput>
91  <computeroutput>% Compiled module: STRSPLIT.</computeroutput>
92  <computeroutput>% Compiled module: DEF_MYUNIQUETMPDIR.</computeroutput>
93  <computeroutput>We forget the compatibility with the old version</computeroutput>
94  <computeroutput>% Compiled module: DEMOMODE_COMPATIBILITY.</computeroutput>
95  <computeroutput>% Compiled module: ISADIRECTORY.</computeroutput>
96  <computeroutput>% Compiled module: LCT.</computeroutput>
97  <computeroutput>% Compiled module: RSTRPOS.</computeroutput>
98  <computeroutput>% Compiled module: REVERSE.</computeroutput>
99  <computeroutput>% Compiled module: STR_SEP.</computeroutput>
100  <computeroutput>% Compiled module: LOADCT.</computeroutput>
101  <prompt>&promptidl;</prompt>
102        </screen>
103        As an IDL session using <application>SAXO</application> must always start with <prompt>&promptidl;</prompt> <userinput><command>@init</command></userinput>, it could be convenient to define the environment variable <envar>IDL_STARTUP</envar> to <filename><envar>${HOME}</envar>/My_IDL/init.pro</filename>. In that way, <filename>init.pro</filename> will automatically been execuded when starting IDL. This can be done with the following command:
104      <variablelist>
105        <varlistentry><term><command>csh</command></term>
106        <listitem><screen><prompt>$</prompt> <userinput><command>setenv</command> <envar>IDL_STARTUP</envar> <filename><envar>${HOME}</envar>/My_IDL/init.pro</filename></userinput></screen></listitem>
107        </varlistentry>
108        <varlistentry><term><command>ksh</command></term>
109        <listitem><screen><prompt>$</prompt> <userinput><command>export</command> <envar>IDL_STARTUP</envar>=<filename><envar>${HOME}</envar>/My_IDL/init.pro</filename></userinput></screen></listitem>
110        </varlistentry>
111      </variablelist>
112      </para>
113 
114     
115    </sect2>
116    <sect2 id="basic_plots">
117      <title>
118        basic plots...
119      </title>
120      <sect3 id="basic_splot">
121      <title>
122        splot
123      </title>
124
125      <para>
126        <screenco>
127          <areaspec>
128            <area id="findgen" coords='2'/>
129          </areaspec>
130        <screen format="linespecific">
131   <prompt>&promptidl;</prompt> <userinput><command>n = 10</command></userinput>
132   <prompt>&promptidl;</prompt> <userinput><command>y = findgen(n)</command></userinput> &numb1;
133   <prompt>&promptidl;</prompt> <userinput><command>plot, y</command></userinput> <ulink url="figpng/basic_plot.png?format=raw">&showfig;</ulink>
134        </screen>
135          <calloutlist>
136            <callout arearefs="findgen">
137              <para>
138                <command>findgen</command> stands for <command>f</command>loat <command>ind</command>ex <command>gen</command>erator.
139                <screen format="linespecific">
140  <prompt>&promptidl;</prompt> <userinput><command>print, findgen(6)</command></userinput>
141  <computeroutput>      0.00000      1.00000      2.00000      3.00000      4.00000      5.00000</computeroutput>
142                </screen>
143              </para> 
144            </callout>
145          </calloutlist>
146        </screenco>
147     </para>
148     
149      <para>
150        Using IDL <command>plot</command> command is quite unconvenient to save the figure as a postscript. In addition, positionning the figure on the window/page by using <varname>!p.position</varname>, <varname>!p.region</varname> and <varname>!p.multi</varname> is often a nightmare. That's why we developped <command>splot</command> (like super-plot) which can be used in the same way as plot but is much more convenient to make postcript and position the figure.
151        <screen format="linespecific">
152  <prompt>&promptidl;</prompt> <userinput><command>splot, y</command></userinput> <ulink url="figpng/basic_splot1.png?format=raw">&showfig;</ulink>
153  <computeroutput>% Compiled module: SPLOT.</computeroutput>
154  <computeroutput>% Compiled module: REINITPLT.</computeroutput>
155  <computeroutput>% Compiled module: PLACEDESSIN.</computeroutput>
156  <computeroutput>% Compiled module: CALIBRE.</computeroutput>
157  <computeroutput>% Compiled module: GIVEWINDOWSIZE.</computeroutput>
158  <computeroutput>% Compiled module: GET_SCREEN_SIZE.</computeroutput>
159  <computeroutput>% Compiled module: TERMINEDESSIN.</computeroutput>
160        </screen>
161        Save the figure seen on the screen as a (real, not a screen capture) postscript in only one command.
162        <screenco>
163          <areaspec>
164            <area id="make_ps" coords='6'/>
165          </areaspec>
166        <screen format="linespecific">
167  <prompt>&promptidl;</prompt> <userinput><command>@ps</command></userinput>
168  <computeroutput>% Compiled module: GETFILE.</computeroutput>
169  <computeroutput>% Compiled module: PUTFILE.</computeroutput>
170  <computeroutput>% Compiled module: OPENPS.</computeroutput>
171  <computeroutput>% Compiled module: XQUESTION.</computeroutput>
172  <computeroutput>Name of the postscript file? (default answer is idl.ps) </computeroutput><userinput>first_ps</userinput> &numb1;
173  <computeroutput>% Compiled module: ISAFILE.</computeroutput>
174  <computeroutput>% Compiled module: XNOTICE.</computeroutput>
175  <computeroutput>% Compiled module: CLOSEPS.</computeroutput>
176  <computeroutput>% Compiled module: PRINTPS.</computeroutput>
177  <computeroutput>% Compiled module: FILE_WHICH.</computeroutput>
178  <computeroutput>% Compiled module: CW_BGROUP.</computeroutput>
179  <computeroutput>% Compiled module: XMANAGER.</computeroutput>
180        </screen>
181          <calloutlist>
182            <callout arearefs="make_ps">
183              <para>
184                <remark>If needed, the name of the postscript will automatically be completed with .ps. Just hit return, if you want to use the default postcript name: <filename>idl.ps</filename>.</remark> 
185              </para>
186            </callout>
187          </calloutlist>
188        </screenco>
189        Check that the <quote><filename>first_ps.ps</filename></quote> file is now existing...
190        <screen format="linespecific">
191  <prompt>&promptidl;</prompt> <userinput><command>print, file_test(psdir + 'first_ps.ps')</command></userinput>
192  <computeroutput>           1</computeroutput>
193  <prompt>&promptidl;</prompt> <userinput><command>help, file_info(psdir + 'first_ps.ps'), /structure</command></userinput>
194  <computeroutput>** Structure FILE_INFO, 21 tags, length=64, data length=63:</computeroutput>
195  <computeroutput>   NAME            STRING    '/Users/sebastie/IDL/first_ps.ps'</computeroutput>
196  <computeroutput>   EXISTS          BYTE         1</computeroutput>
197  <computeroutput>   READ            BYTE         1</computeroutput>
198  <computeroutput>   WRITE           BYTE         1</computeroutput>
199  <computeroutput>   EXECUTE         BYTE         0</computeroutput>
200  <computeroutput>   REGULAR         BYTE         1</computeroutput>
201  <computeroutput>   DIRECTORY       BYTE         0</computeroutput>
202  <computeroutput>   BLOCK_SPECIAL   BYTE         0</computeroutput>
203  <computeroutput>   CHARACTER_SPECIAL</computeroutput>
204  <computeroutput>                   BYTE         0</computeroutput>
205  <computeroutput>   NAMED_PIPE      BYTE         0</computeroutput>
206  <computeroutput>   SETUID          BYTE         0</computeroutput>
207  <computeroutput>   SETGID          BYTE         0</computeroutput>
208  <computeroutput>   SOCKET          BYTE         0</computeroutput>
209  <computeroutput>   STICKY_BIT      BYTE         0</computeroutput>
210  <computeroutput>   SYMLINK         BYTE         0</computeroutput>
211  <computeroutput>   DANGLING_SYMLINK</computeroutput>
212  <computeroutput>                   BYTE         0</computeroutput>
213  <computeroutput>   MODE            LONG               420</computeroutput>
214  <computeroutput>   ATIME           LONG64                1122424373</computeroutput>
215  <computeroutput>   CTIME           LONG64                1122424373</computeroutput>       
216  <computeroutput>   MTIME           LONG64                1122424373</computeroutput>       
217  <computeroutput>   SIZE            LONG64                      4913</computeroutput>
218        </screen>
219      </para>
220      <para id="splot_description">
221        <command>splot</command> accepts the same keywords as <command>plot</command> (<computeroutput id="plot_kwd">/ISOTROPIC, MAX_VALUE=value, MIN_VALUE=value, NSUM=value, /POLAR, THICK=value, /XLOG, /YLOG, /YNOZERO</computeroutput>), including the graphics keywords (<computeroutput id="gr_kwd">BACKGROUND, CHARSIZE, CHARTHICK, CLIP, COLOR, DATA, DEVICE, FONT, LINESTYLE, NOCLIP, NODATA, NOERASE, NORMAL, POSITION, PSYM, SUBTITLE, SYMSIZE, T3D, THICK, TICKLEN, TITLE, [XYZ]CHARSIZE, [XYZ]GRIDSTYLE, [XYZ]MARGIN, [XYZ]MINOR, [XYZ]RANGE, [XYZ]STYLE, [XYZ]THICK, [XYZ]TICKFORMAT, [XYZ]TICKINTERVAL, [XYZ]TICKLAYOUT, [XYZ]TICKLEN, [XYZ]TICKNAME, [XYZ]TICKS, [XYZ]TICKUNITS, [XYZ]TICKV, [XYZ]TICK_GET, [XYZ]TITLE, ZVALUE</computeroutput>).
222      </para>
223      <simpara>
224        It can therefore be customized <emphasis>as much as you want</emphasis>. See this short example:
225      </simpara>
226      <para>
227        <screen format="linespecific">
228  <prompt>&promptidl;</prompt> <userinput><command>splot, y, y^2, linestyle = 2, thick = 2, title = 'y = x^2', /portrait</command></userinput> <ulink url="figpng/basic_splot2.png?format=raw">&showfig;</ulink>
229        </screen>
230        <command>splot</command> can be used to setup the graphic environment (<varname>!p</varname>, <varname>!x</varname>, <varname>!y</varname>, <varname>!z</varname> variables) needed by procedures like <command>oplot</command>
231        <screen format="linespecific">
232  <prompt>&promptidl;</prompt> <userinput><command>splot, y, yrange = [0, (n-1)^2], title = 'x and x^2'</command></userinput>
233  <prompt>&promptidl;</prompt> <userinput><command>oplot, y^2, color = 50, linestyle = 2</command></userinput> <ulink url="figpng/basic_splot4.png?format=raw">&showfig;</ulink>
234        </screen>
235        Use the keyword small to produce multi plots figures.
236        <screenco>
237          <areaspec>
238            <areaset id="small" coords="">
239              <area id="small.1" coords='1'/>
240              <area id="small.2" coords='2'/>
241            </areaset>
242            <area id="noerase" coords='2'/>
243          </areaspec>
244        <screen format="linespecific">
245  <prompt>&promptidl;</prompt> <userinput><command>splot, y, y^2, title = 'y = x^2', psym = 2, small &numb1; = [1, 2, 1]</command></userinput>
246  <prompt>&promptidl;</prompt> <userinput><command>splot, findgen(360)/36., findgen(360)*2.*!dtor, /polar $</command></userinput>
247  <prompt>&promptidl;</prompt> <userinput><command>    , small &numb1; = [1, 2, 2], /noerase &numb2;</command></userinput> <ulink url="figpng/basic_splot3.png?format=raw">&showfig;</ulink>
248        </screen>
249          <calloutlist>
250            <callout arearefs="small">
251              <para>
252                the <computeroutput>small</computeroutput> keyword is a 3 elements vector which defines how we devide the page and in which case we should make the plot: [number of columns, number of rows, case number]. The case numbering is starting at 1, from top to bottom and left to right.
253              </para>
254            </callout>
255            <callout arearefs="noerase">
256              <simpara>
257                you must put <computeroutput>/norease</computeroutput> otherwise the second plot will be done in a new window.
258              </simpara>
259            </callout>
260          </calloutlist>
261        </screenco>
262      </para>
263     
264      </sect3>
265
266      <sect3 id="basic_contour">
267      <title>
268        scontour
269      </title>
270      <para>
271        Following <command><link linkend="basic_splot">splot</link></command> example, we provide <command>scontour</command> as a "super <command>contour</command>".
272        <screen format="linespecific">
273  <prompt>&promptidl;</prompt> <userinput><command>z = dist(n)</command></userinput>
274  <computeroutput>% Compiled module: DIST.</computeroutput>
275  <prompt>&promptidl;</prompt> <userinput><command>scontour, z</command></userinput> <ulink url="figpng/basic_scontour1.png?format=raw">&showfig;</ulink>
276  <computeroutput>% Compiled module: SCONTOUR.</computeroutput>
277  <computeroutput>% Compiled module: CHKSTRU.</computeroutput>
278        </screen>
279        <command>scontour</command> accepts the same keywords as <command>contour</command> (<computeroutput>C_ANNOTATION=vector_of_strings, C_CHARSIZE=value, C_CHARTHICK=integer, C_COLORS=vector, C_LABELS=vector{each element 0 or 1}, C_LINESTYLE=vector, { /FILL | /CELL_FILL | C_ORIENTATION=degrees}, C_SPACING=value, C_THICK=vector, /CLOSED, /DOWNHILL, /FOLLOW, /IRREGULAR, /ISOTROPIC, LEVELS=vector, NLEVELS=integer{1 to 60}, MAX_VALUE=value, MIN_VALUE=value, /OVERPLOT, {/PATH_DATA_COORDS, PATH_FILENAME=string, PATH_INFO=variable, PATH_XY=variable}, TRIANGULATION=variable, /PATH_DOUBLE, /XLOG, /YLOG, ZAXIS={0 | 1 | 2 | 3 | 4}</computeroutput>), including the <link linkend="gr_kwd">graphics keywords</link> (except <computeroutput>LINESTYLE, PSYM, SYMSIZE</computeroutput>).
280      </para>
281      <simpara>It can therefore be customized <emphasis>as much as you want</emphasis>. See these short examples:</simpara>
282      <para>
283        <screen format="linespecific">
284  <prompt>&promptidl;</prompt> <userinput><command>scontour, z, /fill, nlevels = 15, subtitle = 'nicer contour' $</command></userinput>
285  <prompt>&promptidl;</prompt> <userinput><command>    , xtitle = 'x index', charsize = 1.5</command></userinput> <ulink url="figpng/basic_scontour2.png?format=raw">&showfig;</ulink>
286        </screen>
287It can be used in combinanson with contour to make more complex plots:
288        <screenco>
289          <areaspec>
290            <area id="rebin" coords='1'/>
291          </areaspec>
292        <screen format="linespecific">
293  <prompt>&promptidl;</prompt> <userinput><command>ind = findgen(2*n)/(2.*n)</command></userinput>
294  <prompt>&promptidl;</prompt> <userinput><command>scontour, z, levels = n*ind, c_orientation = 180*ind, c_spacing = 0.4*ind</command></userinput>
295  <prompt>&promptidl;</prompt> <userinput><command>contour, z, /overplot, c_label = rebin([1, 0], 2, n) &numb1;, levels = n*ind $</command></userinput>
296  <prompt>&promptidl;</prompt> <userinput><command>    , c_charthick = 2, c_charsize = 1.5, c_colors = 250*ind</command></userinput> <ulink url="figpng/basic_scontour3.png?format=raw">&showfig;</ulink>
297        </screen>
298        <calloutlist>
299          <callout arearefs="rebin">
300            <para>
301              <command>rebin</command> is used to build an array containing an alternation of 1 and 0 in order to label one contour every two contours.
302                <screen format="linespecific">
303  <prompt>&promptidl;</prompt> <userinput><command>print, rebin([1, 0], 2, 3)</command></userinput>
304  <computeroutput>       1       0</computeroutput>
305  <computeroutput>       1       0</computeroutput>
306  <computeroutput>       1       0</computeroutput>
307                </screen>
308            </para>
309          </callout>
310        </calloutlist>
311        </screenco>
312        <command>scontour</command> is compatible with the positioning method associated with the <computeroutput>small</computeroutput> keyword. See for example the test file <ulink url="../../Tests/tst_basic.pro?format=raw"><filename>tst_basic.pro</filename></ulink>:
313        <screen format="linespecific">
314  <prompt>&promptidl;</prompt> <userinput><command>tst_basic</command></userinput> <ulink url="figpng/tst_basic.png?format=raw">&showfig;</ulink>
315        </screen>
316      </para>
317      </sect3>
318
319      <sect3 id="tvplus">
320        <title>
321          Quick look at 2D arrays: tvplus
322        </title>
323        <para>
324          <command>tvplus</command> is a enhanced version of tvscl and allow you to have a quick look and perform basic exploration of 2D arrays.
325          <screen format="linespecific">
326            <prompt>&promptidl;</prompt> <userinput><command>tvplus, dist(20)</command></userinput> <ulink url="figpng/tvplus.png?format=raw">&showfig;</ulink>
327  <computeroutput>left button  : mouse position and associated array value</computeroutput>
328  <computeroutput>middle button: use it twice to define a zoom box</computeroutput>
329  <computeroutput>right button : quit</computeroutput>
330  <computeroutput>(x, y) = (  5,   5), value = 7.07107</computeroutput>
331  <computeroutput>(x, y) = ( 12,   8), value = 11.3137</computeroutput>
332          </screen>
333          For more informations on <command>tvplus</command>, try:
334          <screen format="linespecific">
335  <prompt>&promptidl;</prompt> <userinput><command>xhelp, 'tvplus'</command></userinput>
336          </screen>
337        </para>
338      </sect3>
339    </sect2>
340  </sect1>
341
342  <sect1 id="gridded_data">
343    <title>
344      Explore gridded data (model outputs and observations)
345    </title>
346    <para>
347      This section briefly describes the main fonctionalities offered by SAXO to explore gridded data on regular or irregular grid.
348    </para>
349
350    <sect2 id="load_grid">
351      <title>
352        Load the data grid
353      </title>
354      <para>
355        As we focus in this section on the gridded data, we must first load the grid informations before reading and plotting the data. Loading the grid independently of the data allow you to reload the grid only when it is strictly necessary and not every time you access the data. In <filename class="directory"><envar>${HOME}</envar>/SAXO_DIR/Tests/</filename>, we provide several examples to load a grid.
356      </para>
357      <sect3 id="load_fromdata">
358        <title>
359          Easiest solution: load data grid (regular or not) directly from the data file.
360        </title>
361        <para>
362          Example of Levitus temprature on a regular 1x1 grid.
363          <screen format="linespecific">
364  <prompt>&promptidl;</prompt> <userinput><command>@tst_initlev</command></userinput>
365  <computeroutput>% Compiled module: INITNCDF.</computeroutput>
366  <computeroutput>% Compiled module: ISAFILE.</computeroutput>
367  <computeroutput>% Compiled module: UNIQ.</computeroutput>
368  <computeroutput>% Loaded DLM: NCDF.</computeroutput>
369  <computeroutput>% Compiled module: COMPUTEGRID.</computeroutput>
370  <computeroutput>% Compiled module: DOMDEF.</computeroutput>
371  <computeroutput>% Compiled module: INTER.</computeroutput>
372  <computeroutput>% Compiled module: TRIANGULE.</computeroutput>
373  <computeroutput>% Compiled module: TRIANGULE_C.</computeroutput>
374  <computeroutput>% Compiled module: UNDEFINE.</computeroutput>
375  <computeroutput>% Compiled module: TESTVAR.</computeroutput>
376  <computeroutput>% Compiled module: DIFFERENT.</computeroutput>
377  <computeroutput>% Compiled module: DEFINETRI.</computeroutput>
378          </screen>
379          This <ulink url="../../Tests/tst_initlev.pro?format=raw"><command>@tst_initlev</command></ulink> command allows us to define:
380          <itemizedlist>
381            <listitem><simpara>domain dimensions, stored in <varname>jpi, jpj and jpk</varname></simpara></listitem>
382            <listitem><simpara>points abscissa, stored in 2D array <varname></varname>glamt</simpara></listitem>
383            <listitem><simpara>points ordinates, stored in 2D array <varname></varname>gphit</simpara></listitem>
384            <listitem><simpara>points depths, stored in 1D array <varname></varname>gdept</simpara></listitem>
385            <listitem><simpara>cells corners abscissa, storde in 2D array <varname></varname>glamf</simpara></listitem>
386            <listitem><simpara>cells corners ordinates, stored in 2D array <varname></varname>gphif</simpara></listitem>
387            <listitem><simpara>cells upper bondary depth, stored in 1D array <varname></varname>gdepw</simpara></listitem>
388            <listitem><simpara>land-sea mask, stored in <varname></varname>tmask</simpara></listitem>
389            <listitem><simpara>the cells size in the longitudinal direction, stored in 2D array <varname></varname>e1t</simpara></listitem>
390            <listitem><simpara>the cells size in the latitudinal direction, stored in 2D array <varname></varname>e2t</simpara></listitem>
391            <listitem><simpara>the cells size in the vertical direction, stored in 1D array <varname></varname>e3t</simpara></listitem>
392            <listitem><simpara>the triangulation used to fill the land points, stored in <varname></varname>triangles_list</simpara></listitem>
393          </itemizedlist>
394
395          <screen format="linespecific">
396  <prompt>&promptidl;</prompt> <userinput><command>help, jpi,jpj,jpk</command></userinput>
397  <computeroutput>JPI (LOCAL_COORD)   LONG      =          360</computeroutput>
398  <computeroutput>JPJ (LOCAL_COORD)   LONG      =          180</computeroutput>
399  <computeroutput>JPK (LOCAL_COORD)   LONG      =           33</computeroutput>
400  <prompt>&promptidl;</prompt> <userinput><command>help, glamt, gphit,glamf, gphif</command></userinput>
401  <computeroutput>GLAMT (LONGITUDES)  FLOAT     = Array[360, 180]</computeroutput>
402  <computeroutput>GPHIT (LATITUDES)   FLOAT     = Array[360, 180]</computeroutput>
403  <computeroutput>GLAMF (LONGITUDES)  FLOAT     = Array[360, 180]</computeroutput>
404  <computeroutput>GPHIF (LATITUDES)   FLOAT     = Array[360, 180]</computeroutput>
405  <prompt>&promptidl;</prompt> <userinput><command>help, gdept, gdepw</command></userinput>
406  <computeroutput>GDEPT (VERTICAL)    FLOAT     = Array[33]</computeroutput>
407  <computeroutput>GDEPW (VERTICAL)    FLOAT     = Array[33]</computeroutput>
408  <prompt>&promptidl;</prompt> <userinput><command>help, e1t, e2t, e3t</command></userinput>
409  <computeroutput>E1T (SCALE_FACTORS) FLOAT     = Array[360, 180]</computeroutput>
410  <computeroutput>E2T (SCALE_FACTORS) FLOAT     = Array[360, 180]</computeroutput>
411  <computeroutput>E3T (VERTICAL)      FLOAT     = Array[33]</computeroutput>
412  <prompt>&promptidl;</prompt> <userinput><command>help, tmask</command></userinput>
413  <computeroutput>TMASK (MASKS)       BYTE      = Array[360, 180, 33]</computeroutput>
414  <prompt>&promptidl;</prompt> <userinput><command>help, triangles_list</command></userinput>
415  <computeroutput>TRIANGLES_LIST (LIEES_A_TRIANGULE) LONG      = Array[3, 128880]</computeroutput>
416  <prompt>&promptidl;</prompt> <userinput><command>tvplus, glamt*tmask[*,*,0]</command></userinput>
417  <prompt>&promptidl;</prompt> <userinput><command>tvplus, gphit*tmask[*,*,0]</command></userinput>
418          </screen>
419          We provide other initialization methods/examples
420          <itemizedlist>
421            <listitem><simpara><ulink url="../../Tests/tst_initorca2_short.pro?format=raw">@tst_initorca2_short</ulink> : ORCA2 example</simpara></listitem>
422            <listitem><simpara><ulink url="../../Tests/tst_initorca05_short.pro?format=raw">@tst_initorca05_short</ulink> : ORCA05 example</simpara></listitem>
423            <listitem><simpara><ulink url="../../Tests/tst_initlev_stride.pro?format=raw">@tst_initlev_stride</ulink> : same as @tst_initlev but we skip on point over 2 in x and y direction</simpara></listitem>
424            <listitem><simpara><ulink url="../../Tests/tst_initorca2_short_stride.pro?format=raw">@tst_initorca2_short_stride</ulink> : ORCA2 with stride</simpara></listitem>
425            <listitem><simpara><ulink url="../../Tests/tst_initorca05_short_stride.pro?format=raw">@tst_initorca05_short_stride</ulink> : ORCA05 with stride</simpara></listitem>
426            <listitem><simpara><ulink url="../../Tests/tst_initlev_index.pro?format=raw">@tst_initlev_index</ulink> : in that case we load the grid using points index as axis instead of the longitude/latitude position</simpara></listitem>
427            <listitem><simpara><ulink url="../../Tests/tst_initorca2_index.pro?format=raw">@tst_initorca2_index</ulink> : load ORCA2 as it see by the model</simpara></listitem>
428            <listitem><simpara><ulink url="../../Tests/tst_initorca05_index.pro?format=raw">@tst_initorca05_index</ulink> : load ORCA05 as it see by the model</simpara></listitem>
429            <listitem><simpara><ulink url="../../Tests/tst_initlev_index_stride.pro?format=raw">@tst_initlev_index_stride</ulink> : @tst_initlev_index with stride</simpara></listitem>
430            <listitem><simpara><ulink url="../../Tests/tst_initorca2_index_stride.pro?format=raw">@tst_initorca2_index_stride</ulink> : ORCA2 in index with stride</simpara></listitem>
431            <listitem><simpara><ulink url="../../Tests/tst_initorca05_index_stride.pro?format=raw">@tst_initorca05_index_stride</ulink> : ORCA05 in index with stride</simpara></listitem>
432          </itemizedlist>
433        </para>
434      </sect3>
435      <sect3 id="load_meshmask">
436        <title>
437          Load the grid from OPA <filename>meshmask</filename> file
438        </title>
439        <para>
440          When the grid is really irregular (its abscissa and ordinate cannot be descried by a vector), loading the grid directly from the data forces us to make an approximation when computing the grid corners position and the cells size. In that case, it can be preferable to load the grid from the meshmask file created by OPA. As OPA use a Arakawa-C discretization, loading the grid from the meshmask will also define all parameters related to the U, V and F grids (glam[uv],gphi[uv], e[12][uvf]). Note that, when using a simple <link linkend="load_fromdata">grid definition from the data itself</link> (with <filename>initncdf</filename> or <filename>computegrid</filename>), adding the keyword /FULLCGRID leads also to the definition of all U, V and F grids parameters. There is the examples to load ORCA grids from OPA meshmask.
441          <itemizedlist>
442            <listitem><simpara><ulink url="../../Tests/tst_initorca2.pro?format=raw">@tst_initorca2</ulink> : ORCA2</simpara></listitem>
443            <listitem><simpara><ulink url="../../Tests/tst_initorca05.pro?format=raw">@tst_initorca05</ulink> : ORCA05</simpara></listitem>
444            <listitem><simpara><ulink url="../../Tests/tst_initorca2_stride.pro?format=raw">@tst_initorca2_stride</ulink> : ORCA2 with stride</simpara></listitem>
445            <listitem><simpara><ulink url="../../Tests/tst_initorca05_stride.pro?format=raw">@tst_initorca05_stride</ulink> : ORCA05 with stride</simpara></listitem>
446            <listitem><simpara><ulink url="../../Tests/tst_initorca2_index.pro?format=raw">@tst_initorca2_index</ulink> : load ORCA2 as it see by the model</simpara></listitem>
447            <listitem><simpara><ulink url="../../Tests/tst_initorca05_index.pro?format=raw">@tst_initorca05_index</ulink> : load ORCA05 as it see by the model</simpara></listitem>
448            <listitem><simpara><ulink url="../../Tests/tst_initorca2_index_stride.pro?format=raw">@tst_initorca2_index_stride</ulink> : ORCA2 in index with stride</simpara></listitem>
449            <listitem><simpara><ulink url="../../Tests/tst_initorca05_index_stride.pro?format=raw">@tst_initorca05_index_stride</ulink> : ORCA05 in index with stride</simpara></listitem>
450          </itemizedlist>
451        </para>
452        </sect3>
453    </sect2>
454
455    <sect2 id="plt">
456      <title>
457        horizontal plots and maps
458      </title>
459        <para>
460          A quick presentation of horizontal plots and maps is shown in <ulink url="../../Tests/tst_plt.pro?format=raw">tst_plt</ulink>. After laoding any of the grid (for example with one of the <link linkend="load_grid">above examples</link>). Just try:
461          <screen format="linespecific">
462  <prompt>&promptidl;</prompt> <userinput><command>tst_plt</command></userinput>
463          </screen>
464        </para>
465        <simpara><emphasis>Beware, the command is <command>tst_plt</command> and not <command>@tst_plt</command> as <filename>tst_plt.pro</filename> is a procedure and not an include.</emphasis></simpara>
466        <para>
467          See the results with
468          <itemizedlist>
469          <listitem><simpara><command>@tst_initlev</command>&figsplt_lev;</simpara></listitem>
470          <listitem><simpara><command>@tst_initorca2</command>&figsplt_orca2;</simpara></listitem>
471          <listitem><simpara><command>@tst_initorca05</command>&figsplt_orca05;</simpara></listitem>
472          <listitem><simpara><command>@tst_initlev_stride</command>&figsplt_lev_stride;</simpara></listitem>
473          <listitem><simpara><command>@tst_initorca2_stride</command>&figsplt_orca2_stride;</simpara></listitem>
474          <listitem><simpara><command>@tst_initorca05_stride</command>&figsplt_orca05_stride;</simpara></listitem>
475          </itemizedlist>
476        </para>
477    </sect2>
478
479    <sect2 id="pltz">
480      <title>
481        vertical sections
482      </title>
483        <para>
484          A quick presentation of vertical sections is shown in <ulink url="../../Tests/tst_pltz.pro?format=raw">tst_pltz</ulink>. After laoding any of the grid (for example with one of the <link linkend="load_grid">above examples</link>). Just try:
485          <screen format="linespecific">
486  <prompt>&promptidl;</prompt> <userinput><command>tst_pltz</command></userinput>
487          </screen>
488        </para>
489          <simpara><emphasis>Beware, the command is <command>tst_pltz</command> and not <command>@tst_pltz</command> as <filename>tst_pltz.pro</filename> is a procedure and not an include.</emphasis></simpara>         
490        <para>
491          See the results with
492          <itemizedlist>
493          <listitem><simpara><command>@tst_initlev</command>&figspltz_lev;</simpara></listitem>
494          <listitem><simpara><command>@tst_initorca2</command>&figspltz_orca2;</simpara></listitem>
495          <listitem><simpara><command>@tst_initorca05</command>&figspltz_orca05;</simpara></listitem>
496          <listitem><simpara><command>@tst_initlev_stride</command>&figspltz_lev_stride;</simpara></listitem>
497          <listitem><simpara><command>@tst_initorca2_stride</command>&figspltz_orca2_stride;</simpara></listitem>
498          <listitem><simpara><command>@tst_initorca05_stride</command>&figspltz_orca05_stride;</simpara></listitem>
499          </itemizedlist>
500        </para>
501    </sect2>
502
503    <sect2 id="pltt">
504      <title>
505        hovmoellers and time series
506      </title>
507        <para>
508          A quick presentation of hovmoellers and time series is shown in <ulink url="../../Tests/tst_pltt.pro?format=raw">tst_pltt</ulink>. After laoding any of the grid (for example with one of the <link linkend="load_grid">above examples</link>). Just try:
509          <screen format="linespecific">
510  <prompt>&promptidl;</prompt> <userinput><command>tst_pltt</command></userinput>
511          </screen>
512        </para>
513          <simpara><emphasis>Beware, the command is <command>tst_pltt</command> and not <command>@tst_pltt</command> as <filename>tst_pltt.pro</filename> is a procedure and not an include.</emphasis></simpara>
514        <para>
515          See the results with
516          <itemizedlist>
517          <listitem><simpara><command>@tst_initlev</command>&figspltt_lev;</simpara></listitem>
518          <listitem><simpara><command>@tst_initorca2</command>&figspltt_orca2;</simpara></listitem>
519          <listitem><simpara><command>@tst_initorca05</command>&figspltt_orca05;</simpara></listitem>
520          <listitem><simpara><command>@tst_initlev_stride</command>&figspltt_lev_stride;</simpara></listitem>
521          <listitem><simpara><command>@tst_initorca2_stride</command>&figspltt_orca2_stride;</simpara></listitem>
522          <listitem><simpara><command>@tst_initorca05_stride</command>&figspltt_orca05_stride;</simpara></listitem>
523          </itemizedlist>
524        </para>
525    </sect2>
526
527    <sect2 id="plt1d">
528      <title>
529        1D plots
530      </title>
531        <para>
532          To be continued...
533        </para>
534   </sect2>
535
536
537  </sect1>
538 
539</article>
Note: See TracBrowser for help on using the repository browser.