Java org.apache.commons.math3.geometry.euclidean.twod Vector2D fields, constructors, methods, implement or subclass

Example usage for Java org.apache.commons.math3.geometry.euclidean.twod Vector2D fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for org.apache.commons.math3.geometry.euclidean.twod Vector2D.

The text is from its open source code.

Field

Vector2DZERO
Origin (coordinates: 0, 0).
Vector2DNaN
A vector with all coordinates set to NaN.

Constructor

Vector2D(double x, double y)
Simple constructor.
Vector2D(double a, Vector2D u)
Multiplicative constructor Build a vector from another one and a scale factor.
Vector2D(double[] v)
Simple constructor.

Method

Vector2Dadd(Vector v)
Vector2Dadd(double factor, Vector v)
doubledistance(Vector p)
doubledistance(Vector2D p1, Vector2D p2)
Compute the distance between two vectors according to the L2 norm.
doubledistanceSq(Vector p)
doubledotProduct(final Vector v)
doublegetNorm()
doublegetNormSq()
doublegetX()
Get the abscissa of the vector.
doublegetY()
Get the ordinate of the vector.
Vector2Dnegate()
Vector2Dnormalize()
Vector2DscalarMultiply(double a)
Vector2Dsubtract(Vector p)
double[]toArray()
Get the vector coordinates as a dimension 2 array.
StringtoString()
Get a string representation of this vector.