Class Ellipse2afp.PrivateAPI
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d2.afp.Ellipse2afp.PrivateAPI
-
- Enclosing interface:
- Ellipse2afp<ST extends Shape2afp<?,?,IE,P,V,B>,IT extends Ellipse2afp<?,?,IE,P,V,B>,IE extends PathElement2afp,P extends Point2D<? super P,? super V>,V extends Vector2D<? super V,? super P>,B extends Rectangle2afp<?,?,IE,P,V,B>>
public static final class Ellipse2afp.PrivateAPI extends Object
Private API functions for the ellipses.- Since:
- 13.0
- Version:
- Geometry Tools $Revision$ 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static double[]
computeClosestPointOnShallowEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the closest point to a shallow ellipse centered on (0, 0) and in the positive quadrant.static double[]
computeClosestPointOnSolidEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the closest point to a solid ellipse centered on (0, 0) and in the positive quadrant.static double[]
computeFarthestPointOnShallowEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the farthest point to a shallow ellipse centered on (0, 0) and in the positive quadrant.
-
-
-
Method Detail
-
computeClosestPointOnShallowEllipseInPositiveQuadrant
public static double[] computeClosestPointOnShallowEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the closest point to a shallow ellipse centered on (0, 0) and in the positive quadrant. The coordinates of the point must be positive.The mathematrical definition of the algorithm is explained in: DistancePointEllipseEllipsoid.pdf (source: geometrictools.com).
- Parameters:
px
- the x coordinate of the point. It must be positive or nul.py
- the y coordinate of the point. It must be positive or nul.horizontalRadius
- the horizontal radius.verticalRadius
- the vertical radius.computeDistance
- indicates if the distance musst be computed and replied.- Returns:
- the triplet (closest point x, closest point y, distance to closest point) if
computeDistance
iftrue
. Otherwise, the triplet (closest point x, closest point y).
-
computeClosestPointOnSolidEllipseInPositiveQuadrant
public static double[] computeClosestPointOnSolidEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the closest point to a solid ellipse centered on (0, 0) and in the positive quadrant. The coordinates of the point must be positive.The mathematrical definition of the algorithm is explained in: DistancePointEllipseEllipsoid.pdf (source: geometrictools.com).
- Parameters:
px
- the x coordinate of the point. It must be positive or nul.py
- the y coordinate of the point. It must be positive or nul.horizontalRadius
- the horizontal radius.verticalRadius
- the vertical radius.computeDistance
- indicates if the distance musst be computed and replied.- Returns:
- the triplet (closest point x, closest point y, distance to closest point) if
computeDistance
iftrue
. Otherwise, the triplet (closest point x, closest point y).
-
computeFarthestPointOnShallowEllipseInPositiveQuadrant
public static double[] computeFarthestPointOnShallowEllipseInPositiveQuadrant(double px, double py, double horizontalRadius, double verticalRadius, boolean computeDistance)
Compute the farthest point to a shallow ellipse centered on (0, 0) and in the positive quadrant. The coordinates of the point must be negative.This function is an adaptation of the mathematrical definition that is explained in: DistancePointEllipseEllipsoid.pdf (source: geometrictools.com).
- Parameters:
px
- the x coordinate of the point. It must be positive or nul.py
- the y coordinate of the point. It must be positive or nul.horizontalRadius
- the horizontal radius.verticalRadius
- the vertical radius.computeDistance
- indicates if the distance musst be computed and replied.- Returns:
- the triplet (closest point x, closest point y, distance to closest point) if
computeDistance
iftrue
. Otherwise, the triplet (closest point x, closest point y).
-
-