Changes between Version 2 and Version 3 of other/gmt


Ignore:
Timestamp:
10/22/09 14:15:05 (15 years ago)
Author:
Paul Gibbon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • other/gmt

    v2 v3  
    1 Using the GMT imaging software for 2D plots
     1=== Using the GMT imaging software for 2D plots ===
    22
    33Graphical output from PEPC can be created using the postprocessor slicer,
     
    88
    99The particle data is assumed to be in the form of the PEPC dump file:
    10 
     10{{{
    1111x, y, z, px, py, pz, q, m, Ex, Ey, Ez, potential, owner, plabel
     12}}}
    1213
    1314The postprocessor program slicer.f90 is in the tools directory. To (re)compile it, use:
    14 
     15{{{
    1516  > make clean
    1617  > make slicer
    17 
     18}}}
    1819The input files read by this program from the run directory are:
    19 
     20{{{
    2021   grid_defs.in
    2122   dumps/parts_info.TTTTTT
    2223   timestamps
    23 
     24}}}
    2425where TTTTTT is the snapshot timestep. This should be entered in the timestamps file,
    2526which may contain a snapshot series. If timestamps is empty, a new one will be generated by
     
    3233so care should be taken not to alter the order or integer/float representation of the numbers.
    3334The variable names in front of the equals sign can be changed, however.
    34 
     35{{{
    3536       n= 1000000        # particles to process
    3637     ngx= 200            # grid points in x
     
    105106
    106107 iskip3d=1
     108}}}
     109The slicer program can be used on its own to generate gridded data: these subsequently appear in a subdirectory TTTTTT corresponding to the to parts_info.TTTTTT.
    107110
    108 The slicer program can be used on its own to generate gridded data
    109  - these subsequently appear in a subdirectory TTTTTT corresponding to the to parts_info.TTTTTT.
     111Tips:[[BR]]
     112   1. Make sure the grid lengths (ie: xmax-xmin etc.) are easily divisible by the number of mesh points (ngx).[[BR]]
     113   2. Use a coarse grid to start with (eg 100x100x50) and refine later.[[BR]]
     114   3. For quick previews, reduce the number of particles read in.[[BR]]
    110115
    111 Tips:
    112 
    113    1. Make sure the grid lengths (ie: xmax-xmin etc.) are easily divisible by the number of mesh points (ngx).
    114    2. Use a coarse grid to start with (eg 100x100x50) and refine later.
    115    3. For quick previews, reduce the number of particles read in.
    116116
    117117For convenience, a number of scripts are made available which combine the slicer output
    118  with command-line graphics tools from the GMT (Generic Mapping Tools) package.
    119  The latter is assumed to be installed locally under $HOME/gmt, with the appropriate environment
    120  (GMTHOME) and path variables set. If not, it is freely available from
     118with command-line graphics tools from the GMT (Generic Mapping Tools) package.
     119The latter is assumed to be installed locally under $HOME/gmt, with the appropriate environment
     120(GMTHOME) and path variables set. If not, it is freely available from
    121121
    122 http://gmt.soest.hawaii.edu/
     122[http://gmt.soest.hawaii.edu/]
    123123
    124124The postprocessing scripts are located in pepc/bin and have the form:
    125 
     125{{{
    126126  make_density
    127127  make_snaps
    128 
     128}}}
    129129etc. Calling a script without parameters will usually result in a help message, for example:
    130 
     130{{{
    131131   > make_snaps
    132132   Call parameters:  run# runpp/nopp plot/noplot
    133133   >
    134 
     134}}}
    135135First, the script checks whether the particle data have already been merged from
    136136the 'pe' directories. If so, there will be a large file in dumps/parts_dump.TTTTTT
     
    141141
    142142The make_snaps script will produce snapshots for the whole sequence given in the timestamps
    143  file, eg: suppose the timestamps file contains:
    144 
     143file, eg: suppose the timestamps file contains:
     144{{{
    145145  000100
    146146  000200
    147147  000300
    148 
     148}}}
    149149Then:
    150 
     150{{{
    151151   > make_snaps disc1 runpp plot
    152 
     152}}}
    153153will perform the postprocessing and produce plots at timesteps 100, 200 and 300.
    154  The first parameter is an arbitary run label which will get stamped on the corner of the
    155  plots together with the date for identification purposes. Use the runpp option the first
    156  time you generate grid data, or if you change any parameters in the grid_defs.in file.
    157  Otherwise, nopp will use the available data and jump straight to the graphics tools.
    158  The noplot option can be used to suppress postscript image generation (postprocess only).
     154The first parameter is an arbitary run label which will get stamped on the corner of the
     155plots together with the date for identification purposes. Use the runpp option the first
     156time you generate grid data, or if you change any parameters in the grid_defs.in file.
     157Otherwise, nopp will use the available data and jump straight to the graphics tools.
     158The noplot option can be used to suppress postscript image generation (postprocess only).
    159159
    160160
    161161The plots are in high-quality postscript format and are placed in subdirectory pepc/plots/.
    162  A compressed tar file images.tar.gz containing all plots is also generated by the script.
    163  Fine-tuning of the plots can be done by editing the scripts - make_snaps, etc.
    164  This will require some knowledge of the GMT package, which is comprehensively documented
    165  in GMT_Docs.pdf and GMT_Tutorial.pdf from the distribution.
     162A compressed tar file images.tar.gz containing all plots is also generated by the script.
     163Fine-tuning of the plots can be done by editing the scripts - make_snaps, etc.
     164This will require some knowledge of the GMT package, which is comprehensively documented
     165in GMT_Docs.pdf and GMT_Tutorial.pdf from the distribution.