Skip to content
Snippets Groups Projects
Commit a7cac104 authored by Oliver Sander's avatar Oliver Sander Committed by sander
Browse files

Add default constructor and setProblem method

These are needed to use the CGStep as an acceleration step for
the TNNMG method.

[[Imported from SVN: r13067]]
parent 013d86e1
Branches
Tags
No related merge requests found
......@@ -12,6 +12,9 @@ namespace Dune {
class CGStep : public IterationStep<VectorType>
{
public:
CGStep()
{}
CGStep(const MatrixType& matrix,
VectorType& x,
const VectorType& rhs)
......@@ -27,6 +30,14 @@ namespace Dune {
preconditioner_(&preconditioner)
{}
//! Set linear operator, solution and right hand side
virtual void setProblem(const MatrixType& mat, VectorType& x, const VectorType& rhs)
{
matrix_ = mat;
x_ = x;
r_ = rhs;
}
void check() const;
void preprocess();
void iterate();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment