~ubuntu-branches/ubuntu/karmic/grace/karmic

« back to all changes in this revision

Viewing changes to doc/UsersGuide.sgml

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-07 19:11:41 UTC
  • mfrom: (1.2.1 upstream) (2.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20050107191141-hnwj3sa0kg7eg4vy
Tags: 1:5.1.18-1
* new upstream release
* added Conflicts: grace6

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
 
5
5
<article>
6
6
 
7
 
<title>Grace User's Guide (for Grace-5.1.7)</title>
 
7
<title>Grace User's Guide (for Grace-5.1.18)</title>
8
8
<author>by the Grace Team</author>
9
 
<date>16.03.2002</date>
 
9
<date>28.12.2004</date>
10
10
<abstract>
11
11
  This document explains the usage of
12
12
  <bf>Grace</bf>, a WYSIWYG 2D plotting tool for numerical data.
23
23
     Grace is a WYSIWYG tool to make two-dimensional plots of numerical
24
24
     data. It runs under various (if not all) flavors of Unix with X11
25
25
     and M*tif (LessTif or Motif). It also runs under VMS, OS/2, and
26
 
     Windows (95/98/NT/2000). Its capabilities are roughly similar to
 
26
     Windows (95/98/NT/2000/XP). Its capabilities are roughly similar to
27
27
     GUI-based programs like Sigmaplot or Microcal Origin plus
28
28
     script-based tools like Gnuplot or Genplot. Its strength lies in the
29
29
     fact that it combines the convenience of a graphical user interface
53
53
 
54
54
<tscreen><verb>
55
55
Copyright (&copy;) 1991-1995 Paul J Turner, Portland, OR
56
 
Copyright (&copy;) 1996-2002 Grace Development Team
 
56
Copyright (&copy;) 1996-2004 Grace Development Team
57
57
 
58
58
Maintained by Evgeny Stambulchik
59
59
 
130
130
              <item> The PDF driver requires the PDFlib library of Thomas
131
131
                     Merz to be installed, which is available
132
132
                     <url name="here" url="http://www.pdflib.com/">, version
133
 
                     3.02 or above.
 
133
                     4.0.3 or above.
134
134
              <item> If your computer has the FFTW library installed when
135
135
                     Grace is compiled, Grace will link itself to this, and
136
136
                     drop all conventional FFT's and DFT's. All transforms
294
294
          from the "Plot/Graph appearance popup". You can load the settings
295
295
          contained in a parameter file with File/Open.
296
296
 
297
 
      <sect2>Input File formats <label id="files-formats">
 
297
      <sect2>Input file formats <label id="files-formats">
298
298
        <p>
299
299
 
300
 
          Grace understands several input files formats. The most
301
 
          basic one is ASCII text files containing space and comma
302
 
          separated columns of data. The data fields can be either
303
 
          numeric (Fortran 'd' and 'D' exponent markers are supported)
304
 
          or alphanumeric (with or without quotes). Several calendar
305
 
          date formats are recognized automatically and you can
306
 
          specify your own reference for numeric dates formats. Grace also
307
 
          has a command language (see <ref id="command-interpreter"
308
 
          name="command interpreter">), you can include commands in
309
 
          data files using lines having "@" as their first non-blank
310
 
          character. Depending on configuration, Grace can also read
311
 
          NetCDF files (see <ref id="configuration" name="configuration">).
 
300
          Grace understands several input files formats. The most basic one
 
301
          is ASCII text files containing space and comma separated columns
 
302
          of data. The data fields can be either numeric (Fortran 'd' and
 
303
          'D' exponent markers are also supported) or alphanumeric (with or
 
304
          without quotes). Several calendar date formats are recognized
 
305
          automatically and you can specify your own reference for numeric
 
306
          date formats. Lines beginnig with "#" are ignored. Blank lines
 
307
          indicate new dataset.
 
308
          Grace also has a command language (see <ref
 
309
          id="command-interpreter" name="command interpreter">), you can
 
310
          include commands in data files using lines having "@" as their
 
311
          first non-blank character, though this is not recommended.
 
312
          Depending on configuration, Grace can also read NetCDF files (see
 
313
          <ref id="configuration" name="configuration">).
312
314
 
313
315
      <sect2>Graphs <label id="graph">
314
316
        <p>
325
327
             <item> Fixed Graph
326
328
             <item> Pie chart
327
329
          </itemize>
 
330
          
 
331
          The idea of "XY Chart" is to plot bars (or symbols in general) of
 
332
          several sets side by side, assuming the abscissas of all the sets are
 
333
          the same (or subsets of the longest set).
328
334
 
329
335
      <sect2>Datasets <label id="datasets">
330
336
        <p>
604
610
          <tag> -noprint </tag>
605
611
                In batch mode, do not print
606
612
 
 
613
          <tag> -nosafe </tag>
 
614
                Disable safe mode
 
615
 
607
616
          <tag> -nosigcatch </tag>
608
617
                Don't catch signals
609
618
 
634
643
          <tag> -rvideo </tag>
635
644
                Exchange the color indices for black and white
636
645
 
 
646
          <tag> -safe </tag>
 
647
                Run in the safe mode (default) - no file system modifications
 
648
                are allowd through the batch language
 
649
 
637
650
          <tag> -saveall <it>save_file</it> </tag>
638
651
                Save all graphs to save_file
639
652
 
691
704
               <p>
692
705
        <item> GRACE&lowbar;HELPVIEWER
693
706
               <p>
694
 
               The HTML viewer for on-line browsing of help documents
 
707
               The shell command to run an HTML viewer for on-line browsing of
 
708
               the help documents. Must include at least one instance of "%s"
 
709
               which will be replaced with the actual URL by Grace.
695
710
               <p>
696
711
        <item> GRACE&lowbar;FFTW&lowbar;WISDOM&lowbar;FILE and
697
712
               GRACE&lowbar;FFTW&lowbar;RAM&lowbar;WISDOM
1198
1213
      <p>
1199
1214
      You can link a set to a file or a pipe using this feature. Once
1200
1215
      a link has been established, you can update it (i.e., read data
1201
 
      again) by clicking on the update button. If you have specified a
1202
 
      command (using Grace language) in the corresponding text field
1203
 
      of the popup, it will be executed after each update. Note that
1204
 
      you can use several commands separated by ';' characters.
 
1216
      again) by clicking on the update button.
