Package com.google.common.geometry
Class BigPoint
- java.lang.Object
-
- com.google.common.geometry.BigPoint
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(BigPoint p)
(package private) BigPoint
crossProd(BigPoint that)
Returns the vector cross product of 'this' with 'that'.(package private) java.math.BigDecimal
dotProd(BigPoint that)
Returns the vector dot product of 'this' with 'that'.(package private) java.math.BigDecimal
dotProd(S2Point that)
Returns the vector dot product of 'this' with 'that'.boolean
equals(java.lang.Object that)
int
hashCode()
(package private) boolean
isAntipodal(BigPoint p)
Returns true iff this and 'p' are exactly anti-parallel, antipodal points.(package private) boolean
isLinearlyDependent(BigPoint p)
Returns true iff this and 'p' are exactly parallel or anti-parallel.(package private) java.math.BigDecimal
norm2()
Returns the square of the magnitude of this vector.(package private) S2Point
toS2Point()
Returns an S2Point by rounding 'this' to double precision.
-
-
-
Constructor Detail
-
BigPoint
BigPoint(S2Point p)
Creates a point of BigDecimal coordinates from a point of double coordinates.
-
BigPoint
BigPoint(java.math.BigDecimal x, java.math.BigDecimal y, java.math.BigDecimal z)
Creates a point from the given BigDecimal coordinates.
-
-
Method Detail
-
toS2Point
S2Point toS2Point()
Returns an S2Point by rounding 'this' to double precision.
-
crossProd
BigPoint crossProd(BigPoint that)
Returns the vector cross product of 'this' with 'that'.
-
dotProd
java.math.BigDecimal dotProd(BigPoint that)
Returns the vector dot product of 'this' with 'that'.
-
dotProd
java.math.BigDecimal dotProd(S2Point that)
Returns the vector dot product of 'this' with 'that'.
-
isLinearlyDependent
boolean isLinearlyDependent(BigPoint p)
Returns true iff this and 'p' are exactly parallel or anti-parallel.
-
isAntipodal
boolean isAntipodal(BigPoint p)
Returns true iff this and 'p' are exactly anti-parallel, antipodal points.
-
norm2
java.math.BigDecimal norm2()
Returns the square of the magnitude of this vector.
-
compareTo
public int compareTo(BigPoint p)
- Specified by:
compareTo
in interfacejava.lang.Comparable<BigPoint>
-
equals
public boolean equals(java.lang.Object that)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-