java.lang.Object
org.hipparchus.geometry.spherical.oned.Arc

public class Arc extends Object
This class represents an arc on a circle.
See Also:
  • Constructor Summary Link icon

    Constructors
    Constructor
    Description
    Arc(double lower, double upper, double tolerance)
    Simple constructor.
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    checkPoint(double point)
    Check a point with respect to the arc.
    double
    Get the barycenter of the arc.
    double
    Get the lower angular bound of the arc.
    double
    getOffset(double point)
    Get the distance (arc length) from a point to the edge of the arc.
    double
    Get the distance (arc length) from a point to the edge of the arc.
    double
    Get the angular size of the arc.
    double
    Get the upper angular bound of the arc.
    double
    Get the tolerance below which angles are considered identical.

    Methods inherited from class java.lang.Object Link icon

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details Link icon

    • Arc Link icon

      public Arc(double lower, double upper, double tolerance) throws MathIllegalArgumentException
      Simple constructor.

      If either lower is equals to upper or the interval exceeds 2π, the arc is considered to be the full circle and its initial defining boundaries will be forgotten. lower is not allowed to be greater than upper (an exception is thrown in this case). lower will be canonicalized between 0 and 2π, and upper shifted accordingly, so the getInf() and getSup() may not return the value used at instance construction.

      Parameters:
      lower - lower angular bound of the arc
      upper - upper angular bound of the arc
      tolerance - tolerance below which angles are considered identical
      Throws:
      MathIllegalArgumentException - if lower is greater than upper or tolerance is smaller than Sphere1D.SMALLEST_TOLERANCE
  • Method Details Link icon

    • getInf Link icon

      public double getInf()
      Get the lower angular bound of the arc.
      Returns:
      lower angular bound of the arc, always between 0 and 2π
    • getSup Link icon

      public double getSup()
      Get the upper angular bound of the arc.
      Returns:
      upper angular bound of the arc, always between getInf() and getInf() +2π
    • getSize Link icon

      public double getSize()
      Get the angular size of the arc.
      Returns:
      angular size of the arc
    • getBarycenter Link icon

      public double getBarycenter()
      Get the barycenter of the arc.
      Returns:
      barycenter of the arc
    • getTolerance Link icon

      public double getTolerance()
      Get the tolerance below which angles are considered identical.
      Returns:
      tolerance below which angles are considered identical
    • checkPoint Link icon

      public Region.Location checkPoint(double point)
      Check a point with respect to the arc.
      Parameters:
      point - point to check
      Returns:
      a code representing the point status: either Region.Location.INSIDE, Region.Location.OUTSIDE or Region.Location.BOUNDARY
    • getOffset Link icon

      public double getOffset(double point)
      Get the distance (arc length) from a point to the edge of the arc.

      This method does not use getTolerance().

      Parameters:
      point - to test.
      Returns:
      offset, negative if the point is inside the arc, positive if it is outside the arc, or zero if point is getInf() or getSup().
    • getOffset Link icon

      public double getOffset(S1Point point)
      Get the distance (arc length) from a point to the edge of the arc.

      This method does not use getTolerance().

      Parameters:
      point - to test.
      Returns:
      offset, negative if the point is inside the arc, positive if it is outside the arc, or zero if point is getInf() or getSup().