Class GenericMatrix<E>
java.lang.Object
org.episteme.core.mathematics.linearalgebra.matrices.GenericMatrix<E>
- All Implemented Interfaces:
Matrix<E>, AbelianGroup<Matrix<E>>, AbelianMonoid<Matrix<E>>, Group<Matrix<E>>, Magma<Matrix<E>>, Monoid<Matrix<E>>, Ring<Matrix<E>>, Semiring<Matrix<E>>, Set<Matrix<E>>, Module<Matrix<E>, E>
- Direct Known Subclasses:
DenseMatrix, MMapMatrix, NativeRealDoubleMatrix, NativeRealFloatMatrix, RealDoubleMatrix, SIMDRealDoubleMatrix, SIMDRealFloatMatrix, SparseMatrix, TiledMatrix
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionGenericMatrix(E[][] data, Ring<E> ring) Creates a GenericMatrix with automatic storage selection.GenericMatrix(MatrixStorage<E> storage, LinearAlgebraProvider<E> provider, Ring<E> ring) Public constructor for Providers and internal use. -
Method Summary
Modifier and TypeMethodDescriptionReturns the sum of this matrix and another.cholesky()Computes the Cholesky decomposition of this matrix.intcols()Returns the number of columns in this matrix.booleanTests whether this set contains the specified element.Returns a human-readable description of this set.Returns the determinant of this matrix.eigen()Computes the eigenvalue decomposition of this matrix.get(int row, int col) Returns the element at the specified row and column.getColumn(int col) Returns the column at the specified index as a vector.getField()Returns the provider that created or manages this matrix.getRow(int row) Returns the row at the specified index as a vector.Returns the ring of scalars for this module.Returns the underlying storage of this matrix.getSubMatrix(int rowStart, int rowEnd, int colStart, int colEnd) Returns a submatrix of this matrix.inverse()Returns the multiplicative inverse of this matrix.lu()Computes the LU decomposition of this matrix.Returns the product of this matrix and another.Multiplies this matrix by a vector.negate()Returns the negation of this matrix (-this).one()Returns the multiplicative identity (one element).qr()Computes the QR decomposition of this matrix.introws()Returns the number of rows in this matrix.Scalar multiplication (r × m).voidsvd()Computes the Singular Value Decomposition (SVD) of this matrix.trace()Returns the trace of this matrix (sum of diagonal elements).Returns the transpose of this matrix.withProvider(LinearAlgebraProvider<E> provider) Returns a new view of this matrix with a different provider.zero()Returns the zero matrix of the same dimensions.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface AbelianGroup
negate, subtractMethods inherited from interface Matrix
add, identity, inverse, isCommutative, isEmpty, isMultiplicationCommutative, map, multiply, operate, scale, subtract, toTensorMethods inherited from interface Monoid
isAssociative
-
Field Details
-
storage
-
provider
-
ring
-
-
Constructor Details
-
GenericMatrix
-
GenericMatrix
Public constructor for Providers and internal use.
-
-
Method Details
-
description
Description copied from interface:SetReturns a human-readable description of this set.Examples:
- "â„ (Real Numbers)"
- "ℤ/12ℤ (Integers modulo 12)"
- "{1, 2, 3, 4, 5}"
- Specified by:
descriptionin interfaceSet<E>- Returns:
- a description of this set
-
contains
Description copied from interface:SetTests whether this set contains the specified element.This is the fundamental operation of a set - membership testing.
-
withProvider
Returns a new view of this matrix with a different provider. -
set
-
rows
-
cols
-
get
-
add
-
multiply
-
transpose
-
trace
-
getSubMatrix
-
getRow
-
getColumn
-
determinant
Description copied from interface:MatrixReturns the determinant of this matrix.- Specified by:
determinantin interfaceMatrix<E>
-
inverse
-
multiply
-
lu
-
qr
-
svd
-
cholesky
-
eigen
-
negate
-
zero
-
one
-
getScalarRing
-
scale
Description copied from interface:ModuleScalar multiplication (r × m). -
getStorage
Description copied from interface:MatrixReturns the underlying storage of this matrix.- Specified by:
getStoragein interfaceMatrix<E>- Returns:
- the matrix storage
-
getProvider
Description copied from interface:MatrixReturns the provider that created or manages this matrix.- Specified by:
getProviderin interfaceMatrix<E>- Returns:
- the linear algebra provider
-
getField
-