|
Tensorium
|
Iterative Jacobi solver with SIMD and OpenMP support. More...
#include <LinearSolver.hpp>
Static Public Member Functions | |
| static Vector< K > | solve (const Matrix< K > &A, const Vector< K > &b, K tol=1e-10, int max_iter=2000) |
| Solve the system using the Jacobi method. | |
Public Attributes | |
| aligned_vector< K > | data |
Iterative Jacobi solver with SIMD and OpenMP support.
Iteratively solves \( Ax = b \) using the Jacobi method. Works best on diagonally dominant matrices.
Update rule:
\[ x_i^{(k+1)} = \frac{1}{A_{ii}} \left(b_i - \sum_{j \ne i} A_{ij} x_j^{(k)} \right) \]
| K | Scalar type (must be floating-point) |
|
inlinestatic |
Solve the system using the Jacobi method.
| A | Matrix \( A \in \mathbb{R}^{n \times n} \) |
| b | Right-hand side vector |
| tol | Convergence tolerance (default = 1e-10) |
| max_iter | Maximum number of iterations (default = 2000) |
| std::runtime_error | if diagonal is zero or near-zero |
References MathsUtils::_abs(), tensorium::Matrix< K, RowMajor >::cols, tensorium::Matrix< K, RowMajor >::rows, sigma, and tensorium::Vector< K >::size().
Referenced by tensorium::jacobi_solve().
| aligned_vector<K> tensorium::solver::Jacobi< K >::data |