Function XYZ = aer2xyz(AER)
XYZ = aer2xyz(AER,epsilon)
returns the x,y,z coordinates of vectors given by their
azimuth, elevation and radius.
The matrices XYZ and AER contain a row for each vector,
and have obviously 3 columns.
The azimuth is the angle between the positive y axis and
the projection of the vector onto the x,y plane. The
azimuth is measured from the positive y axis and it is
positive in clockwise direction, as seen from a far point
on the the positive z axis. The azimuth is expressed in
degrees. Its canonical value ranges from 0 (inclusively)
to 360 (exclusively), or its value may be NaN, when the
elevation is -90 or +90 degrees. It is not necessary that
the input azimuth adheres to these limited values.
The elevation is the angle between the x,y plane and the
vector. The elevation is measured from the x,y plane, and
it is positive or negative, conforming to the sign of the
z component of the vector. The elevation is expressed in
degrees. Its canonical value ranges from -90 (inclusively)
to +90 (inclusively) degrees. It is not necessary that the
input elevation adheres to these limited values.
The radius is the length of the vector.
The optional second argument epsilon is a scalar for the
maximal error allowed to consider an elevation equal to
-90 or +90 degrees. Its default is 1e-6.
The function internally calls the following non-standard
m-file:
-- aer2aer.m
(c) 2026 fabien van mook
2026.08.20 release of this file within package "fvm-geometry" under GNU GPLv3+