Next: 6. GMT Map Projections
Up: 5. GMT Coordinate Transformations
Previous: 5.1.3 Cartesian Power projection
  Contents
  Index
Figure 5.6:
Polar (Cylindrical) transformation of
() coordinates.
|
This transformation converts polar coordinates (angle and radius )
to positions on a plot. Now
and
, hence it is similar
to a regular map projection because and are coupled and (i.e., ) has a 360 periodicity.
With input and output points both in the plane it is a two-dimensional projection.
The transformation comes in two flavors:
- Normally, is understood to be directions counter-clockwise from the horizontal axis, but we may choose
to specify an angular offset [whose default value is zero]. We will call this offset .
Then,
and
.
- Alternatively, can be interpreted to be azimuths clockwise from the vertical axis, yet we may again
choose to specify the angular offset [whose default value is zero].
Then,
and
.
Consequently, the polar transformation is defined by providing
- scale in inches/unit (-Jp) or full width of plot in inches (-JP)
- Optionally, insert a after pP to indicate CW azimuths rather than CCW directions
- Optionally, append / in degrees to indicate an angular offset [0]
As an example of this projection we will create a gridded data set
in polar coordinates
using grdmath, a RPN calculator that operates on or
creates grdfiles.
grdmath -R0/360/2/4 -I6/0.1 X 4 MUL PI MUL 180 DIV COS Y 2 POW MUL = test.grd
grdcontour test.grd -JP3i -B30Ns -P -C2 -S4 --PLOT_DEGREE_FORMAT=+ddd > GMT_polar.ps
rm -f test.grd
We used grdcontour to make a contour map of this data. Because
the data file only contains values with
, a donut
shaped plot appears in Figure 5.6.
Next: 6. GMT Map Projections
Up: 5. GMT Coordinate Transformations
Previous: 5.1.3 Cartesian Power projection
  Contents
  Index
Paul Wessel
2006-01-01