Skip to content

Commit

Permalink
docstrings for matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
GraDje13 committed Jan 14, 2025
1 parent 7f38430 commit a77a7e3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/matrix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ pub struct SquareMatrix<T> {
}

#[derive(Clone, Copy, Debug)]
/// Error type for when problems occur in the matrix algorithms
pub enum MatrixError {
/// Used when the determinant of L is zero.
ZeroDet,
/// Used when the stability condition is not met.
Unstable,
}

Expand Down Expand Up @@ -290,6 +293,7 @@ impl<T> SquareMatrix<T> {
}

#[derive(Debug, Clone)]
/// Struct containing the result of the matrix algorithms. q is the Cholesky decomposition of l.
pub struct DecompositionResult<T: MomTropFloat> {
pub determinant: T,
pub inverse: SquareMatrix<T>,
Expand Down

0 comments on commit a77a7e3

Please sign in to comment.