solverFabric.hh

Go to the documentation of this file.
1 
6 #ifndef systemSolverFabric_hh
7 #define systemSolverFabric_hh
8 
9 #include "sparseMatrix.hh"
10 
11 namespace concepts {
12 
13  // ********************************************************** SolverFabric **
14 
21  template<typename F>
22  class SolverFabric : public virtual OutputOperator {
23  public:
28  virtual Operator<F>* operator()() = 0;
29  virtual Operator<F>* operator()(Operator<F>& matrix) = 0;
30 // virtual Operator<F>* operator()(SparseMatrix<F>& matrix) {
31 // Operator<F>* m = dynamic_cast<Operator<F>* >(&matrix);
32 // return operator()(*m);
33 // }
34  };
35 
36  // *************************************************** PrecondSolverFabric **
37 
45  template<typename F, class G = F>
46  class PrecondSolverFabric : public SolverFabric<F> {
47  public:
54  Operator<G>& precond) = 0;
55  };
56 
57 } // concepts
58 
59 #endif // systemSolverFabric_hh
Abstract fabric class for linear solvers with preconditoner.
Definition: solverFabric.hh:46
virtual Operator< F > * operator()(Operator< F > &matrix)=0
virtual Operator< F > * operator()(Operator< F > &matrix, Operator< G > &precond)=0
Creates a linear solver from matrix and precond.
Abstract fabric class for linear solvers.
Definition: jdbsym.hh:16
Abstract class for an operator.
Definition: ARPACK.hh:16
virtual Operator< F > * operator()()=0
Creates a linear solver from matrix.
Basic namespace for Concepts-2.
Definition: pml_formula.h:16
Page URL: http://wiki.math.ethz.ch/bin/view/Concepts/WebHome
21 August 2020
© 2020 Eidgenössische Technische Hochschule Zürich