Class SphereAngleRange


  • public class SphereAngleRange
    extends java.lang.Object
    Represents the range of angular coordinates that are covered by a given region.
    Since:
    15 Aug 2018
    Author:
    Mark Taylor
    • Constructor Summary

      Constructors 
      Constructor Description
      SphereAngleRange​(double phiLo, double phiHi, double thetaLo, double thetaHi)
      Constructor.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static SphereAngleRange calculateRange​(double[] dlos, double[] dhis)
      Determines the angle range for a cube defined by Cartesian limits.
      double[] getPhiLimits()
      Returns the limits of azimuthal angle.
      double[] getThetaLimits()
      Returns the limits of polar angle.
      • Methods inherited from class java.lang.Object

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

      • SphereAngleRange

        public SphereAngleRange​(double phiLo,
                                double phiHi,
                                double thetaLo,
                                double thetaHi)
        Constructor.
        Parameters:
        phiLo - phi lower bound
        phiHi - phi upper bound
        thetaLo - theta lower bound
        thetaHi - theta upper bound
    • Method Detail

      • getPhiLimits

        public double[] getPhiLimits()
        Returns the limits of azimuthal angle. A pair of values is returned; the first is always lower than the second, but neither is guaranteed to lie within a given range.
        Returns:
        2-element array giving (lo, hi) limits on phi
      • getThetaLimits

        public double[] getThetaLimits()
        Returns the limits of polar angle. A pair of values is returned; the first is lower than the second, and both are in the range (-PI/2..+PI/2).
        Returns:
        2-element array giving (lo, hi) limits on theta
      • calculateRange

        public static SphereAngleRange calculateRange​(double[] dlos,
                                                      double[] dhis)
        Determines the angle range for a cube defined by Cartesian limits. Note: This code hasn't been tried or tested at all, it may contain more or less serious errors.
        Parameters:
        dlos - 3-element array giving cube lower bounds
        dhis - 3-element array giving cube upper bounds
        Returns:
        angle range