1205
1217
      <p>
1206
1218
      Currently, only simple XY sets can be used for hotlinks.
1207
1219
 
1303
1315
 
1304
1316
         <sect3> Fourier transforms <label id="fourier-transforms">
1305
1317
         <p>
1306
 
         This popup is devoted to direct and inverse Fourier
1307
 
         transforms. The default is to perform a direct transform on
1308
 
         unfiltered data and to produce a set with the index as
1309
 
         abscissa and magnitude as ordinate. You can filter the input
1310
 
         data window through triangular, Hanning, Welch, Hamming,
 
1318
         This popup is devoted to direct and inverse Fourier transforms
 
1319
         (actually, what is computed is a power spectrum). The default is to
 
1320
         perform a direct transform on unfiltered data and to produce a set
 
1321
         with the index as abscissa and magnitude as ordinate. You can filter
 
1322
         the input data window through triangular, Hanning, Welch, Hamming,
1311
1323
         Blackman and Parzen filters. You can load magnitude, phase or
1312
 
         coefficients and use either index, frequency or period as
1313
 
         abscissas. You can choose between direct and inverse Fourier
1314
 
         transforms. If you specify real input data, X is assumed to
1315
 
         be equally spaced and ignored; if you specify complex input
1316
 
         data X is taken as the real part and Y as the imaginary part.
 
1324
         coefficients and use either index, frequency or period as abscissas.
 
1325
         You can choose between direct and inverse Fourier transforms. If you
 
1326
         specify real input data, X is assumed to be equally spaced and
 
1327
         ignored; if you specify complex input data X is taken as the real part
 
1328
         and Y as the imaginary part.
1317
1329
 
1318
1330
         If Grace was configured with the FFTW library (see <ref
1319
1331
         name="configuration" id="configuration">), then the DFT and
