This IDL facility convert the position angles of points on the sphere
into their 3D position vectors.
Location in HEALPix directory tree:
ANG2VEC , Theta, Phi, Vector [, ASTRO=]
- input: scalar or vector,
colatitude in radians measured southward from north pole (in
If ASTRO is set, Theta is the latitude in degrees measured
northward from the equator (in [-90, 90]).
- input: scalar or vector of same size as Theta,
longitude in radians measured eastward (in [0, ]).
If ASTRO is set, it is the longitude in degree measured eastward (in
- output : array,
three dimensional cartesian position vector
(x,y,z) normalised to unity. The north pole is (0,0,1).
The coordinates are ordered as follows
- if set Theta and Phi are the latitude and longitude in
degrees instead of the colatitude and longitude in radians.
ang2vec performs the geometrical transform from the position angles of points
into their position vectors (x,y,z):
This section lists the routines related to ang2vec
- version 6.1 or more is necessary to run ang2vec .
- conversion between vector or angles and pixel index
- conversion from position vectors to angles
will return in vec the 3D cartesian position vector of the point of latitude -45 deg and longitude 120 deg