U
- Unit; the unit of this MutableFloatMatrixpublic abstract class MutableFloatMatrix<U extends Unit<U>> extends FloatMatrix<U> implements WriteFloatMatrixFunctions<U>, FloatMathFunctions<MutableFloatMatrix<U>>
This file was generated by the OpenTrafficSim value classes generator, 09 mrt, 2015
Copyright (c) 2014 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Modifier and Type | Class and Description |
---|---|
static class |
MutableFloatMatrix.Abs<U extends Unit<U>> |
static class |
MutableFloatMatrix.Rel<U extends Unit<U>> |
Modifier | Constructor and Description |
---|---|
protected |
MutableFloatMatrix(U unit)
Construct a new MutableFloatMatrix.
|
Modifier and Type | Method and Description |
---|---|
void |
assign(cern.colt.function.tfloat.FloatFunction f)
Execute a function on a cell by cell basis.
|
protected void |
checkCopyOnWrite()
Check the copyOnWrite flag and, if it is set, make a deep copy of the data and clear the flag.
|
protected MutableFloatMatrix.Rel<U> |
decrementBy(FloatMatrix.Abs<U> abs)
Decrement the values in this Relative MutableFloatMatrix by the corresponding values in an Absolute FloatMatrix.
|
protected MutableFloatMatrix<U> |
decrementByImpl(FloatMatrix.Rel<U> rel)
Decrement the corresponding values of this Relative FloatMatrix from the values of this MutableFloatMatrix.
|
MutableFloatMatrix<U> |
divide(float constant)
Scale the value(s) by the inverse of a factor; i.e.
|
abstract FloatMatrix<U> |
immutable()
Make (immutable) FloatMatrix equivalent for any type of MutableFloatMatrix.
|
protected MutableFloatMatrix<U> |
incrementByImpl(FloatMatrix.Rel<U> rel)
Increment the values in this MutableFloatMatrix by the corresponding values in a Relative FloatMatrix.
|
MutableFloatMatrix<U> |
multiply(float constant)
Scale the value(s) by a factor.
|
void |
normalize()
Normalize the matrix, i.e.
|
protected MutableFloatMatrix<U> |
scaleValueByValue(float[][] factor)
Scale the values in this MutableFloatMatrix by the corresponding values in a float array.
|
protected void |
scaleValueByValue(FloatMatrix<?> factor)
Scale the values in this MutableFloatMatrix by the corresponding values in a FloatMatrix.
|
void |
set(int row,
int column,
FloatScalar<U> value)
Replace the value at row, column by the supplied value which is in a compatible unit.
|
void |
setInUnit(int row,
int column,
float value,
U valueUnit)
Replace the value at row, column by the supplied value which is expressed in a supplied (compatible) unit.
|
void |
setSI(int row,
int column,
float valueSI)
Replace the value at row, column by the supplied value which is expressed in the standard SI unit.
|
cardinality, checkIndex, checkNonEmpty, checkSize, checkSize, columns, createMatrix2D, deepCopyData, deepCopyOfData, denseToSparse, denseToSparse, det, equals, getInUnit, getInUnit, getMatrixSI, getSI, getValuesInUnit, getValuesInUnit, getValuesSI, hashCode, initialize, initialize, initialize, interpolate, interpolate, interpolate, interpolate, minus, minus, minus, minus, minus, minus, minus, minus, minus, mutable, plus, plus, plus, plus, plus, plus, rows, safeGet, safeSet, solve, sparseToDense, sparseToDense, times, times, times, times, times, times, times, times, times, times, toString, toString, toString, toString, zSum
expressAsSIUnit, expressAsSpecifiedUnit, getUnit, isAbsolute, isRelative
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
abs, acos, asin, atan, cbrt, ceil, cos, cosh, exp, expm1, floor, inv, log, log10, log1p, pow, rint, round, signum, sin, sinh, sqrt, tan, tanh, toDegrees, toRadians
get
protected MutableFloatMatrix(U unit)
unit
- U; the unit of the new MutableFloatMatrixpublic final void normalize() throws ValueException
normalize
in interface WriteFloatMatrixFunctions<U extends Unit<U>>
ValueException
- when the sum of the values is zero and normalization is not possiblepublic abstract FloatMatrix<U> immutable()
protected final void checkCopyOnWrite()
public final void setSI(int row, int column, float valueSI) throws ValueException
setSI
in interface WriteFloatMatrixFunctions<U extends Unit<U>>
row
- int; row of the value to replacecolumn
- int; column of the value to replacevalueSI
- float; the value to store (expressed in the standard SI unit)ValueException
- when row or column out of range (row < 0 or row >= rows() or column < 0 or column
>= columns())public final void set(int row, int column, FloatScalar<U> value) throws ValueException
set
in interface WriteFloatMatrixFunctions<U extends Unit<U>>
row
- int; row of the value to replacecolumn
- int; column of the value to replacevalue
- FloatScalar<U>; the strongly typed value to storeValueException
- when row or column out of range (row < 0 or row >= rows() or column < 0 or column
>= columns())public final void setInUnit(int row, int column, float value, U valueUnit) throws ValueException
setInUnit
in interface WriteFloatMatrixFunctions<U extends Unit<U>>
row
- int; row of the value to replacecolumn
- int; column of the value to replacevalue
- float; the value to store (which is expressed in valueUnit)valueUnit
- U; unit of the supplied valueValueException
- when row or column out of range (row < 0 or row >= rows() or column < 0 or column
>= columns())public final void assign(cern.colt.function.tfloat.FloatFunction f)
f
- cern.colt.function.tfloat.FloatFunction; the function to applypublic final MutableFloatMatrix<U> multiply(float constant)
multiply
in interface FloatMathFunctions<MutableFloatMatrix<U extends Unit<U>>>
constant
- float; the multiplierpublic final MutableFloatMatrix<U> divide(float constant)
divide
in interface FloatMathFunctions<MutableFloatMatrix<U extends Unit<U>>>
constant
- float; the divisorprotected final MutableFloatMatrix<U> incrementByImpl(FloatMatrix.Rel<U> rel) throws ValueException
rel
- FloatMatrix.Rel<U>; the Relative FloatMatrixValueException
- when the matrices do not have the same sizeprotected final MutableFloatMatrix<U> decrementByImpl(FloatMatrix.Rel<U> rel) throws ValueException
rel
- FloatMatrix.Rel<U>; the Relative FloatMatrixValueException
- when the matrices do not have the same sizeprotected final MutableFloatMatrix.Rel<U> decrementBy(FloatMatrix.Abs<U> abs) throws ValueException
abs
- FloatMatrix.Abs<U>; the Absolute FloatMatrixValueException
- when the matrices do not have the same sizeprotected final void scaleValueByValue(FloatMatrix<?> factor) throws ValueException
factor
- FloatMatrix<?>; contains the values by which to scale the corresponding values in this
MutableFloatMatrixValueException
- when the matrices do not have the same sizeprotected final MutableFloatMatrix<U> scaleValueByValue(float[][] factor) throws ValueException
factor
- float[][]; contains the values by which to scale the corresponding values in this
MutableFloatMatrixValueException
- when the matrix and the array do not have the same sizeCopyright © 2014–2015 Delft University of Technology. All rights reserved.