healpy.pixelfunc.nside2resol

healpy.pixelfunc.nside2resol(nside, arcmin=False)

Give approximate resolution (pixel size in radian or arcmin) for nside.

Resolution is just the square root of the pixel area, which is a gross approximation given the different pixel shapes

Parameters
nsideint

healpix nside parameter, must be a power of 2, less than 2**30

arcminbool

if True, return resolution in arcmin, otherwise in radian

Returns
resolfloat

approximate pixel size in radians or arcmin

Notes

Raise a ValueError exception if nside is not valid.

Examples

>>> import healpy as hp
>>> hp.nside2resol(128, arcmin = True)
27.483891294539248
>>> hp.nside2resol(256)
0.0039973699529159707
>>> hp.nside2resol(7)
0.1461895297066412