1411
1423
         can be saved in a file and retrieved as needed using the file
1412
1424
         menu of the popup.
1413
1425
 
1414
 
         In the "Advanced" tab, you can additionally apply a restriction to the
1415
 
         set(s) to be fitted (thus ignoring points not satisfying the
1416
 
         criteria), use one of preset weighting schemes or define your own,
1417
 
         and choose whether to load the fitted values, the residuals or
1418
 
         the function itself. Choosing to load fitted values or residuals leads
1419
 
         to a set of the same length and abscissas as the initial set. Choosing
1420
 
         to load the function is almost similar to load the fitted values
1421
 
         except that you choose yourself the boundaries and the number of
1422
 
         points. This can be used for example to draw the curve outside of the
1423
 
         data sample range or to produce an evenly spaced set from an irregular
 
1426
         In the "Advanced" tab, you can additionally apply a restriction to
 
1427
         the set(s) to be fitted (thus ignoring points not satisfying the
 
1428
         criteria), use one of preset weighting schemes or define your own
 
1429
         (notice that "dY" in the preset "1/dY^2" one actually refers to the
 
1430
         third column of the data set; use the "Custom" function if this
 
1431
         doesn't make sense for your data set), and choose whether to load
 
1432
         the fitted values, the residuals or the function itself. Choosing
 
1433
         to load fitted values or residuals leads to a set of the same
 
1434
         length and abscissas as the initial set. Choosing to load the
 
1435
         function is almost similar to load the fitted values except that
 
1436
         you choose yourself the boundaries and the number of points. This
 
1437
         can be used for example to draw the curve outside of the data
 
1438
         sample range or to produce an evenly spaced set from an irregular
1424
1439
         one.
1425
1440
 
1426
1441
         <sect3> Correlation/covariance <label id="correlation/covariance">
1429
1444
         of one set or cross correlation between two sets. You only
1430
1445
         select the set (or sets) and specify the maximum lag. A check
1431
1446
         box allows one to evaluate covariance instead of correlation.
 
1447
         The result is normalized so that abs(C(0)) = 1.
1432
1448
 
1433
1449
         <sect3> Digital filter <label id="digital-filter">
1434
1450
         <p>
1683
1699
      the font tool, the character or command will be inserted at this
1684
1700
      position, not at the end of the string!
1685
1701
 
 
1702
      Most of the controls in the dialog should be self-explanatory. One
 
1703
      that is not (and frequently missed) is the "Axis transform"
 
1704
      input field in the "Tick labels" tab. Entering there e.g. "-$t"
 
1705
      will make the tick labels show negates of the real coordinates their
 
1706
      ticks are placed at. You can use any expression understood by the
 
1707
      interpreter (see <ref id="command-interpreter"
 
1708
      name="command interpreter">).
 
1709
      
1686
1710
      Once you have set the options as you want, you can apply
1687
1711
      them. One useful feature is that you can set several axes at
1688
1712
      once with the bottom pulldown menu (current axis, all axes
1830
1854
        indx |
1831
1855
          Non-negative iexpr |
1832
1856
          &nbsp; @
1833
 
        qstr |
1834
 
          Quoted string |
1835
 
          "a string" @
 
1857
        sexpr |
 
1858
          String expression |
 
1859
          "a string", "a " . "string", "square root of 4 = " . sqrt(4) @
1836
1860
        vexpr |
1837
1861
          Vector expression |
1838
1862
          "2*x" @
1890
1914
          set <it>nn</it> in the current graph|
1891
1915
          <it>nn</it>: 0-99 |
1892
1916
          S1 @
1893
 
        S_ |
1894
 
          the last allocated set in the current graph|
 
1917
        S&lowbar; |
 
1918
          the last implicitly (i.e. as a result of a data transformation) allocated set in the current graph|
1895
1919
          - |
1896
 
          S_ @
 
1920
          S&lowbar; @
1897
1921
        S$ |
1898
1922
          the active set in the current graph|
1899
1923
          - |
2008
2032
        <hline>
2009
2033
        Variable        | Description      @
2010
2034
        <hline>
2011
 
        datacolumn      | data column of current set @
 
2035
        datacolumn      | data column of current ("active") set @
2012
2036
        set.datacolumn  | data column of set @
2013
2037
        <hline>
2014
2038
        vvar            | user-defined array @
2046
2070
 
2047
2071
      In numerical expressions, the infix format is used. Arguments of
2048
2072
      both operators and functions can be either scalars or vector arrays.
2049
 
      
 
2073
      Arithmetic, logical, and comparison operators are 
 
2074
      given in tables below.
 
2075
            
2050
2076
      <p>
2051
2077
 
2052
2078
      <table loc="htbp">
2108
2134
      </table>
2109
2135
      
2110
2136
      <p>
 
2137
        
 
2138
        Another conditional operator is the "?:" (or ternary) operator, which
 
2139
        operates as in C and many other languages.
 
2140
 
 
2141
        (expr1) ? (expr2) : (expr3);
 
2142
 
 
2143
        This expression evaluates to expr2 if expr1 evaluates to TRUE, and
 
2144
        expr3 if expr1 evaluates to FALSE.
 
2145
      <p>
2111
2146
 
2112
2147
      <table loc="htbp">
2113
2148
      <tabular ca="ll">
2141
2176
        rand            | pseudo random number distributed uniformly on (0.0,1.0) @
2142
2177
        rand(n)         | array of n random numbers @
2143
2178
        rint(x)         | round to closest integer @
 
2179
        rsum(x)         | running sum of x @
2144
2180
        sin(x)          | sine function @
2145
2181
        sinh(x)         | hyperbolic sine @
2146
2182
        sqr(x)          | x^2 @
2250
2286
        AVG(x)      | average of array x             @
2251
2287
        SD(x)       | standard deviation of array x  @
2252
2288
        SUM(x)      | sum of all elements of array x @
 
2289
        INT(x,y)    | integral of y dx               @
 
2290
        IMIN(x)     | index of min value of array x  @
 
2291
        IMAX(x)     | index of max value of array x  @
2253
2292
        <hline>
2254
2293
      </tabular>
2255
2294
      <caption>
2261
2300
  <sect1>Procedures
2262
2301
    <p>
2263
2302
     Methods of directly manipulating the data corresponding to the
2264
 
     Data|Transformation menu are described in table
2265
 
     <ref id="transformations">. 
 
2303
     Data|Transformation menu are described in table <ref
 
2304
     id="transformations">. To evaluate expressions, you can directly submit
 
2305
     them to the command interpreter like you would in the evaluate expression
 
2306
     window. As an example, S1.X = S1.X * 0.000256 scales the x-axis
 
2307
     coordinates. The functionality of the 'Sample points' menu entry can be
 
2308
     obtained through RESTRICT.
2266
2309
 
2267
2310
      <table loc="htbp">
2268
2311
      <tabular ca="p{3cm}p{5cm}p{3.5cm}p{3cm}">
2269
2312
        <hline>
2270
2313
        Statement | Description | Types | Example @
2271
2314
        <hline>
 
2315
        RUNAVG (set, npoints) |
 
2316
          running average of <it>set</it> using <it>npoints</it> number of points |
 
2317
          nexpr <it>npoints</it> |
 
2318
          RUNAVG (S0, 100) @
 
2319
        RUNMED (set, npoints) |
 
2320
          running median of <it>set</it> using <it>npoints</it> number of points |
 
2321
          nexpr <it>npoints</it> |
 
2322
          RUNMED (S0, 100) @
 
2323
        RUNMIN (set, npoints) |
 
2324
          running minimum of <it>set</it> using <it>npoints</it> number of points |
 
2325
          nexpr <it>npoints</it> |
 
2326
          RUNMIN (S0, 100) @
 
2327
        RUNMAX (set, npoints) |
 
2328
          running maximum of <it>set</it> using <it>npoints</it> number of points |
 
2329
          nexpr <it>npoints</it> |
 
2330
          RUNMAX (S0, 100) @
 
2331
        RUNSTD (set, npoints) |
 
2332
          running standard deviation of <it>set</it> using <it>npoints</it> number of points |
 
2333
          nexpr <it>points</it> |
 
2334
          RUNSTD (S0, 100) @
2272
2335
        INTERPOLATE (set, mesh, method, strict) |
2273
2336
          interpolate <it>set</it> on a sampling <it>mesh</it> using <it>method</it>. <it>strict</it> flag controls whether result should be bound within the source set |
2274
2337
          vexpr <it>mesh</it>, <it>method</it>: one of LINEAR, SPLINE, and ASPLINE, onoff <it>strict</it> |
2284
2347
        RESTRICT (set, restriction) |
2285
2348
          filter <it>set</it> according to logical <it>restriction</it>. The original set will be overwritten |
2286
2349
          vexpr <it>restriction</it> |
2287
 
          RESTRICT (S0, x < 0) @
 
2350
          RESTRICT (S0, S0.X < 0) @
2288
2351
        RESTRICT (set, region, negate) |
2289
2352
          filter <it>set</it> by keeping only points lying inside/outside <it>region</it>. The original set will be overwritten |
2290
2353
          onoff <it>negate</it>|
2291
 
          RESTRICT (S0, x < 0) @
 
2354
          RESTRICT (S0, R1, OFF) @
2292
2355
        <hline>
2293
2356
      </tabular>
2294
2357
      <caption>
2339
2402
        <hline>
2340
2403
        Statement | Description | Types | Example @
2341
2404
        <hline>
2342
 
        PRINT |
2343
 
          execute print job |
2344
 
          &nbsp; |
2345
 
          PRINT @
2346
 
        SLEEP <it>n</it> |
2347
 
          sleep for <it>n</it> seconds |
2348
 
          expr <it>n</it> |
2349
 
          SLEEP(3) @
2350
2405
        EXIT(<it>status</it>) |
2351
2406
          cause normal program termination with exit status <it>status</it> |
2352
2407
          iexpr <it>status</it> |
2357
2412
          EXIT @
2358
2413
        HELP <it>url</it> |
2359
2414
          open a HTML document pointed to by <it>url</it> |
2360
 
          qstr <it>url</it> |
 
2415
          sexpr <it>url</it> |
2361
2416
          HELP "doc/FAQ.html" @
2362
2417
        HELP |
2363
2418
          open User's Guide |
2364
2419
          &nbsp; |
2365
2420
          HELP @
 
2421
        PRINT |
 
2422
          execute print job |
 
2423
          &nbsp; |
 
2424
          PRINT @
 
2425
        AUTOSCALE |
 
2426
          scale the graph |
 
2427
          &nbsp; |
 
2428
          AUTOSCALE @
 
2429
        AUTOSCALE XAXES |
 
2430
          scale the graph in x only |
 
2431
          &nbsp; |
 
2432
          AUTOSCALE XAXES @
 
2433
        AUTOSCALE YAXES |
 
2434
          scale the graph in y only |
 
2435
          &nbsp; |
 
2436
          AUTOSCALE YAXES @
 
2437
        AUTOSCALE set |
 
2438
          scale to a specific set |
 
2439
          &nbsp; |
 
2440
          AUTOSCALE S0 @
 
2441
        AUTOTICKS |
 
2442
          autotick all axes |
 
2443
          &nbsp; |
 
2444
          AUTOTICKS @
 
2445
        REDRAW |
 
2446
          refresh the canvas to reflect the current project state |
 
2447
          &nbsp; |
 
2448
          REDRAW @
 
2449
        SLEEP <it>n</it> |
 
2450
          sleep for <it>n</it> seconds |
 
2451
          expr <it>n</it> |
 
2452
          SLEEP(3) @
 
2453
        UPDATEALL |
 
2454
          update the GUI (graph and set selectors etc) to reflect the current project state |
 
2455
          &nbsp; |
 
2456
          UPDATEALL @
 
2457
        SAVEALL <it>"file"</it> |
 
2458
          save project to <it>file</it> |
 
2459
          sexpr <it>file</it> |
 
2460
          SAVEALL "foo.agr" @
 
2461
        LOAD <it>"file"</it> |
 
2462
          load project <it>file</it> |
 
2463
          sexpr <it>file</it> |
 
2464
          LOAD "foo.agr" @
2366
2465
        <hline>
2367
2466
      </tabular>
2368
2467
      <caption>
2506
2605
                  expr <it>ymin</it>| VIEW YMIN .25 @
2507
2606
         VIEW YMAX <it>ymax</it> | Sets top edge of current graph at y=<it>ymax</it> in the viewport | 
2508
2607
                  expr <it>ymax</it>| VIEW YMAX .75 @
 
2608
         VIEW <it>xmin</it>, <it>ymin</it>, <it>xmax</it>, <it>ymax</it>| Sets graph's viewport |
 
2609
                  expr <it>xmin</it>, <it>ymin</it>, <it>xmax</it>, <it>ymax</it>| VIEW 0.15, 0.15, 1.15, 0.85 @
2509
2610
         XAXES SCALE <it>type</it>  | Set scaling of the x axes to <it>type</it> |
2510
2611
                  <it>type</it>: one of NORMAL, LOGARITHMIC, or RECIPROCAL | XAXES SCALE NORMAL @
2511
2612
         YAXES SCALE <it>type</it>  | Set scaling of the y axes to <it>type</it>  |
2533
2634
        Statement | Description | Types | Example @
2534
2635
        <hline>
2535
2636
         TITLE <it>title</it>       | Sets the title of current graph |
2536
 
                  qstr <it>title</it> | TITLE "Foo" @
 
2637
                  sexpr <it>title</it> | TITLE "Foo" @
2537
2638
         TITLE FONT <it>font</it>  | Selects font of title string |
2538
2639
                  fontsel <it>font</it> | TITLE FONT 1 @
2539
2640
         TITLE SIZE <it>size</it>  | Sets size of title string |
2541
2642
         TITLE COLOR <it>color</it> | Sets color of title string | 
2542
2643
                  colorsel <it>color</it> | TITLE COLOR 1 @
2543
2644
         SUBTITLE <it>subtitle</it> | Sets the subtitle of current graph |
2544
 
                  qstr <it>subtitle</it> | SUBTITLE "Bar" @
 
2645
                  sexpr <it>subtitle</it> | SUBTITLE "Bar" @
2545
2646
         SUBTITLE FONT <it>font</it>  | Selects font of subtitle string |
2546
2647
                  fontsel <it>font</it> | SUBTITLE FONT "Times-Italic" @
2547
2648
         SUBTITLE SIZE <it>size</it>  | Sets size of subtitle string |
2611
2712
        <hline>
2612
2713
        Statement | Description | Types | Example @
2613
2714
        <hline>
2614
 
        READ <it>file</it> | Reads <it>file</it> as a single set |
2615
 
                             qstr <it>file</it> | READ "foo.dat" @
2616
 
        READ <it>settype</it> <it>file</it> | Reads <it>file</it> into a single set of type <it>settype</it> |
2617
 
                     xytype <it>settype</it>, qstr <it>file</it> | READ xydy "bar.dat" @
2618
 
        READ NXY <it>file</it> | Reads <it>file</it> as NXY data |
2619
 
                             qstr <it>file</it> | READ NXY "gad.dat" @
2620
 
        READ BLOCK <it>file</it> | Reads <it>file</it> as block data |
2621
 
                             qstr <it>file</it> | READ BLOCK "zooks.dat" @
 
2715
        READ <it>"file"</it> | Reads <it>file</it> as a single set |
 
2716
                             sexpr <it>file</it> | READ "foo.dat" @
 
2717
        READ <it>settype</it> <it>"file"</it> | Reads <it>file</it> into a single set of type <it>settype</it> |
 
2718
                     xytype <it>settype</it>, sexpr <it>file</it> | READ xydy "bar.dat" @
 
2719
        READ NXY <it>"file"</it> | Reads <it>file</it> as NXY data |
 
2720
                             sexpr <it>file</it> | READ NXY "gad.dat" @
 
2721
        READ BLOCK <it>"file"</it> | Reads <it>file</it> as block data |
 
2722
                             sexpr <it>file</it> | READ BLOCK "zooks.dat" @
2622
2723
        BLOCK <it>settype</it> <it>columns</it> | Forms a data set of type <it>settype</it> using <it>columns</it> from current block data file. |
2623
 
                     xytype <it>settype</it>, qstr <it>columns</it> | BLOCK xydxdy "0:2:1:3" @
 
2724
                     xytype <it>settype</it>, sexpr <it>columns</it> | BLOCK xydxdy "0:2:1:3" @
 
2725
        WRITE <it>set</it> | writes <it>set</it> to stdout|
 
2726
                     setsel <it>set</it> | WRITE G0.S1 @
 
2727
        WRITE <it>set</it> FORMAT <it>"formatstring"</it> | writes <it>set</it> to stdout using format specification <it>formatstring</it> |
 
2728
                     setsel <it>set</it> sexpr <it>formatstring</it> | WRITE G0.S1 FORMAT "%18.8g" @
 
2729
        WRITE <it>set</it> FILE <it>"file"</it> | writes <it>set</it> to <it>file</it> |
 
2730
                     setsel <it>set</it> sexpr <it>file</it> | WRITE G0.S1 FILE "data.dat" @
 
2731
        WRITE <it>set</it> FILE <it>"file"</it> FORMAT <it>"formatstring"</it> | writes <it>set</it> to <it>file</it> using format specification <it>formatstring</it> |
 
2732
                     setsel <it>set</it> sexpr <it>file</it> sexpr <it>formatstring</it> | WRITE G0.S1 FILE "data.dat" FORMAT "%18.8g" @
2624
2733
      </tabular>
2625
2734
      <caption>
2626
2735
        <label id="set-io">
2791
2900
        int GraceOpenVA    | (char *<it>exe</it>, int <it>buf&lowbar;size</it>, ...)
2792
2901
                                                | launch a Grace executable <it>exe</it> and open a communication channel with it using <it>buf&lowbar;size</it> bytes for data buffering. The remaining NULL-terminated list of options is command line arguments passed to the Grace process @
2793
2902
        int GraceOpen      | (int <it>buf&lowbar;size</it>)
2794
 
                                                | equivalent to GraceOpenVA("xmgrace", buf&lowbar;size, "-noask", NULL) @
 
2903
                                                | equivalent to GraceOpenVA("xmgrace", buf&lowbar;size, "-nosafe", "-noask", NULL) @
2795
2904
        int GraceIsOpen    | (void)             | test if a Grace subprocess is currently connected @
2796
2905
        int GraceClose     | (void)             | close the communication channel and exit the Grace subprocess @
2797
2906
        int GraceClosePipe | (void)             | close the communication channel and leave the Grace subprocess alone @
2837
2946
      </caption>
2838
2947
      </table>
2839
2948
 
2840
 
      <p> There is no fortran equivalent for the GracePrintf function,
 
2949
      <p> There is no Fortran equivalent for the GracePrintf function,
2841
2950
      you should format all the data and commands yourself before
2842
2951
      sending them with GraceCommandF.
2843
2952
 
2844
 
      The Grace subprocess listen for the commands you send and
2845
 
      interpret them as if they were given in a batch file. You can
 
2953
      The Grace subprocess listens for the commands you send and
 
2954
      interprets them as if they were given in a batch file. You can
2846
2955
      send any command you like (redraw, autoscale, ...). If you want
2847
2956
      to send data, you should include them in a command like "g0.s0
2848
2957
      point 3.5, 4.2".
2937
3046
}
2938
3047
 
2939
3048
</code></tscreen>
 
3049
    <p>
 
3050
      To compile this program, type
 
3051
      <tscreen><code>
 
3052
        cc example.c -lgrace_np
 
3053
      </code></tscreen>
 
3054
      If Grace wasn't properly installed, you may need to instruct the
 
3055
      compiler about include and library paths explicitly, e.g.
 
3056
      <tscreen><code>
 
3057
        cc -I/usr/local/grace/include example.c -L/usr/local/grace/lib -lgrace_np
 
3058
      </code></tscreen>
2940
3059
 
2941
3060
 <sect1>FFTW tuning<label id="fftw-tuning">
2942
3061
    <p>
2985
3104
              <hline>
2986
3105
      Grace type | Description   @
2987
3106
              <hline>
2988
 
f&lowbar;of&lowbar;i    | a function of 1 <tt/int/ variable                                 @
2989
 
f&lowbar;of&lowbar;d    | a function of 1 <tt/double/ variable                              @
2990
 
f&lowbar;of&lowbar;nn   | a function of 2 <tt/int/ parameters                               @
2991
 
f&lowbar;of&lowbar;nd   | a function of 1 <tt/int/ parameter and 1 <tt/double/ variable     @
2992
 
f&lowbar;of&lowbar;dd   | a function of 2 <tt/double/ variables                             @
2993
 
f&lowbar;of&lowbar;nnd  | a function of 2 <tt/int/ parameters and 1 <tt/double/ variable    @
2994
 
f&lowbar;of&lowbar;ppd  | a function of 2 <tt/double/ parameters and 1 <tt/double/ variable @
2995
 
f&lowbar;of&lowbar;pppd | a function of 3 <tt/double/ parameters and 1 <tt/double/ variable @
 
3107
f&lowbar;of&lowbar;i      | a function of 1 <tt/int/ variable                                 @
 
3108
f&lowbar;of&lowbar;d      | a function of 1 <tt/double/ variable                              @
 
3109
f&lowbar;of&lowbar;nn     | a function of 2 <tt/int/ parameters                               @
 
3110
f&lowbar;of&lowbar;nd     | a function of 1 <tt/int/ parameter and 1 <tt/double/ variable     @
 
3111
f&lowbar;of&lowbar;dd     | a function of 2 <tt/double/ variables                             @
 
3112
f&lowbar;of&lowbar;nnd    | a function of 2 <tt/int/ parameters and 1 <tt/double/ variable    @
 
3113
f&lowbar;of&lowbar;ppd    | a function of 2 <tt/double/ parameters and 1 <tt/double/ variable @
 
3114
f&lowbar;of&lowbar;pppd   | a function of 3 <tt/double/ parameters and 1 <tt/double/ variable @
 
3115
f&lowbar;of&lowbar;ppppd  | a function of 4 <tt/double/ parameters and 1 <tt/double/ variable @
 
3116
f&lowbar;of&lowbar;pppppd | a function of 5 <tt/double/ parameters and 1 <tt/double/ variable @
2996
3117
              <hline>
2997
3118
      </tabular>
2998
3119
      <caption>
3346
3467
               </itemize>
3347
3468
        <item> PDF driver:
3348
3469
               <itemize>
3349
 
                 <item> patterned fills are not implemented
3350
3470
                 <item> bitmapped text strings are not transparent
3351
3471
               </itemize>
3352
3472
        <item> MIF driver:
3353
 
               the driver is a brand new one and still in beta test
3354
3473
               <itemize>
3355
3474
                 <item> some of patterned fills not implemented
3356
3475
                 <item> bitmapped text strings not implemented
3357
3476
               </itemize>
3358
3477
        <item> SVG driver:
3359
 
               the driver is a brand new one and still in beta test
3360
3478
               <itemize>
3361
 
                 <item> patterned fills not implemented
3362
3479
                 <item> bitmapped text strings not implemented
3363
3480
               </itemize>
3364
3481
      </itemize>
3429
3546
              <hline>
3430
3547
              Command           | Description                        @
3431
3548
              <hline>
3432
 
              PDF1.2            | set compatibility mode to PDF-1.2  @
3433
3549
              PDF1.3            | set compatibility mode to PDF-1.3  @
 
3550
              PDF1.4            | set compatibility mode to PDF-1.4  @
3434
3551
              compression:value | set compression level (0 - 9)      @
 
3552
              patterns:on       | enable use of patterns             @
 
3553
              patterns:off      | disable use of patterns            @
3435
3554
              <hline>
3436
3555
      </tabular>
3437
3556
      <caption>