Linear equation solvers
Introduction
This section describes the linear solver options available to solve the matrix system
where:
: coefficient matrix
: vector of unknowns
: source vector
If the coefficient matrix only has values on its diagonal, the solution vector can be obtained inverting the matrix system:
Where the inverse of the diagonal matrix is simply:
This is available as the diagonalSolver. More typically the matrix cannot be
inverted easily and the system is solved using iterative methods, as described
in the following sections.
Options
Solver options include:
Solver control
Common usage
minIter: minimum number of solver iterationsmaxIter: maximum number of solver iterationsnSweeps: number of solver iterations between checks for solver convergence
Implementation details
Matrix structure
Matrix coefficients are stored in upper-triangular order
- neighbour cell index always higher than owner cell index across a face
- when looping over cell faces, the face index increases with increasing cell index
- for the 1-D case, if cell index 0 is at the boundary, this equates to a monotonic increase in cell numbers, i.e. defines a continuous sweep across the 1-D region
- used in Gauss-Seidel method