Linear System Solvers

Linear System Solvers

At run-time, the user can select the linear solver to be used to solve each matrix equation generated by a given application. OpenFOAM includes:

  • PBiCG - preconditioned bi-conjugate gradient solver for asymmetric matrices;
  • PCG - preconditioned conjugate gradient solver for symmetric matrices;
  • GAMG - generalised geometric-algebraic multi-grid solver
  • smoothSolver - solver using a smoother for both symmetric and asymmetric matrices
  • diagonalSolver - diagonal solver for both symmetric and asymmetric matrices

The solvers are generalised so that the user can select the preconditioner and/or smoother for each solver. The preconditioners include the diagonal incomplete-Cholesky (DIC) and diagonal incomplete LU (DILU), and a GAMG preconditioner amongst others. The smoothers include DIC, DILU and Gauss-Seidel; variants of DIC and DILU exist with additional Gauss-Seidel smoothing.

The GAMG solver can often be the optimal choice, particularly for solving the pressure equation. GAMG uses the principle of: generating a quick solution on a mesh with a small number of cells; mapping this solution onto a finer mesh; using it as an initial guess to obtain an accurate solution on the fine mesh. Its aim is to be faster than standard methods when the increase in speed by solving first on coarser meshes outweighs the additional costs of mesh refinement and mapping of field data. The switching from a coarse mesh from the fine mesh is handled by agglomeration of cells, either by a geometric agglomeration where cells are joined together, or by an algebraic agglomeration where matrix coefficients are joined.