public class Vector3d extends Object
Constructor and Description |
---|
Vector3d(Coord3d p1,
Coord3d p2)
Create a vector, described by two coordinates.
|
Vector3d(float x1,
float y1,
float z1,
float x2,
float y2,
float z2)
Create a vector, described by two points.
|
Modifier and Type | Method and Description |
---|---|
Coord3d |
cross(Vector3d v)
Computes the vectorial product of the current and the given vector.
|
double |
distance(Coord3d c)
Compute the distance between two coordinates.
|
float |
dot(Vector3d v)
Compute the dot product between and current and given vector.
|
Coord3d |
getCenter()
Return the central point of this segment.
|
float |
norm()
Compute the norm of this vector.
|
Coord3d |
vector()
Return the vector induced by this set of coordinates.
|
public Vector3d(float x1, float y1, float z1, float x2, float y2, float z2)
public Coord3d vector()
public float dot(Vector3d v)
v
- input vectorpublic Coord3d cross(Vector3d v)
public float norm()
public double distance(Coord3d c)
public Coord3d getCenter()
Copyright © 2016. All rights reserved.