darsia.BeckmannCGSolver#

class BeckmannCGSolver(amg_options, linear_solver_options)[source]#

Bases: BeckmannLinearSolver

Methods

setup(matrix)

Setup an CG solver with AMG preconditioner for the given matrix.

Attributes

amg_options

dict: options for the AMG solver

solver_options

dict: options for the iterative linear solver

linear_solver

Initialize CG solver with AMG preconditioner.

setup(matrix)[source]#

Setup an CG solver with AMG preconditioner for the given matrix.

Parameters:
matrixsps.csc_matrix

Matrix.

Notes

Sets up the AMG solver (pyamg) and a dict of AMG solver options.

amg_options#

dict: options for the AMG solver

linear_solver#

Initialize CG solver with AMG preconditioner.

solver_options#

dict: options for the iterative linear solver