neighbours_nest


This IDL facility returns the number and indices of the topological immediate neighbours of a central pixel. The pixels are ordered in a clockwise sense (when watching the sphere from the outside) about the central pixel with the southernmost pixel in first element. For the four pixels in the southern corners of the equatorial faces which have two equally southern neighbours the routine returns the southwestern pixel first and proceeds clockwise.

Location in HEALPix directory tree: src/idl/toolkit/neighbours_nest.pro 


FORMAT

IDL> neighbours_nest (Nside, Ipix0, Listpix[,Nneigh])


QUALIFIERS

Nside
HEALPix resolution parameter (scalar integer), should be a valid Nside (power of 2)
Ipix0
NESTED-scheme index of central pixel in [0,12*Nside2-1]
Listpix
output: list of neighbouring pixel (NESTED scheme index) of size Nneigh
Nneigh
optional output: number of neighbours of pixel #Ipix0. Usually 8, sometimes 7 (for 8 particular pixels) or 6 (if Nside=1)


DESCRIPTION

neighbours_nest calls pix2xy_nest to find location of central pixel within the pixelation base-face, and then xy2pix_nest to find neighbouring pixels within the same face, or one of the bit manipulation routines if the neighbouring pixel is on a different base-face.


RELATED ROUTINES

This section lists the routines related to neighbours_nest

idl
version 6.4 or more is necessary to run neighbours_nest .
neighbours_ring
returns topological immediate neighbouring pixels of a given central pixel, using RING indexing.
query_disc, query_polygon,
query_strip, query_triangle
render the list of pixels enclosed respectively in a given disc, polygon, latitude strip and triangle
nest2ring, ring2nest
conversion between NESTED and RING indices


EXAMPLE:

neighbours_nest , 4, 1, list, nneigh
print,nneigh,list
will return:8 90 0 2 3 6 4 94 91, listing the NESTED-indexed 8 neighbors of pixel #1 for Nside=4

Version 3.31, 2017-01-06