Uses of Class
org.flag4j.arrays.sparse.CooMatrix
Packages that use CooMatrix
Package
Description
Provides implementations for dense tensors, matrices, and vectors.
Contains implementations for sparse tensors, matrices, and vectors.
This package contains classes for Pseudo-random generation of real/complex numbers, and arrays, vectors,
matrices, and tensors.
-
Uses of CooMatrix in org.flag4j.arrays.backend.field_arrays
Methods in org.flag4j.arrays.backend.field_arrays that return CooMatrix -
Uses of CooMatrix in org.flag4j.arrays.backend.smart_visitors
Methods in org.flag4j.arrays.backend.smart_visitors with parameters of type CooMatrixModifier and TypeMethodDescriptionMatrixMixin
<?, ?, ?, ?> MatrixMixin
<?, ?, ?, ?> MatrixMixin
<?, ?, ?, ?> MatrixMixin
<?, ?, ?, ?> abstract T
MatrixMixin
<?, ?, ?, ?> -
Uses of CooMatrix in org.flag4j.arrays.dense
Methods in org.flag4j.arrays.dense that return CooMatrixModifier and TypeMethodDescriptionComputes the element-wise product of two matrices.Matrix.toCoo()
Converts this dense tensor to an equivalent sparse COO tensor.Methods in org.flag4j.arrays.dense with parameters of type CooMatrixModifier and TypeMethodDescriptionComputes the element-wise sum between two tensors of the same shape.Sums this matrix with a real sparse COO matrix.Computes the element-wise multiplication of two tensors of the same shape.Computes the element-wise product of two matrices.Computes the matrix multiplication between two matrices.Computes the matrix multiplication between this matrix and a real sparse COO matrix.Computes the element-wise difference between two tensors of the same shape.Computes the difference of this matrix with a real sparse COO matrix. -
Uses of CooMatrix in org.flag4j.arrays.sparse
Subclasses with type arguments of type CooMatrix in org.flag4j.arrays.sparseModifier and TypeClassDescriptionclass
A real sparse matrix stored in coordinate list (COO) format.Classes in org.flag4j.arrays.sparse that implement interfaces with type arguments of type CooMatrixModifier and TypeClassDescriptionclass
A real sparse matrix stored in coordinate list (COO) format.class
A real sparse vector stored in coordinate list (COO) format.Methods in org.flag4j.arrays.sparse that return CooMatrixModifier and TypeMethodDescriptionCooRingMatrix.abs()
Computes the element-wise absolute value of this tensor.CooMatrix.add
(double b) Adds a scalar value to each non-zero element of this tensor.Computes the element-wise sum between two tensors of the same shape.Stacks matrices along rows.Augments a vector to this matrix.CooMatrix.coalesce()
Coalesces this sparse COO matrix.CooMatrix.coalesce
(BinaryOperator<Double> aggregator) Coalesces this sparse COO matrix.Computes the element-wise quotient between two tensors.CooMatrix.dropZeros()
Drops any explicit zeros in this sparse COO matrix.Computes the element-wise product between two matrices.Computes the element-wise multiplication of two tensors of the same shape.CooMatrix.flatten()
Flattens tensor to single dimension while preserving order of data.CooMatrix.flatten
(int axis) Flattens a tensor along the specified axis.CooMatrix.getSlice
(int rowStart, int rowEnd, int colStart, int colEnd) Gets a specified slice of this matrix.CooMatrix.getTriL
(int diagOffset) Extracts the lower-triangular portion of this matrix with a specified diagonal offset.CooMatrix.getTriU
(int diagOffset) Extracts the upper-triangular portion of this matrix with a specified diagonal offset.CooMatrix.H()
Computes the conjugate transpose of a tensor by exchanging the first and last axes of this tensor and conjugating the exchanged values.CooMatrix.makeLikeTensor
(Shape shape, double[] entries) Constructs a sparse COO matrix of the same type as this tensor with the given the shape and data and indices copied from this matrix.CooMatrix.recip()
Computes the element-wise reciprocals of non-zero values of this tensor.CooMatrix.removeCol
(int colIndex) Removes a specified column from this matrix.CooMatrix.removeCols
(int... colIndices) Removes a specified set of columns from this matrix.CooMatrix.removeRow
(int rowIndex) Removes a specified row from this matrix.CooMatrix.removeRows
(int... rowIndices) Removes a specified set of rows from this matrix.CooVector.repeat
(int n, int axis) Repeats a vectorn
times along a certain axis to create a matrix.Copies and reshapes this tensor.Sets the element of this tensor at the specified indices.Sets an index of this matrix to the specified value.Sets a column of this matrix at the given index to the specified values.CooMatrix.setRow
(double[] row, int rowIdx) Sets a specified row of this matrix to an array.Sets a row of this matrix at the given index to the specified values.CooMatrix.setSliceCopy
(CooMatrix values, int rowStart, int colStart) Creates a copy of this matrix and sets a slice of the copy to the specified values.CooMatrix.sortIndices()
Sorts the indices of this tensor in lexicographical order while maintaining the associated value for each index.Stacks matrices along columns.Stacks two vectors vertically as if they were row vectors to form a matrix with two rows.Stacks two vectors along specified axis.CooMatrix.sub
(double b) Subtracts a scalar value from each non-zero element of this tensor.Computes the element-wise difference between two tensors of the same shape.CooMatrix.swapCols
(int colIndex1, int colIndex2) Swaps specified columns in the matrix.CooMatrix.swapRows
(int rowIndex1, int rowIndex2) Swaps specified rows in the matrix.CooMatrix.T()
Computes the transpose of a tensor by exchanging the first and last axes of this tensor.CooMatrix.T
(int... axes) Computes the transpose of this tensor.CooMatrix.T
(int axis1, int axis2) Computes the transpose of a tensor by exchangingaxis1
andaxis2
.CooMatrix.tensorTr
(int axis1, int axis2) Computes the generalized trace of this tensor along the specified axes.CsrMatrix.toCoo()
Converts this CSR matrix to an equivalentCOO matrix
.PermutationMatrix.toCoo()
Converts this permutation matrix to areal sparse COO matrix
.CooVector.toMatrix
(boolean columVector) Converts a vector to an equivalent matrix representing either a row or column vector.CooCMatrix.toReal()
Converts this matrix to an equivalent real matrix.Methods in org.flag4j.arrays.sparse with parameters of type CooMatrixModifier and TypeMethodDescriptionComputes the element-wise sum between two tensors of the same shape.Augments a real COO matrix to this matrix.Stacks matrices along rows.Computes the element-wise quotient between two tensors.Computes the element-wise multiplication between this tensor and a real COO matrix.Computes the element-wise multiplication of two tensors of the same shape.Computes the Frobenius inner product of two matrices.Computes the matrix multiplication between two matrices.CooMatrix.multTranspose
(CooMatrix b) Multiplies this matrix with the transpose of theb
tensor as if bythis.mult(b.T())
.CooMatrix.setSliceCopy
(CooMatrix values, int rowStart, int colStart) Creates a copy of this matrix and sets a slice of the copy to the specified values.Stacks matrices along columns.Computes the element-wise difference to two matrices.Computes the element-wise difference between two tensors of the same shape.Computes the tensor contraction of this tensor with a specified tensor over the specified set of axes.Constructors in org.flag4j.arrays.sparse with parameters of type CooMatrix -
Uses of CooMatrix in org.flag4j.linalg
Methods in org.flag4j.linalg that return CooMatrixModifier and TypeMethodDescriptionstatic CooMatrix
Computes the direct sum of two matrices.static CooMatrix
Computes the direct sum of two matrices.static CooMatrix
DirectSum.invDirectSum
(CooMatrix A, Matrix B) Computes direct sum from bottom left to top right of two matrices.static CooMatrix
DirectSum.invDirectSum
(CooMatrix A, CooMatrix B) Computes direct sum from bottom left to top right of two matrices.Methods in org.flag4j.linalg with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic CMatrix
Computes the direct sum of two matrices.static Matrix
Computes the direct sum of two matrices.static CooCMatrix
DirectSum.directSum
(CooCMatrix A, CooMatrix B) Computes the direct sum of two matrices.static CooCMatrix
Computes the direct sum of two matrices.static CooMatrix
Computes the direct sum of two matrices.static CooCMatrix
DirectSum.directSum
(CooMatrix A, CooCMatrix B) Computes the direct sum of two matrices.static CooMatrix
Computes the direct sum of two matrices.static CMatrix
DirectSum.invDirectSum
(CMatrix A, CooMatrix B) Computes direct sum from bottom left to top right of two matrices.static Matrix
DirectSum.invDirectSum
(Matrix A, CooMatrix B) Computes direct sum from bottom left to top right of two matrices.static CooCMatrix
DirectSum.invDirectSum
(CooCMatrix A, CooMatrix B) Computes direct sum from bottom left to top right of two matrices.static CooCMatrix
DirectSum.invDirectSum
(CooMatrix A, CMatrix B) Computes direct sum from bottom left to top right of two matrices.static CooMatrix
DirectSum.invDirectSum
(CooMatrix A, Matrix B) Computes direct sum from bottom left to top right of two matrices.static CooCMatrix
DirectSum.invDirectSum
(CooMatrix A, CooCMatrix B) Computes direct sum from bottom left to top right of two matrices.static CooMatrix
DirectSum.invDirectSum
(CooMatrix A, CooMatrix B) Computes direct sum from bottom left to top right of two matrices.static double
Computes the max norm of a matrix.static double
Computes the Frobenius (L2, 2) norm of this complex COO matrix.static double
Computes the Lp, q norm of a real COO matrix. -
Uses of CooMatrix in org.flag4j.linalg.ops.dense_sparse.coo.real
Methods in org.flag4j.linalg.ops.dense_sparse.coo.real that return CooMatrixModifier and TypeMethodDescriptionstatic CooMatrix
Computes the element-wise division between a real sparse matrix and a real dense matrix.static CooMatrix
Computes the element-wise multiplication between a real dense matrix and a real sparse matrix.Methods in org.flag4j.linalg.ops.dense_sparse.coo.real with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic Matrix
Adds a real dense matrix to a real sparse matrix.static void
Adds a real dense matrix to a real sparse matrix and stores the result in the first matrix.static Matrix
RealDenseSparseMatrixOps.addToEachCol
(CooMatrix src, Vector col) Adds a dense vector to each column as if the vector is a column vector.static Matrix
RealDenseSparseMatrixOps.addToEachRow
(CooMatrix src, Vector row) Adds a dense vector to add to each row as if the vector is a row vector.static CooMatrix
Computes the element-wise division between a real sparse matrix and a real dense matrix.static CooMatrix
Computes the element-wise multiplication between a real dense matrix and a real sparse matrix.static boolean
RealDenseSparseEquals.matrixEquals
(Matrix A, CooMatrix B) Checks if a real dense matrix is equal to a real sparse matrix.static Matrix
Subtracts a real sparse matrix from a real dense matrix.static Matrix
Subtracts a real dense matrix from a real sparse matrix.static void
Subtracts a real sparse matrix from a real dense matrix and stores the result in the first matrix. -
Uses of CooMatrix in org.flag4j.linalg.ops.dense_sparse.coo.real_complex
Methods in org.flag4j.linalg.ops.dense_sparse.coo.real_complex with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic CooCMatrix
Computes the element-wise division between a real sparse matrix and a complex dense matrix.static CooCMatrix
Computes the element-wise multiplication between a complex dense matrix and a real sparse matrix.static boolean
RealComplexDenseSparseEquals.matrixEquals
(CMatrix A, CooMatrix B) Checks if a dense complex matrix is equal to a real sparse matrix. -
Uses of CooMatrix in org.flag4j.linalg.ops.dense_sparse.coo.real_field_ops
Methods in org.flag4j.linalg.ops.dense_sparse.coo.real_field_ops with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic <T extends Field<T>>
AbstractDenseFieldMatrix<?, ?, T> RealFieldDenseCooMatrixOps.add
(AbstractDenseFieldMatrix<?, ?, T> src1, CooMatrix src2) Adds a real dense matrix to a real sparse matrix.static <T extends Field<T>>
voidRealFieldDenseCooMatrixOps.addEq
(AbstractDenseFieldMatrix<?, ?, T> src1, CooMatrix src2) Adds a complex dense matrix to a real sparse matrix and stores the result in the first matrix.static <T extends Field<T>>
voidRealFieldDenseCooMatrixOps.elemMult
(AbstractDenseFieldMatrix<?, ?, T> src1, CooMatrix src2, Field<T>[] destEntries) Computes the element-wise multiplication between two matrices.static <T extends Field<T>>
AbstractDenseFieldMatrix<?, ?, T> RealFieldDenseCooMatrixOps.sub
(AbstractDenseFieldMatrix<?, ?, T> src1, CooMatrix src2) Subtracts a real sparse matrix from a complex dense matrix.static <T extends Field<T>>
AbstractDenseFieldMatrix<?, ?, T> RealFieldDenseCooMatrixOps.sub
(CooMatrix src1, AbstractDenseFieldMatrix<?, ?, T> src2) Subtracts a real sparse matrix from a real dense matrix.static <T extends Field<T>>
voidRealFieldDenseCooMatrixOps.subEq
(AbstractDenseFieldMatrix<?, ?, T> src1, CooMatrix src2) Subtracts a real sparse matrix from a complex dense matrix and stores the result in the first matrix. -
Uses of CooMatrix in org.flag4j.linalg.ops.sparse.coo.real
Methods in org.flag4j.linalg.ops.sparse.coo.real that return CooMatrixModifier and TypeMethodDescriptionstatic CooMatrix
Adds two real sparse matrices.static CooMatrix
Multiplies two sparse matrices element-wise.static CooMatrix
Gets a specified rectangular slice of a sparse matrix.static CooMatrix
Sets the specified element from a sparse matrix.static CooMatrix
Removes a specified column from a sparse matrix.static CooMatrix
RealSparseMatrixManipulations.removeCols
(CooMatrix src, int... colIdxs) Removes a list of specified columns from a sparse matrix.static CooMatrix
Removes a specified row from a sparse matrix.static CooMatrix
RealSparseMatrixManipulations.removeRows
(CooMatrix src, int... rowIdxs) Removes multiple rows from a real sparse matrix.static CooMatrix
Repeats a vectorn
times along a certain axis to create a matrix.static CooMatrix
Sets a column of a sparse matrix to the data of a dense array.static CooMatrix
Sets a column of a sparse matrix to the values in a sparse tensor.static CooMatrix
Sets a specified row of a real sparse matrix to the values of a dense array.static CooMatrix
Sets a specified row of a real sparse COO matrix to the values in a sparse COO vector.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense array.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense array.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense matrix.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of another sparse matrix.static CooMatrix
Stacks two vectors along columns as if they were row vectors.static CooMatrix
Computes the subtraction between two real sparse matrices.static CooMatrix
Swaps two columns, in place, in a sparse matrix.static CooMatrix
Swaps two rows, in place, in a sparse matrix.Methods in org.flag4j.linalg.ops.sparse.coo.real with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic Matrix
Adds a double all data (including zero values) of a real sparse matrix.static CooMatrix
Adds two real sparse matrices.static Matrix
RealSparseMatrixOps.addToEachCol
(CooMatrix src, CooVector col) Adds a sparse vector to each column of a sparse matrix as if the vector is a column vector.static Matrix
RealSparseMatrixOps.addToEachRow
(CooMatrix src, CooVector row) Adds a sparse vector to each row of a sparse matrix as if the vector is a row vector.static boolean
RealSparseEquals.allCloseMatrix
(CooMatrix src1, CooMatrix src2, double relTol, double absTol) Checks that all non-zero data are "close" according toRealProperties.allClose(double[], double[])
and * all indices are the same.static boolean
RealSparseEquals.cooMatrixEquals
(CooMatrix src1, CooMatrix src2) Checks if two real sparse matrices are real.static CooMatrix
Multiplies two sparse matrices element-wise.static CooVector
Gets a specified column from this sparse matrix.static CooVector
Gets a specified column range from this sparse matrix.static CooVector
Gets a specified row from this sparse matrix.static CooVector
Gets a specified row range from this sparse matrix.static CooMatrix
Gets a specified rectangular slice of a sparse matrix.static boolean
RealSparseMatrixProperties.isCloseToIdentity
(CooMatrix src) Checks if a real sparse matrix is close to the identity matrix.static boolean
RealSparseMatrixProperties.isIdentity
(CooMatrix src) Checks if a real sparse matrix is the identity matrix.static double
Gets the specified element from a sparse matrix.static double
RealSparseNorms.matrixNormL2
(CooMatrix src) Computes the L2 norm of a matrix.static double
RealSparseNorms.matrixNormLp
(CooMatrix src, double p) Computes the Lp norm of a matrix.static double
RealSparseNorms.matrixNormLpq
(CooMatrix src, double p, double q) Computes the Lp, q norm of a matrix.static CooMatrix
Sets the specified element from a sparse matrix.static CooMatrix
Removes a specified column from a sparse matrix.static CooMatrix
RealSparseMatrixManipulations.removeCols
(CooMatrix src, int... colIdxs) Removes a list of specified columns from a sparse matrix.static CooMatrix
Removes a specified row from a sparse matrix.static CooMatrix
RealSparseMatrixManipulations.removeRows
(CooMatrix src, int... rowIdxs) Removes multiple rows from a real sparse matrix.static CooMatrix
Sets a column of a sparse matrix to the data of a dense array.static CooMatrix
Sets a column of a sparse matrix to the values in a sparse tensor.static CooMatrix
Sets a specified row of a real sparse matrix to the values of a dense array.static CooMatrix
Sets a specified row of a real sparse COO matrix to the values in a sparse COO vector.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense array.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense array.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of a dense matrix.static CooMatrix
Copies a sparse matrix and sets a slice of the sparse matrix to the data of another sparse matrix.static Matrix
Subtracts a double from all data (including zero values) of a real sparse matrix.static CooMatrix
Computes the subtraction between two real sparse matrices.static CooMatrix
Swaps two columns, in place, in a sparse matrix.static CooMatrix
Swaps two rows, in place, in a sparse matrix. -
Uses of CooMatrix in org.flag4j.linalg.ops.sparse.coo.real_complex
Methods in org.flag4j.linalg.ops.sparse.coo.real_complex with parameters of type CooMatrixModifier and TypeMethodDescriptionstatic CooCMatrix
RealComplexSparseMatOps.add
(CooCMatrix src1, CooMatrix src2) Adds a real sparse matrix to a complex sparse matrix.static CMatrix
RealComplexSparseMatOps.add
(CooMatrix src, Complex128 a) Adds a complex number to all data (including zero values) of a real sparse matrix.static CMatrix
RealComplexSparseMatOps.addToEachCol
(CooMatrix src, CooCVector col) Adds a sparse vector to each column of a sparse matrix as if the vector is a column vector.static CMatrix
RealComplexSparseMatOps.addToEachRow
(CooMatrix src, CooCVector row) Adds a sparse vector to each row of a sparse matrix as if the vector is a row vector.static CooCMatrix
RealComplexCooConcats.augment
(CooCMatrix a, CooMatrix b) Augments two matrices.static CooCMatrix
RealComplexSparseMatOps.elemMult
(CooCMatrix src1, CooMatrix src2) Multiplies two sparse matrices element-wise.static boolean
RealComplexSparseEquals.matrixEquals
(CooMatrix a, CooCMatrix b) Checks if a real sparse matrix and complex sparse matrix are equal.static CooCMatrix
RealComplexSparseMatOps.sub
(CooCMatrix src1, CooMatrix src2) Subtracts a real sparse matrix from a complex sparse matrix.static CMatrix
RealComplexSparseMatOps.sub
(CooMatrix src, Complex128 a) Adds a complex number to all data (including zero values) of a real sparse matrix.static CooCMatrix
RealComplexSparseMatOps.sub
(CooMatrix src1, CooCMatrix src2) Subtracts a complex sparse matrix from a real sparse matrix. -
Uses of CooMatrix in org.flag4j.rng
Methods in org.flag4j.rng that return CooMatrixModifier and TypeMethodDescriptionRandomSparseTensor.randomCooMatrix
(int rows, int cols, double min, double max, double sparsity) Generates a random sparse matrix with the specified sparsity.RandomSparseTensor.randomCooMatrix
(int rows, int cols, double min, double max, int numNonZeroEntries) Generates a random sparse matrix with the specified number of non-zero data.RandomSparseTensor.randomCooMatrix
(Shape shape, double min, double max, double sparsity) Generates a random sparse matrix with the specified sparsity.RandomSparseTensor.randomCooMatrix
(Shape shape, double min, double max, int numNonZeroEntries) Generates a random sparse matrix with the specified number of non-zero data.RandomSparseTensor.randomSymmetricCooMatrix
(int size, int min, int max, double sparsity) Generates a symmetricCOO matrix
filled with pseudorandom values uniformly distributed in[min, max)
.