public abstract class ArrayVector extends AVector
| Constructor and Description |
|---|
ArrayVector() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(ArrayVector v) |
void |
add(ArrayVector src,
int srcOffset) |
void |
add(AVector src)
Adds another vector to this one
|
void |
add(AVector src,
int srcOffset)
Adds part another vector to this one, starting at the specified offset in the source vector
|
void |
add(double constant) |
void |
add(int offset,
ArrayVector src) |
void |
add(int offset,
ArrayVector src,
int srcOffset,
int length) |
void |
add(int offset,
AVector src)
Adds another vector into this one, at the specified offset
|
void |
addAt(int i,
double v) |
void |
addMultiple(ArrayVector v,
double factor) |
void |
addMultiple(AVector v,
double factor)
Adds a scaled multiple of another vector to this one
|
void |
addMultipleToArray(double factor,
int offset,
double[] array,
int arrayOffset,
int length) |
void |
addProduct(AVector a,
AVector b,
double factor) |
void |
addProduct(AVector a,
int aOffset,
AVector b,
int bOffset,
double factor) |
void |
addProductToArray(double factor,
int offset,
ArrayVector other,
int otherOffset,
double[] array,
int arrayOffset,
int length) |
void |
addProductToArray(double factor,
int offset,
AVector other,
int otherOffset,
double[] array,
int arrayOffset,
int length) |
void |
addToArray(int offset,
double[] array,
int arrayOffset,
int length) |
void |
applyOp(Op op)
Applies a unary operator to all elements of the array (in-place)
|
void |
copyTo(double[] data,
int offset)
Copies a the contents of a vector to a double array at the specified offset
|
void |
copyTo(int offset,
ArrayVector dest,
int destOffset,
int length) |
void |
copyTo(int start,
AVector dest,
int destOffset,
int length)
Copies a subset of this vector to a vector at the specified offset
|
void |
copyTo(int offset,
double[] dest,
int destOffset,
int length) |
void |
divide(AVector v) |
void |
divide(double[] data,
int offset) |
void |
divideTo(double[] data,
int offset) |
double |
elementSum()
Returns the sum of all elements in a vector
|
void |
fillRange(int offset,
int length,
double value) |
abstract double[] |
getArray() |
abstract int |
getArrayOffset() |
boolean |
isView()
Returns true if this vector is of a view type that references other vectors / data.
|
AVector |
join(ArrayVector v) |
AVector |
join(AVector v)
Returns a new vector that refers to this vector joined to a second vector
|
AVector |
join(JoinedArrayVector v) |
double |
magnitude()
Returns the magnitude (Euclidean length) of the vector
|
double |
magnitudeSquared() |
void |
multiply(AVector v) |
void |
multiply(double[] data,
int offset) |
void |
multiplyTo(double[] data,
int offset) |
void |
scaleAdd(double factor,
double constant) |
void |
set(AVector a)
Sets the vector to equal the value of another vector
|
void |
set(AVector a,
int offset)
Set the vector equal to an offset into another vector
|
void |
set(int offset,
double[] data,
int dataOffset,
int length)
Set part of this vector from a double array
|
void |
setElements(double[] values,
int offset,
int length) |
AScalar |
slice(int position) |
void |
square() |
ArraySubVector |
subVector(int offset,
int length)
Returns a vector referencing a sub-vector of the current vector
|
abs, add, add, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addProduct, addWeighted, angle, applyOp, asElementList, asVector, broadcast, clamp, clampMax, clampMin, clone, compareTo, copyTo, copyTo, countZeros, crossProduct, dimensionality, distance, distanceL1, distanceLinf, distanceSquared, divide, dotProduct, dotProduct, elementCount, epsilonEquals, epsilonEquals, equals, equals, equals, equalsArray, exactClone, fill, get, get, getLongShape, getShape, getSlices, hashCode, innerProduct, innerProduct, innerProduct, interpolate, interpolate, isElementConstrained, isFullyMutable, isMutable, isUnitLengthVector, isZeroVector, iterator, length, maxAbsElement, multiply, negate, normalise, normaliseMaxAbsElement, outerProduct, outerProduct, projectToPlane, reshape, scale, scaleAdd, scaleToMagnitude, set, set, set, set, set, set, setValues, signum, sliceCount, sub, sub, sub, subMultiple, toArray, toList, toStringget, get, scale, set, set, setElementspublic abstract double[] getArray()
public abstract int getArrayOffset()
public ArraySubVector subVector(int offset, int length)
public AScalar slice(int position)
public boolean isView()
AVectorpublic void copyTo(double[] data,
int offset)
AVectorpublic void fillRange(int offset,
int length,
double value)
public void set(AVector a)
AVectorpublic void set(AVector a, int offset)
AVectorpublic void set(int offset,
double[] data,
int dataOffset,
int length)
AVectorpublic void setElements(double[] values,
int offset,
int length)
setElements in interface INDArraysetElements in class AVectorpublic void add(AVector src)
AVectorpublic void add(ArrayVector v)
public void add(AVector src, int srcOffset)
AVectorpublic void add(int offset,
AVector src)
AVectorpublic void add(int offset,
ArrayVector src)
public void add(int offset,
ArrayVector src,
int srcOffset,
int length)
public void addMultiple(AVector v, double factor)
AVectoraddMultiple in class AVectorpublic void addProduct(AVector a, int aOffset, AVector b, int bOffset, double factor)
addProduct in class AVectorpublic void addToArray(int offset,
double[] array,
int arrayOffset,
int length)
addToArray in class AVectorpublic void addProduct(AVector a, AVector b, double factor)
addProduct in class AVectorpublic void addMultipleToArray(double factor,
int offset,
double[] array,
int arrayOffset,
int length)
addMultipleToArray in class AVectorpublic void addProductToArray(double factor,
int offset,
AVector other,
int otherOffset,
double[] array,
int arrayOffset,
int length)
addProductToArray in class AVectorpublic void addProductToArray(double factor,
int offset,
ArrayVector other,
int otherOffset,
double[] array,
int arrayOffset,
int length)
addProductToArray in class AVectorpublic void add(ArrayVector src, int srcOffset)
public void applyOp(Op op)
INDArraypublic double elementSum()
AVectorelementSum in class AVectorpublic void multiplyTo(double[] data,
int offset)
multiplyTo in class AVectorpublic void copyTo(int start,
AVector dest,
int destOffset,
int length)
AVectorpublic void copyTo(int offset,
ArrayVector dest,
int destOffset,
int length)
public void copyTo(int offset,
double[] dest,
int destOffset,
int length)
public void addMultiple(ArrayVector v, double factor)
public double magnitudeSquared()
magnitudeSquared in class AVectorpublic double magnitude()
AVectorpublic AVector join(AVector v)
AVectorpublic AVector join(ArrayVector v)
public AVector join(JoinedArrayVector v)
Copyright © 2013. All Rights Reserved.