Class PixtoolsHealpix

  • All Implemented Interfaces:
    cds.moc.HealpixImpl

    public class PixtoolsHealpix
    extends java.lang.Object
    implements cds.moc.HealpixImpl
    Healpix implementation for use with MOC library based on Kuropatkin's PixTools library. Use getInstance() to obtain the singleton instance of this class.
    Since:
    16 Dec 2011
    Author:
    Mark Taylor
    See Also:
    PixTools
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      long ang2pix​(int order, double lonDeg, double latDeg)  
      static PixtoolsHealpix getInstance()
      Returns the sole instance of this singleton class.
      static int nsideToOrder​(long nside)
      Turns the HEALPix Nside parameter into the MOC "order" parameter.
      static long orderToNside​(int order)
      Turns the MOC "order" parameter into the HEALPix Nside parameter.
      double[] pix2ang​(int order, long ipix)  
      long[] queryDisc​(int order, double lonDeg, double latDeg, double radiusDeg)  
      int sizeToNside​(double sizeDeg)
      Returns an Nside value corresponding to a given angular size.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • ang2pix

        public long ang2pix​(int order,
                            double lonDeg,
                            double latDeg)
        Specified by:
        ang2pix in interface cds.moc.HealpixImpl
      • pix2ang

        public double[] pix2ang​(int order,
                                long ipix)
        Specified by:
        pix2ang in interface cds.moc.HealpixImpl
      • queryDisc

        public long[] queryDisc​(int order,
                                double lonDeg,
                                double latDeg,
                                double radiusDeg)
        Specified by:
        queryDisc in interface cds.moc.HealpixImpl
      • sizeToNside

        public int sizeToNside​(double sizeDeg)
        Returns an Nside value corresponding to a given angular size.
        Parameters:
        sizeDeg - size in degrees
        Returns:
        nside
      • orderToNside

        public static long orderToNside​(int order)
        Turns the MOC "order" parameter into the HEALPix Nside parameter.
        Parameters:
        order - healpix order (>=0)
        Returns:
        nside
      • nsideToOrder

        public static int nsideToOrder​(long nside)
        Turns the HEALPix Nside parameter into the MOC "order" parameter.
        Parameters:
        nside - Nside
        Returns:
        order
        Throws:
        java.lang.IllegalArgumentException - if nside is not suitable
      • getInstance

        public static PixtoolsHealpix getInstance()
        Returns the sole instance of this singleton class.
        Returns:
        instance