Class AtA
java.lang.Object
smile.tensor.AtA
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(int i, int j, double x) SetsA[i,j] += x
.copy()
Returns a deep copy of matrix.void
div
(int i, int j, double x) SetsA[i,j] /= x
.double
get
(int i, int j) ReturnsA[i,j]
.long
length()
Returns the number of tensor elements.void
mul
(int i, int j, double x) SetsA[i,j] *= x
.void
Matrix-vector multiplication.void
Matrix-vector multiplicationA * x
.int
ncol()
Returns the number of columns.int
nrow()
Returns the number of rows.Returns the element data type.scale
(double alpha) A *= alphavoid
set
(int i, int j, double x) SetsA[i,j] = x
.void
sub
(int i, int j, double x) SetsA[i,j] -= x
.Returns the transpose of matrix.void
Matrix-vector multiplicationA' * x
.
-
Constructor Details
-
AtA
-
-
Method Details
-
scalarType
Description copied from interface:Tensor
Returns the element data type.- Specified by:
scalarType
in interfaceTensor
- Returns:
- the element data type.
-
nrow
-
ncol
-
length
public long length()Description copied from interface:Tensor
Returns the number of tensor elements. For tensors with packed storage (e.g., BandMatrix, SparseMatrix, SymmMatrix), it returns the number of non-zero elements. -
get
-
set
-
add
-
sub
-
mul
-
div
-
scale
-
copy
-
transpose
-
mv
Description copied from interface:Matrix
Matrix-vector multiplication.y = alpha * A * x + beta * y
-
mv
Description copied from interface:Matrix
Matrix-vector multiplicationA * x
. -
tv
Description copied from interface:Matrix
Matrix-vector multiplicationA' * x
.
-