Package mathvoyage
Class vmath.Vector
java.lang.Object
mathvoyage.vmath.Vector
- Enclosing class:
vmath
Contains functions to calculate vector operations
- Author:
- Adib Sakhawat
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic vectorAdd vector.static booleanCompare boolean.static doubleMagnitude double.static vectorMultiply vector.static doublescalerProduct(vector a, vector b) Scaler product double.static vectorSubtract vector.static vectorunitVector(vector a) Unit vector vector.static vectorvectorProduct(vector a, vector b) Vector product vector.
-
Constructor Details
-
Vector
public Vector()
-
-
Method Details
-
add
Add vector.- Parameters:
a- the ab- the b- Returns:
- the vector
-
subtract
Subtract vector.- Parameters:
a- the ab- the b- Returns:
- the vector
-
scalerProduct
Scaler product double.- Parameters:
a- the ab- the b- Returns:
- the double
-
vectorProduct
Vector product vector.- Parameters:
a- the ab- the b- Returns:
- the vector
-
multiply
Multiply vector.- Parameters:
a- the am- the m- Returns:
- the vector
-
compare
Compare boolean.- Parameters:
a- the ab- the b- Returns:
- the boolean
-
magnitude
Magnitude double.- Parameters:
a- the a- Returns:
- the double
-
unitVector
Unit vector vector.- Parameters:
a- the a- Returns:
- the vector
-