Class LinearSolver

Inheritance Relationships

Derived Types

Class Documentation

class LinearSolver

Subclassed by opensn::LinearEigenSolver, opensn::LinearSystemSolver

Public Functions

inline explicit LinearSolver(std::shared_ptr<LinearSolverContext> context_ptr)
virtual ~LinearSolver() = default
inline virtual void Setup()

Set up the linaer solver.

virtual void Solve() = 0

Solve the system.

inline virtual void ReleaseWorkspace()

Frees the storage that Setup() and Solve() allocate.

The settings are kept. The next Setup() or Solve() allocates the storage again, so a later solve gives the same result. The default implementation frees nothing.

inline std::shared_ptr<LinearSolverContext> GetContext()

Protected Attributes

std::shared_ptr<LinearSolverContext> context_ptr_