/usr/share/doc/geographiclib/html/Planimeter.1.html is in geographiclib-tools 1.21-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | <?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><link href="http://search.cpan.org/s/style.css" rel="stylesheet" type="text/css">
<title>Planimeter -- compute the area of geodesic polygons</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<link rev="made" href="mailto:root@localhost" />
</head>
<body style="background-color: white">
<!-- INDEX BEGIN -->
<div name="index">
<p><a name="__index__"></a></p>
<!--
<ul>
<li><a href="#name">NAME</a></li>
<li><a href="#synopsis">SYNOPSIS</a></li>
<li><a href="#description">DESCRIPTION</a></li>
<li><a href="#options">OPTIONS</a></li>
<li><a href="#examples">EXAMPLES</a></li>
<li><a href="#see_also">SEE ALSO</a></li>
<li><a href="#author">AUTHOR</a></li>
<li><a href="#history">HISTORY</a></li>
</ul>
-->
</div>
<!-- INDEX END -->
<p>
</p>
<hr />
<h1><a name="name">NAME</a></h1>
<p>Planimeter -- compute the area of geodesic polygons</p>
<p>
</p>
<hr />
<h1><a name="synopsis">SYNOPSIS</a></h1>
<p><strong>Planimeter</strong> [ <strong>-r</strong> ] [ <strong>-s</strong> ] [ <strong>-l</strong> ] [ <strong>-e</strong> <em>a</em> <em>f</em> ]
[ <strong>--comment-delimiter</strong> <em>commentdelim</em> ]
[ <strong>--version</strong> | <strong>-h</strong> | <strong>--help</strong> ]
[ <strong>--input-file</strong> <em>infile</em> | <strong>--input-string</strong> <em>instring</em> ]
[ <strong>--line-separator</strong> <em>linesep</em> ]
[ <strong>--output-file</strong> <em>outfile</em> ]</p>
<p>
</p>
<hr />
<h1><a name="description">DESCRIPTION</a></h1>
<p>Measure the area of a geodesic polygon. Reads polygon vertices from
standard input, one per line. Vertices may be given as latitude and
longitude, UTM/UPS, or MGRS coordinates, interpreted in the same way as
<a href="GeoConvert.1.html"><code>GeoConvert(1)</code></a>. (MGRS coordinates signify the center of the
corresponding MGRS square.) The end of input, a blank line, or a line
which can't be interpreted as a vertex signals the end of one polygon
and the start of the next. For each polygon print a summary line with
the number of points, the perimeter (in meters), and the area (in
meters^2).</p>
<p>By default, polygons traversed in a counter-clockwise direction return a
positive area and those traversed in a clockwise direction return a
negative area. This sign convention is reversed if the <strong>-r</strong> option is
given.</p>
<p>Of course, encircling an area in the clockwise direction is equivalent
to encircling the rest of the ellipsoid in the counter-clockwise
direction. The default interpretation used by <strong>Planimeter</strong> is the one
that results in a smaller magnitude of area; i.e., the magnitude of the
area is less than or equal to one half the total area of the ellipsoid.
If the <strong>-s</strong> option is given, then the interpretation used is the one
that results in a positive area; i.e., the area is positive and less
than the total area of the ellipsoid.</p>
<p>Only simple polygons are supported for the area computation. Polygons
may include one or both poles. There is no need to close the polygon.</p>
<p>
</p>
<hr />
<h1><a name="options">OPTIONS</a></h1>
<dl>
<dt><strong><a name="r" class="item"><strong>-r</strong></a></strong></dt>
<dd>
<p>toggle whether counter-clockwise traversal of the polygon returns a
positive (the default) or negative result.</p>
</dd>
<dt><strong><a name="s" class="item"><strong>-s</strong></a></strong></dt>
<dd>
<p>toggle whether to return a signed result (the default) or not.</p>
</dd>
<dt><strong><a name="l" class="item"><strong>-l</strong></a></strong></dt>
<dd>
<p>toggle whether the vertices represent a polygon (the default) or a
polyline. For a polyline, the number of points and the length of the
path joining them is returned; the path is not closed and the area is
not reported.</p>
</dd>
<dt><strong><a name="e" class="item"><strong>-e</strong></a></strong></dt>
<dd>
<p>specify the ellipsoid via <em>a</em> <em>f</em>; the equatorial radius is <em>a</em> and
the flattening is <em>f</em>. Setting <em>f</em> = 0 results in a sphere. Specify
<em>f</em> < 0 for a prolate ellipsoid. A simple fraction, e.g., 1/297,
is allowed for <em>f</em>. (Also, if <em>f</em> > 1, the flattening is set to
1/<em>f</em>.) By default, the WGS84 ellipsoid is used, <em>a</em> = 6378137 m,
<em>f</em> = 1/298.257223563. If entering vertices as UTM/UPS or MGRS
coordinates, use the default ellipsoid, since the conversion of these
coordinates to latitude and longitude uses the WGS84 parameters.</p>
</dd>
<dt><strong><a name="comment_delimiter" class="item"><strong>--comment-delimiter</strong></a></strong></dt>
<dd>
<p>set the comment delimiter to <em>commentdelim</em> (e.g., "#" or "//"). If
set, the input lines will be scanned for this delimiter and, if found,
the delimiter and the rest of the line will be removed prior to
processing. For a given polygon, the last such string found will be
appended to the output line (separated by a space).</p>
</dd>
<dt><strong><a name="version" class="item"><strong>--version</strong></a></strong></dt>
<dd>
<p>print version and exit.</p>
</dd>
<dt><strong><a name="h" class="item"><strong>-h</strong></a></strong></dt>
<dd>
<p>print usage and exit.</p>
</dd>
<dt><strong><a name="help" class="item"><strong>--help</strong></a></strong></dt>
<dd>
<p>print full documentation and exit.</p>
</dd>
<dt><strong><a name="input_file" class="item"><strong>--input-file</strong></a></strong></dt>
<dd>
<p>read input from the file <em>infile</em> instead of from standard input; a file
name of "-" stands for standard input.</p>
</dd>
<dt><strong><a name="input_string" class="item"><strong>--input-string</strong></a></strong></dt>
<dd>
<p>read input from the string <em>instring</em> instead of from standard input.
All occurrences of the line separator character (default is a semicolon)
in <em>instring</em> are converted to newlines before the reading begins.</p>
</dd>
<dt><strong><a name="line_separator" class="item"><strong>--line-separator</strong></a></strong></dt>
<dd>
<p>set the line separator character to <em>linesep</em>. By default this is a
semicolon.</p>
</dd>
<dt><strong><a name="output_file" class="item"><strong>--output-file</strong></a></strong></dt>
<dd>
<p>write output to the file <em>outfile</em> instead of to standard output; a
file name of "-" stands for standard output.</p>
</dd>
</dl>
<p>
</p>
<hr />
<h1><a name="examples">EXAMPLES</a></h1>
<p>Example (the area of the 100km MGRS square 18SWK)</p>
<pre>
Planimeter <<EOF
18N 500000 4400000
18N 600000 4400000
18N 600000 4500000
18N 500000 4500000
EOF
=> 4 400139.53295860 10007388597.1913</pre>
<p>The following code takes the output from gdalinfo and reports the area
covered by the data (assuming the edges of the image are geodesics).</p>
<pre>
#! /bin/sh
egrep '^((Upper|Lower) (Left|Right)|Center) ' |
sed -e 's/d /d/g' -e "s/' /'/g" | tr -s '(),\r\t' ' ' | awk '{
if ($1 $2 == "UpperLeft")
ul = $6 " " $5;
else if ($1 $2 == "LowerLeft")
ll = $6 " " $5;
else if ($1 $2 == "UpperRight")
ur = $6 " " $5;
else if ($1 $2 == "LowerRight")
lr = $6 " " $5;
else if ($1 == "Center") {
printf "%s\n%s\n%s\n%s\n\n", ul, ll, lr, ur;
ul = ll = ur = lr = "";
}
}
' | Planimeter | cut -f3 -d' '</pre>
<p>
</p>
<hr />
<h1><a name="see_also">SEE ALSO</a></h1>
<p><a href="GeoConvert.1.html"><code>GeoConvert(1)</code></a>. The algorithm for the area of geodesic polygon is given
in Section 15 of C. F. F. Karney, <em>Geodesics on an ellipsoid of
revolution</em>, Feb. 2011; preprint <a href="http://arxiv.org/abs/1102.1215">http://arxiv.org/abs/1102.1215</a>. See
also Section 6 of C. F. F. Karney, <em>Algorithms for geodesics</em>,
Sept. 2011; preprint <a href="http://arxiv.org/abs/1109.4448">http://arxiv.org/abs/1109.4448</a>.</p>
<p>
</p>
<hr />
<h1><a name="author">AUTHOR</a></h1>
<p><strong>Planimeter</strong> was written by Charles Karney.</p>
<p>
</p>
<hr />
<h1><a name="history">HISTORY</a></h1>
<p><strong>Planimeter</strong> was added to GeographicLib,
<a href="http://geographiclib.sf.net">http://geographiclib.sf.net</a>, in version 1.4.</p>
</body>
</html>
|