Skip to content
Snippets Groups Projects

Feature/dynamicpolymorphism

Merged Christian Engwer requested to merge feature/dynamicpolymorphism into master
1 file
+ 12
4
Compare changes
  • Side-by-side
  • Inline
@@ -47,8 +47,6 @@ namespace Dune
typedef Y range_type;
typedef typename X::field_type field_type;
enum {category = Dune::SolverCategory::sequential};
ScalingLinearOperator (field_type immutable_scaling,
const field_type& mutable_scaling)
: immutable_scaling_(immutable_scaling),
@@ -68,6 +66,12 @@ namespace Dune
y.axpy(alpha,temp);
}
//! Category of the linear operator (see SolverCategory::Category)
virtual SolverCategory::Category category() const
{
return SolverCategory::sequential;
}
protected:
const field_type immutable_scaling_;
const field_type& mutable_scaling_;
@@ -92,8 +96,6 @@ namespace Dune
typedef typename OP1::range_type range_type;
typedef typename domain_type::field_type field_type;
enum {category = Dune::SolverCategory::sequential};
LinearOperatorSum (const OP1& op1, const OP2& op2)
: op1_(op1), op2_(op2)
{
@@ -118,6 +120,12 @@ namespace Dune
y.axpy(alpha,temp);
}
//! Category of the linear operator (see SolverCategory::Category)
virtual SolverCategory::Category category() const
{
return SolverCategory::sequential;
}
protected:
const OP1& op1_;
const OP2& op2_;
Loading