healpy.pixelfunc.ang2vec

healpy.pixelfunc.ang2vec(theta, phi)

ang2vec : convert angles to 3D position vector

Parameters :

theta : float, scalar or arry-like

colatitude in radians measured southward from north pole (in [0,pi]).

phi : float, scalar or array-like

longitude in radians measured eastward (in [0, 2*pi]).

Returns :

vec : float, array

if theta and phi are vectors, the result is a 2D array with a vector per row otherwise, it is a 1D array of shape (3,)

See also

vec2ang, rotator.dir2vec, rotator.vec2dir

Project Versions

Previous topic

healpy.pixelfunc.vec2ang

Next topic

healpy.pixelfunc.get_neighbours

This Page