azel — rotate 3-D Cartesian data in azimuth and elevation
converts between right-handed Cartesian coordinate systems,
an application-geometry system
x, y, z
and a viewer-embedded system
d, h, v.
These systems differ by rotation in azimuth and elevation
about their common origin.
Input comes from
and output goes to
if they are specified, otherwise
uses stdin and stdout, respectively.
Each line of input must contain three numbers separated by
option (q.v.) is specified,
interprets each triple as the
x, y, z
coordinates of a vector, and prints out its
d, h, v
Any other text on the input line beyond the triple is copied verbatim.
The command-line options and their meanings are given below.
Specifies azimuthal rotation of azim degrees. Default is 0.
Specifies elevation rotation of elev degrees. Default is 0.
Specifies a cell size of celsiz. Output vectors are scalar multiplied by 1/celsiz. Default is 1. Useful with the
-roption to bin output data into cells.
Causes azel to perform the inverse rotation. The input is transformed from viewer to application-geometry coordinates (i.e., from d, h, v to x, y, z). Incompatible with the
Causes azel to project the output vectors onto the hv plane. This gives grid-plane coordinates. Incompatible with the
Causes azel to round each coordinate of the output vectors to the nearest integer. Useful with the
-coption to bin output data into cells.
The viewer coordinates are defined so that positive d points toward the viewer, positive h (horizontal) points to the viewer's right, and positive v (vertical) points up. When azim = elev =0 , the two coordinate systems coincide, in which case azel performs the identity transformation. Azimuth is the angle in the dh plane from positive h to positive y, measured toward positive d. Elevation is the angle in the dv plane from positive v to positive z, measured toward positive d. In the forward direction the azimuthal rotation is performed before the elevation, while in the inverse direction, the elevation is undone before the azimuth. Thus, the z axis is always normal to the h axis. When azim = 90 and elev = 0, x = -h, y = d, and z = v. When azim = 0 and elev = 90, x = -v, y = h, and z = d.
This software is Copyright (c) 1991-2016 by the United States Government as represented by U.S. Army Research Laboratory.