1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
|
- .. index:: ! grdrotater
- .. include:: ../module_supplements_purpose.rst_
- **********
- grdrotater
- **********
- |grdrotater_purpose|
- Synopsis
- --------
- .. include:: ../../common_SYN_OPTs.rst_
- **gmt grdrotater** *ingrdfile* |-E|\ *rot_file*\|\ *lon*/*lat*/*angle*
- |-G|\ *outgrdfile*
- [ |-A|\ *region* ]
- [ |-D|\ *rotoutline* ]
- [ |-F|\ *polygonfile* ]
- [ |-N| ]
- [ |SYN_OPT-R| ]
- [ |-S| ]
- [ |-T|\ *ages* ]
- [ |SYN_OPT-V| ]
- [ |SYN_OPT-b| ]
- [ |SYN_OPT-d| ]
- [ |SYN_OPT-h| ]
- [ |SYN_OPT-n| ]
- [ |SYN_OPT-:| ]
- [ |SYN_OPT--| ]
- |No-spaces|
- Description
- -----------
- **grdrotater** reads a geographical grid and reconstructs it given
- total reconstruction rotations. Optionally, the user may supply a
- clipping polygon in multiple-segment format; then, only the part of the
- grid inside the polygon is used to determine the reconstructed region. The
- outlines of the reconstructed region is also returned provided the
- rotated region is not the entire globe.
- Required Arguments
- ------------------
- *ingrdfile*
- Name of a grid file in geographical (lon, lat) coordinates.
- .. include:: explain_rots.rst_
- .. _-G:
- **-G**\ *outgrdfile*
- Name of output grid. This is the grid with the data reconstructed
- according to the specified rotation. If more than one reconstruction
- time is implied then *outgrdfile* must contain a C-format specifier
- to format a floating point number (reconstruction time) to text.
- Optional Arguments
- ------------------
- .. _-A:
- **-A**\ *region*
- Specify directly the region of the rotated grid. By default, the
- output grid has a region that exactly matches the extent of the rotated
- domain, but **-A** can be used to crop or extend this region to that
- provided via *region*.
- .. _-D:
- **-D**\ *rotoutline*
- Name of the grid polygon outline file. This represents the outline
- of the grid reconstructed to the specified time. If more than one reconstruction
- time is implied then *rotoutline* must contain a C-format specifier
- to format a floating point number (reconstruction time) to text.
- If only one time is implied and **-D** is not set then we write the
- polygon to stdout (but see **-N**).
- .. _-F:
- **-F**\ *polygonfile*
- Specify a multisegment closed polygon file that describes the inside
- area of the grid that should be projected [Default projects entire grid].
- .. _-N:
- **-N**
- Do Not output the rotated polygon outline [Default will write it to
- stdout, or to a file via **-D**].
- .. _-R:
- .. |Add_-Rgeo| unicode:: 0x20 .. just an invisible code
- .. include:: ../../explain_-Rgeo.rst_
- .. _-S:
- **-S**
- Skip the rotation of the grid, just rotate the polygon outline
- (requires **-F** if no grid is provided).
- .. _-T:
- **-T**\ *ages*
- Sets the desired reconstruction times. For a single time append
- the desired time. For an equidistant range of reconstruction times
- give **-T**\ *start*\ /\ *stop*\ /\ *inc*. Append **+n** if *inc* should
- be interpreted to mean *npoints* instead.
- For an non-equidistant set of reconstruction times please pass them
- via the first column in a file, e.g., **-T**\ *agefile*. If no **-T**
- option is given and **-E** specified a rotation file then we equate
- the rotation file times with the reconstruction times.
- .. _-V:
- .. |Add_-V| unicode:: 0x20 .. just an invisible code
- .. include:: ../../explain_-V.rst_
- .. |Add_-bi| replace:: [Default is 2 input columns].
- .. include:: ../../explain_-bi.rst_
- .. |Add_-bo| replace:: [Default is same as input].
- .. include:: ../../explain_-bo.rst_
- .. |Add_-d| unicode:: 0x20 .. just an invisible code
- .. include:: ../../explain_-d.rst_
- .. |Add_-h| unicode:: 0x20 .. just an invisible code
- .. include:: ../../explain_-h.rst_
- .. include:: ../../explain_colon.rst_
- .. include:: ../../explain_-n.rst_
- .. include:: ../../explain_help.rst_
- .. include:: ../../explain_grdresample2.rst_
- .. include:: explain_geodetic.rst_
- Examples
- --------
- To rotate the data defined by grid topo.nc and the polygon outline
- clip_path.txt, using a total reconstruction rotation with pole at (135.5,
- -33.0) and a rotation angle of 37.3 degrees and bicubic interpolation, try
- ::
- gmt grdrotater topo.nc -E135.5/-33/37.3 -V -Fclip_path.txt -Grot_topo.nc > rot_clip_path.txt
- To rotate the entire grid faa.nc back to 32 Ma using the rotation file
- *rotations.txt* and a bilinear interpolation, try
- ::
- gmt grdrotater faa.nc -Erotations.txt -T32 -V -Grot_faa.nc -nl > rot_faa_path.txt
- To just see how the outline of the grid large.nc will plot after the
- same rotation, try
- ::
- gmt grdrotater large.nc -Erotations.txt -T32 -V -S | gmt plot -Rg -JH180/6i -B30 -W0.5p \| gv -
- To rotate the grid topo.nc back to 100 Ma using the rotation file
- *rotations.txt* and request a reconstruction every 10 Myr, saving
- both grids and outlines to filenames that derive from templates, try
- ::
- gmt grdrotater topo.nc -Erotations.txt -T10/100/10 -V -Grot_topo_%g.nc -Drot_topo_path_%g.txt
- Let say you have rotated gridA.nc and gridB.nc, restricting each
- rotation to nodes inside polygons polyA.txt and polyB.txt, respectively,
- using rotation A = (123W,22S,16,4) and rotation B = (108W, 16S, -14.5),
- yielding rotated grids rot_gridA.nc and rot_gridB.nc. To determine the
- region of overlap between the rotated grids, we use :doc:`grdmath </grdmath>`:
- ::
- gmt grdmath 1 rot_gridA.nc ISNAN SUB 1 rot_gridB.nc ISNAN SUB 2 EQ = overlap.nc
- The grid overlap.nc now has 1s in the regions of overlap and 0
- elsewhere. You can use it as a mask or use :doc:`grdcontour </grdcontour>` **-D** to extract
- a polygon (i.e., a contour).
- Notes
- -----
- GMT distributes the EarthByte rotation model Global_EarthByte_230-0Ma_GK07_AREPS.rot.
- To use an alternate rotation file, create an environmental parameters named
- **GPLATES_ROTATIONS** that points to an alternate rotation file.
- See Also
- --------
- :doc:`backtracker`,
- :doc:`grdcontour </grdcontour>`,
- :doc:`gmtpmodeler`,
- :doc:`grdmath </grdmath>`,
- :doc:`grdpmodeler`,
- :doc:`grdspotter`,
- :doc:`hotspotter`,
- :doc:`originater`,
- :doc:`rotconverter`
|