public final class ArrayAnyD<N extends Number> extends Object implements AccessAnyD<N>, AccessAnyD.Visitable<N>, AccessAnyD.Aggregatable<N>, AccessAnyD.Sliceable<N>, AccessAnyD.Elements, AccessAnyD.IndexOf, StructureAnyD.ReducibleTo1D<Array1D<N>>, StructureAnyD.ReducibleTo2D<Array2D<N>>, MutateAnyD.ModifiableReceiver<N>, MutateAnyD.Mixable<N>
Modifier and Type | Class and Description |
---|---|
static class |
ArrayAnyD.Factory<N extends Number> |
AccessAnyD.Aggregatable<N extends Number>, AccessAnyD.Collectable<N extends Number,R extends MutateAnyD.Receiver<N>>, AccessAnyD.Elements, AccessAnyD.IndexOf, AccessAnyD.Sliceable<N extends Number>, AccessAnyD.Visitable<N extends Number>
Access1D.ElementView<N extends Number>
MutateAnyD.Fillable<N extends Number>, MutateAnyD.Mixable<N extends Number>, MutateAnyD.Modifiable<N extends Number>, MutateAnyD.ModifiableReceiver<N extends Number>, MutateAnyD.Receiver<N extends Number>
Mutate1D.Sortable
StructureAnyD.IntReference, StructureAnyD.Logical<S extends StructureAnyD,B extends StructureAnyD.Logical<S,?>>, StructureAnyD.LongReference, StructureAnyD.ReducibleTo1D<R extends Structure1D>, StructureAnyD.ReducibleTo2D<R extends Structure2D>, StructureAnyD.ReferenceCallback, StructureAnyD.ReferenceMapper
Structure1D.BasicMapper<T>, Structure1D.IndexCallback, Structure1D.IndexMapper<T>, Structure1D.IntIndex, Structure1D.LongIndex, Structure1D.LoopCallback
Modifier and Type | Field and Description |
---|---|
static ArrayAnyD.Factory<BigDecimal> |
BIG |
static ArrayAnyD.Factory<ComplexNumber> |
COMPLEX |
static ArrayAnyD.Factory<Double> |
DIRECT32 |
static ArrayAnyD.Factory<Double> |
DIRECT64 |
static ArrayAnyD.Factory<Double> |
PRIMITIVE32 |
static ArrayAnyD.Factory<Double> |
PRIMITIVE64 |
static ArrayAnyD.Factory<Quaternion> |
QUATERNION |
static ArrayAnyD.Factory<RationalNumber> |
RATIONAL |
Modifier and Type | Method and Description |
---|---|
void |
add(long[] reference,
double addend) |
void |
add(long[] reference,
Number addend) |
void |
add(long index,
double addend) |
void |
add(long index,
Number addend) |
N |
aggregateRange(long first,
long limit,
Aggregator aggregator) |
Number |
aggregateSet(int dimension,
long dimensionalIndex,
Aggregator aggregator) |
Number |
aggregateSet(long[] initial,
int dimension,
Aggregator aggregator) |
Array1D<N> |
asArray1D()
Deprecated.
v39 Not needed
|
void |
clear() |
long |
count()
count() == count(0) * count(1) * count(2) * count(3) * ...
|
long |
count(int dimension) |
double |
doubleValue(long index)
Will pass through each matching element position calling the
through function. |
double |
doubleValue(long[] ref) |
boolean |
equals(Object obj) |
static <N extends Number> |
factory(DenseArray.Factory<N> denseArray) |
void |
fillAll(N value) |
void |
fillAll(NullaryFunction<N> supplier) |
void |
fillOne(long[] reference,
N value) |
void |
fillOne(long[] reference,
NullaryFunction<N> supplier) |
void |
fillOne(long index,
Access1D<?> values,
long valueIndex) |
void |
fillOne(long index,
N value) |
void |
fillOne(long index,
NullaryFunction<N> supplier) |
void |
fillRange(long first,
long limit,
N value) |
void |
fillRange(long first,
long limit,
NullaryFunction<N> supplier) |
void |
fillSet(int dimension,
long dimensionalIndex,
N value) |
void |
fillSet(int dimension,
long dimensionalIndex,
NullaryFunction<N> supplier) |
void |
fillSet(long[] initial,
int dimension,
N value) |
void |
fillSet(long[] initial,
int dimension,
NullaryFunction<N> supplier) |
N |
get(long index) |
N |
get(long[] ref) |
int |
hashCode() |
long |
indexOfLargest() |
long |
indexOfLargestInRange(long first,
long limit) |
boolean |
isAbsolute(long index) |
boolean |
isAbsolute(long[] reference) |
boolean |
isSmall(long[] reference,
double comparedTo) |
boolean |
isSmall(long index,
double comparedTo) |
double |
mix(long[] reference,
BinaryFunction<N> mixer,
double addend) |
N |
mix(long[] reference,
BinaryFunction<N> mixer,
N addend) |
void |
modifyAll(UnaryFunction<N> modifier) |
void |
modifyAny(TransformationAnyD<N> modifier) |
void |
modifyMatching(Access1D<N> left,
BinaryFunction<N> function) |
void |
modifyMatching(BinaryFunction<N> function,
Access1D<N> right) |
void |
modifyOne(long[] reference,
UnaryFunction<N> modifier) |
void |
modifyOne(long index,
UnaryFunction<N> modifier) |
void |
modifyRange(long first,
long limit,
UnaryFunction<N> modifier) |
void |
modifySet(int dimension,
long dimensionalIndex,
UnaryFunction<N> modifier) |
void |
modifySet(long[] initial,
int dimension,
UnaryFunction<N> modifier) |
int |
rank() |
Array1D<N> |
reduce(int dimension,
Aggregator aggregator) |
Array2D<N> |
reduce(int rowDimension,
int columnDimension,
Aggregator aggregator) |
void |
set(long[] reference,
double value) |
void |
set(long[] reference,
Number value) |
void |
set(long index,
double value) |
void |
set(long index,
Number value) |
long[] |
shape() |
Array1D<N> |
sliceRange(long first,
long limit) |
Array1D<N> |
sliceSet(long[] initial,
int dimension) |
String |
toString() |
void |
visitAll(VoidFunction<N> visitor) |
void |
visitOne(long[] reference,
VoidFunction<N> visitor) |
void |
visitOne(long index,
VoidFunction<N> visitor) |
void |
visitRange(long first,
long limit,
VoidFunction<N> visitor) |
void |
visitSet(int dimension,
long dimensionalIndex,
VoidFunction<N> visitor) |
void |
visitSet(long[] initial,
int dimension,
VoidFunction<N> visitor) |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
asCollectableAnyD, asPrimitiveAnyD, byteValue, byteValue, equals, floatValue, floatValue, intValue, intValue, longValue, longValue, matrices, shortValue, shortValue
asCollectable1D, asPrimitive1D, axpy, dot, elements, equals, hashCode, nonzeros, supplyTo, toRawCopy1D, toString, wrap, wrap, wrap
reduce
aggregateAll
isAllSmall
accept, isAcceptable
copyComplexArgument, copyComplexImaginary, copyComplexModulus, copyComplexModulusAndArgument, copyComplexReal, copyComplexRealAndImaginary, reset
count, count, count, count, index, index, index, loop, loop, loop, loopAll, loopMatching, mapperOf, reference, shape, step, step, step, step
fillMatching, fillMatching, fillMatching
index, loopAll, loopMatching, loopRange, mapper, size
mix, mix
public static final ArrayAnyD.Factory<BigDecimal> BIG
public static final ArrayAnyD.Factory<ComplexNumber> COMPLEX
public static final ArrayAnyD.Factory<Double> DIRECT32
public static final ArrayAnyD.Factory<Double> DIRECT64
public static final ArrayAnyD.Factory<Double> PRIMITIVE32
public static final ArrayAnyD.Factory<Double> PRIMITIVE64
public static final ArrayAnyD.Factory<Quaternion> QUATERNION
public static final ArrayAnyD.Factory<RationalNumber> RATIONAL
public static <N extends Number> ArrayAnyD.Factory<N> factory(DenseArray.Factory<N> denseArray)
public void add(long index, double addend)
add
in interface Mutate1D
add
in interface MutateAnyD
public void add(long index, Number addend)
add
in interface Mutate1D
add
in interface MutateAnyD
public void add(long[] reference, double addend)
add
in interface MutateAnyD
public void add(long[] reference, Number addend)
add
in interface MutateAnyD
public N aggregateRange(long first, long limit, Aggregator aggregator)
aggregateRange
in interface Access1D.Aggregatable<N extends Number>
public Number aggregateSet(int dimension, long dimensionalIndex, Aggregator aggregator)
aggregateSet
in interface AccessAnyD.Aggregatable<N extends Number>
public Number aggregateSet(long[] initial, int dimension, Aggregator aggregator)
aggregateSet
in interface AccessAnyD.Aggregatable<N extends Number>
@Deprecated public Array1D<N> asArray1D()
public void clear()
public long count()
StructureAnyD
count
in interface Structure1D
count
in interface StructureAnyD
public long count(int dimension)
count
in interface StructureAnyD
public double doubleValue(long index)
AccessAnyD
through
function. What happens is
entirely dictated by how you implement the callback.doubleValue
in interface Access1D<N extends Number>
doubleValue
in interface AccessAnyD<N extends Number>
public double doubleValue(long[] ref)
doubleValue
in interface AccessAnyD<N extends Number>
public void fillAll(N value)
fillAll
in interface Mutate1D.Fillable<N extends Number>
public void fillAll(NullaryFunction<N> supplier)
fillAll
in interface Mutate1D.Fillable<N extends Number>
public void fillOne(long index, Access1D<?> values, long valueIndex)
fillOne
in interface Mutate1D.Fillable<N extends Number>
public void fillOne(long index, N value)
fillOne
in interface Mutate1D.Fillable<N extends Number>
public void fillOne(long index, NullaryFunction<N> supplier)
fillOne
in interface Mutate1D.Fillable<N extends Number>
public void fillOne(long[] reference, N value)
fillOne
in interface MutateAnyD.Fillable<N extends Number>
public void fillOne(long[] reference, NullaryFunction<N> supplier)
fillOne
in interface MutateAnyD.Fillable<N extends Number>
public void fillRange(long first, long limit, N value)
fillRange
in interface Mutate1D.Fillable<N extends Number>
public void fillRange(long first, long limit, NullaryFunction<N> supplier)
fillRange
in interface Mutate1D.Fillable<N extends Number>
public void fillSet(int dimension, long dimensionalIndex, N value)
fillSet
in interface MutateAnyD.Fillable<N extends Number>
public void fillSet(int dimension, long dimensionalIndex, NullaryFunction<N> supplier)
fillSet
in interface MutateAnyD.Fillable<N extends Number>
public void fillSet(long[] initial, int dimension, N value)
fillSet
in interface MutateAnyD.Fillable<N extends Number>
public void fillSet(long[] initial, int dimension, NullaryFunction<N> supplier)
fillSet
in interface MutateAnyD.Fillable<N extends Number>
public N get(long index)
public N get(long[] ref)
get
in interface AccessAnyD<N extends Number>
public long indexOfLargest()
indexOfLargest
in interface Access1D.IndexOf
public long indexOfLargestInRange(long first, long limit)
indexOfLargestInRange
in interface Access1D.IndexOf
public boolean isAbsolute(long index)
isAbsolute
in interface Access1D.Elements
Scalar.isAbsolute()
public boolean isAbsolute(long[] reference)
isAbsolute
in interface AccessAnyD.Elements
Scalar.isAbsolute()
public boolean isSmall(long index, double comparedTo)
isSmall
in interface Access1D.Elements
NormedVectorSpace.isSmall(double)
public boolean isSmall(long[] reference, double comparedTo)
isSmall
in interface AccessAnyD.Elements
NormedVectorSpace.isSmall(double)
public double mix(long[] reference, BinaryFunction<N> mixer, double addend)
mix
in interface MutateAnyD.Mixable<N extends Number>
public N mix(long[] reference, BinaryFunction<N> mixer, N addend)
mix
in interface MutateAnyD.Mixable<N extends Number>
public void modifyAll(UnaryFunction<N> modifier)
modifyAll
in interface Mutate1D.Modifiable<N extends Number>
public void modifyAny(TransformationAnyD<N> modifier)
modifyAny
in interface MutateAnyD.ModifiableReceiver<N extends Number>
public void modifyMatching(Access1D<N> left, BinaryFunction<N> function)
modifyMatching
in interface Mutate1D.Modifiable<N extends Number>
public void modifyMatching(BinaryFunction<N> function, Access1D<N> right)
modifyMatching
in interface Mutate1D.Modifiable<N extends Number>
public void modifyOne(long index, UnaryFunction<N> modifier)
modifyOne
in interface Mutate1D.Modifiable<N extends Number>
public void modifyOne(long[] reference, UnaryFunction<N> modifier)
modifyOne
in interface MutateAnyD.Modifiable<N extends Number>
public void modifyRange(long first, long limit, UnaryFunction<N> modifier)
modifyRange
in interface Mutate1D.Modifiable<N extends Number>
public void modifySet(int dimension, long dimensionalIndex, UnaryFunction<N> modifier)
modifySet
in interface MutateAnyD.Modifiable<N extends Number>
public void modifySet(long[] initial, int dimension, UnaryFunction<N> modifier)
modifySet
in interface MutateAnyD.Modifiable<N extends Number>
public int rank()
rank
in interface StructureAnyD
public Array1D<N> reduce(int dimension, Aggregator aggregator)
reduce
in interface StructureAnyD.ReducibleTo1D<Array1D<N extends Number>>
dimension
- Which of the AnyD-dimensions should be mapped to the resulting 1D structure.aggregator
- How to aggregate the values of the reductionpublic Array2D<N> reduce(int rowDimension, int columnDimension, Aggregator aggregator)
reduce
in interface StructureAnyD.ReducibleTo2D<Array2D<N extends Number>>
rowDimension
- Which of the AnyD-dimensions should be mapped to the rows of the resulting 2D
structure.columnDimension
- Which of the AnyD-dimensions should be mapped to the columns of the
resulting 2D structure.aggregator
- How to aggregate the values of the reductionpublic void set(long index, double value)
set
in interface Mutate1D
set
in interface MutateAnyD
public void set(long index, Number value)
set
in interface Mutate1D
set
in interface MutateAnyD
public void set(long[] reference, double value)
set
in interface MutateAnyD
public void set(long[] reference, Number value)
set
in interface MutateAnyD
public long[] shape()
shape
in interface StructureAnyD
public Array1D<N> sliceRange(long first, long limit)
sliceRange
in interface Access1D.Sliceable<N extends Number>
public Array1D<N> sliceSet(long[] initial, int dimension)
sliceSet
in interface AccessAnyD.Sliceable<N extends Number>
public void visitAll(VoidFunction<N> visitor)
visitAll
in interface Access1D.Visitable<N extends Number>
public void visitOne(long index, VoidFunction<N> visitor)
visitOne
in interface Access1D.Visitable<N extends Number>
public void visitOne(long[] reference, VoidFunction<N> visitor)
visitOne
in interface AccessAnyD.Visitable<N extends Number>
public void visitRange(long first, long limit, VoidFunction<N> visitor)
visitRange
in interface Access1D.Visitable<N extends Number>
public void visitSet(int dimension, long dimensionalIndex, VoidFunction<N> visitor)
visitSet
in interface AccessAnyD.Visitable<N extends Number>
public void visitSet(long[] initial, int dimension, VoidFunction<N> visitor)
visitSet
in interface AccessAnyD.Visitable<N extends Number>
Copyright © 2019 Optimatika. All rights reserved.