Modifier | Constructor and Description |
---|---|
protected |
Abstract2d(double x,
double y) |
Modifier and Type | Method and Description |
---|---|
double |
dot(Abstract2d a)
Returns the dot product of this vector and the specified vector.
|
boolean |
equals(Object obj) |
double |
getX() |
double |
getY() |
int |
hashCode() |
boolean |
isXZero()
Checks if the X coordinate is zero.
|
boolean |
isYZero()
Checks if the Y coordinate is zero.
|
boolean |
isZero()
Checks if all three coordinates are zero, which means it is equals to
isXZero() && isYZero() && isZZero().
|
double |
squareDist(Abstract2d p)
Returns the square distance of the two point.
|
String |
toString() |
public final boolean isXZero()
public final boolean isYZero()
public final boolean isZero()
public double getX()
public double getY()
public double dot(Abstract2d a)
a
- the second vectorpublic double squareDist(Abstract2d p)
p
- the other pointCopyright © 2014–2020, Printing in 3D. All rights reserved.