Package org.flag4j.operations.dense.real
Class RealDenseDeterminant
java.lang.Object
org.flag4j.operations.dense.real.RealDenseDeterminant
This class contains methods for computing the determinant of a real dense matrix.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic double
Computes the determinant of a square matrix using the LU factorization.static double
Explicitly computes the determinant of a 1x1 matrix.static double
Explicitly computes the determinant of a 2x2 matrix.static double
Explicitly computes the determinant of a 3x3 matrix.static double
Computes the determinant of a square matrix using the LU factorization.static double
Computes the determinant for a triangular matrix.
-
Constructor Details
-
RealDenseDeterminant
private RealDenseDeterminant()
-
-
Method Details
-
det
Computes the determinant of a square matrix using the LU factorization.- Parameters:
A
- Matrix to compute the determinant of.- Returns:
- The determinant of the matrix.
- Throws:
IllegalArgumentException
- If matrix is not square.
-
detLU
Computes the determinant of a square matrix using the LU factorization.- Parameters:
A
- Matrix to compute the determinant of.- Returns:
- The determinant of the matrix.
- Throws:
IllegalArgumentException
- If matrix is not square.
-
det3
Explicitly computes the determinant of a 3x3 matrix.- Parameters:
A
- Matrix to compute the determinant of.- Returns:
- The determinant of the 3x3 matrix.
-
det2
Explicitly computes the determinant of a 2x2 matrix.- Parameters:
A
- Matrix to compute the determinant of.- Returns:
- The determinant of the 2x2 matrix.
-
det1
Explicitly computes the determinant of a 1x1 matrix.- Parameters:
A
- Matrix to compute the determinant of.- Returns:
- The determinant of the 1x1 matrix.
-
detTri
Computes the determinant for a triangular matrix. This method does not check that the matrix is actually triangular.- Parameters:
A
- Triangular matrix.- Returns:
- The determinant of the triangular matrix.
-