Modifier and Type  Field and Description 

static double 
MINIMUM_ANGULAR_RESOLUTION
Angular version of minimum resolution.

static double 
MINIMUM_RESOLUTION
Values that are all considered to be essentially zero have a magnitude
less than this.

static double 
MINIMUM_RESOLUTION_CUBED
For cubed quantities, cube the bound.

static double 
MINIMUM_RESOLUTION_SQUARED
For squared quantities, the bound is squared too.

double 
x
The x value

double 
y
The y value

double 
z
The z value

Constructor and Description 

Vector(double x,
double y,
double z)
Construct from (U.S.) x,y,z coordinates.

Vector(double AX,
double AY,
double AZ,
double BX,
double BY,
double BZ)
Construct a vector that is perpendicular to
two other (nonzero) vectors.

Vector(Vector A,
double BX,
double BY,
double BZ)
Construct a vector that is perpendicular to
two other (nonzero) vectors.

Vector(Vector A,
Vector B)
Construct a vector that is perpendicular to
two other (nonzero) vectors.

Modifier and Type  Method and Description 

static boolean 
crossProductEvaluateIsZero(Vector A,
Vector B,
Vector point)
Evaluate the cross product of two vectors against a point.

double 
dotProduct(double x,
double y,
double z)
Do a dot product.

double 
dotProduct(Vector v)
Do a dot product.

boolean 
equals(Object o) 
int 
hashCode() 
boolean 
isNumericallyIdentical(double otherX,
double otherY,
double otherZ)
Compute whether two vectors are numerically identical.

boolean 
isNumericallyIdentical(Vector other)
Compute whether two vectors are numerically identical.

boolean 
isParallel(double otherX,
double otherY,
double otherZ)
Compute whether two vectors are parallel.

boolean 
isParallel(Vector other)
Compute whether two vectors are numerically identical.

boolean 
isWithin(Membership[] bounds,
Membership... moreBounds)
Determine if this vector, taken from the origin,
describes a point within a set of planes.

double 
linearDistance(double x,
double y,
double z)
Compute the straightline distance to a point described by the
vector taken from the origin.

double 
linearDistance(Vector v)
Compute the straightline distance to a point described by the
vector taken from the origin.

double 
linearDistanceSquared(double x,
double y,
double z)
Compute the square of a straightline distance to a point described by the
vector taken from the origin.

double 
linearDistanceSquared(Vector v)
Compute the square of a straightline distance to a point described by the
vector taken from the origin.

double 
magnitude()
Compute the magnitude of this vector.

static double 
magnitude(double x,
double y,
double z)
Compute a magnitude of an x,y,z value.

double 
normalDistance(double x,
double y,
double z)
Compute the normal (perpendicular) distance to a vector described by a
vector taken from the origin.

double 
normalDistance(Vector v)
Compute the normal (perpendicular) distance to a vector described by a
vector taken from the origin.

double 
normalDistanceSquared(double x,
double y,
double z)
Compute the square of the normal distance to a vector described by a
vector taken from the origin.

double 
normalDistanceSquared(Vector v)
Compute the square of the normal distance to a vector described by a
vector taken from the origin.

Vector 
normalize()
Compute a normalized unit vector based on the current vector.

Vector 
rotateXY(double angle)
Rotate vector counterclockwise in xy by an angle.

Vector 
rotateXY(double sinAngle,
double cosAngle)
Rotate vector counterclockwise in xy by an angle, expressed as sin and cos.

Vector 
rotateXZ(double angle)
Rotate vector counterclockwise in xz by an angle.

Vector 
rotateXZ(double sinAngle,
double cosAngle)
Rotate vector counterclockwise in xz by an angle, expressed as sin and cos.

Vector 
rotateZY(double angle)
Rotate vector counterclockwise in zy by an angle.

Vector 
rotateZY(double sinAngle,
double cosAngle)
Rotate vector counterclockwise in zy by an angle, expressed as sin and cos.

String 
toString() 
Vector 
translate(double xOffset,
double yOffset,
double zOffset)
Translate vector.

public static final double MINIMUM_RESOLUTION
public static final double MINIMUM_ANGULAR_RESOLUTION
public static final double MINIMUM_RESOLUTION_SQUARED
public static final double MINIMUM_RESOLUTION_CUBED
public final double x
public final double y
public final double z
public Vector(double x, double y, double z)
x
 is the x value.y
 is the y value.z
 is the z value.public Vector(Vector A, double BX, double BY, double BZ)
A
 is the first vectorBX
 is the X value of the secondBY
 is the Y value of the secondBZ
 is the Z value of the secondpublic Vector(double AX, double AY, double AZ, double BX, double BY, double BZ)
AX
 is the X value of the firstAY
 is the Y value of the firstAZ
 is the Z value of the firstBX
 is the X value of the secondBY
 is the Y value of the secondBZ
 is the Z value of the secondpublic static double magnitude(double x, double y, double z)
public Vector normalize()
public static boolean crossProductEvaluateIsZero(Vector A, Vector B, Vector point)
A
 is the first vector to use for the cross product.B
 is the second vector to use for the cross product.point
 is the point to evaluate.public double dotProduct(Vector v)
v
 is the vector to multiply.public double dotProduct(double x, double y, double z)
x
 is the x value of the vector to multiply.y
 is the y value of the vector to multiply.z
 is the z value of the vector to multiply.public boolean isWithin(Membership[] bounds, Membership... moreBounds)
bounds
 is the first part of the set of planes.moreBounds
 is the second part of the set of planes.public Vector translate(double xOffset, double yOffset, double zOffset)
public Vector rotateXY(double angle)
public Vector rotateXY(double sinAngle, double cosAngle)
public Vector rotateXZ(double angle)
public Vector rotateXZ(double sinAngle, double cosAngle)
public Vector rotateZY(double angle)
public Vector rotateZY(double sinAngle, double cosAngle)
public double linearDistanceSquared(Vector v)
v
 is the vector to compute a distance to.public double linearDistanceSquared(double x, double y, double z)
x
 is the x part of the vector to compute a distance to.y
 is the y part of the vector to compute a distance to.z
 is the z part of the vector to compute a distance to.public double linearDistance(Vector v)
v
 is the vector to compute a distance to.public double linearDistance(double x, double y, double z)
x
 is the x part of the vector to compute a distance to.y
 is the y part of the vector to compute a distance to.z
 is the z part of the vector to compute a distance to.public double normalDistanceSquared(Vector v)
v
 is the vector to compute a distance to.public double normalDistanceSquared(double x, double y, double z)
x
 is the x part of the vector to compute a distance to.y
 is the y part of the vector to compute a distance to.z
 is the z part of the vector to compute a distance to.public double normalDistance(Vector v)
v
 is the vector to compute a distance to.public double normalDistance(double x, double y, double z)
x
 is the x part of the vector to compute a distance to.y
 is the y part of the vector to compute a distance to.z
 is the z part of the vector to compute a distance to.public double magnitude()
public boolean isNumericallyIdentical(double otherX, double otherY, double otherZ)
otherX
 is the other vector X.otherY
 is the other vector Y.otherZ
 is the other vector Z.public boolean isNumericallyIdentical(Vector other)
other
 is the other vector.public boolean isParallel(double otherX, double otherY, double otherZ)
otherX
 is the other vector X.otherY
 is the other vector Y.otherZ
 is the other vector Z.public boolean isParallel(Vector other)
other
 is the other vector.Copyright © 20002019 Apache Software Foundation. All Rights Reserved.