NASA - Jet Propulsion Laboratory
    + View the NASA Portal
Search JPL
Jet Propulsion Laboratory Home Earth Solar System Stars & Galaxies Technology
Introduction Background Software Links


pix2xxx, ang2xxx, vec2xxx, nest2ring, ring2nest


These routines provide conversion between pixel number in the HEALPix map and $(\theta,\phi)$ or (x,y,z) coordinates on the sphere. Some of these routines are listed here.


Location in HEALPix directory tree: src/idl/toolkit/


QUALIFIERS


name (dim.) type in/out description
nside scalar integer IN Nside parameter for the HEALPix map.
ipnest(n) vector integer -- pixel identification number in NESTED scheme over the range {0,Npix-1}.
ipring(n) vector integer -- pixel identification number in RING scheme over the range {0,Npix-1}.
theta(n) vector double -- colatitude in radians measured southward from north pole in {0,$\pi$}
phi(n) vector double -- longitude in radians, measured eastward in {0,$2\pi$}.
vector(n,3) array double -- three dimensional cartesian position vector (x,y,z). The north pole is (0,0,1). An output vector is normalised to unity. The coordinates are ordered as follows $x(0),\ldots,x(n-1),\ y(0),\ldots,y(n-1),\ z(0),\ldots,z(n-1)$
vertex(n,3,4) array double optional OUT three dimensional cartesian position vector (x,y,z). Contains the location of the four vertices (=corners) of a pixel in the order North, West, South, East. The coordinates are ordered as follows $x_N(0),\ldots,x_N(n-1),\ y_N(0),\ldots,y_N(n-1),\ z_N(0),\ldots,z_N(n-1)$, $x_W(0),\ldots,x_W(n-1),\ y_W(0),\ldots,y_W(n-1),\
z_W(0),\ldots,z_W(n-1)$, and so on with South and East vertices

ROUTINES:
pix2ang_ring, nside, ipring, theta, phi

    renders theta and phi coordinates of the nominal pixel center given the pixel number ipring and a map resolution parameter nside.  


pix2vec_ring, nside, ipring, vector [,vertex]

    renders cartesian vector coordinates of the nominal pixel center given the pixel number ipring and a map resolution parameter nside. Optionally returns the location of the 4 vertices for the pixel(s) under consideration  


ang2pix_ring, nside, theta, phi, ipring

    renders the pixel number ipring for a pixel which, given the map resolution parameter nside, contains the point on the sphere at angular coordinates theta and phi.  


vec2pix_ring, nside, vector, ipring

    renders the pixel number ipring for a pixel which, given the map resolution parameter nside, contains the point on the sphere at cartesian coordinates vector.  


pix2ang_nest, nside, ipnest, theta, phi

    renders theta and phi coordinates of the nominal pixel center given the pixel number ipnest and a map resolution parameter nside.  


pix2vec_nest, nside, ipnest, vector [,vertex]

    renders cartesian vector coordinates of the nominal pixel center given the pixel number ipnest and a map resolution parameter nside. Optionally returns the location of the 4 vertices for the pixel(s) under consideration  


ang2pix_nest, nside, theta, phi, ipnest

    renders the pixel number ipnest for a pixel which, given the map resolution parameter nside, contains the point on the sphere at angular coordinates theta and phi.  


vec2pix_nest, nside, vector, ipnest

    renders the pixel number ipnest for a pixel which, given the map resolution parameter nside, contains the point on the sphere at cartesian coordinates vector.  


nest2ring, nside, ipnest, ipring

    performs conversion from NESTED to RING pixel number.  


ring2nest, nside, ipring, ipnest

    performs conversion from RING to NESTED pixel number.  



RELATED ROUTINES

This section lists the routines related to pix2xxx, ang2xxx, vec2xxx, nest2ring, ring2nest


idl
version 6.1 or more is necessary to run pix2xxx, ang2xxx,... .
npix2nside
computes Nside (resolution) corresponding to Npix (total pixel number)
nside2npix
computes Npix corresponding to Nside
ang2vec, vec2ang
geometrical conversion between position angles and position vector


EXAMPLE:

pix2ang_ring, 256, [17,1000], theta, phi
print,theta,phi

returns
0.0095683558 0.070182078
2.8797933 5.4620872
position of 2 pixels 17 and 1000 in the RING scheme with parameter 256.

Eric Hivon 2010-06-18
Privacy / Copyright
FIRST GOV Contact: NASA Home Page Site Manager:
Webmaster:

CL 03-2650