3 #ifndef DUNE_ISTL_SCALARPRODUCTS_HH 4 #define DUNE_ISTL_SCALARPRODUCTS_HH 49 typedef typename FieldTraits<field_type>::real_type
real_type;
55 virtual field_type
dot (
const X& x,
const X& y) = 0;
60 virtual real_type
norm (
const X& x) = 0;
75 template<
class X,
class C,
int c>
101 typedef typename FieldTraits<field_type>::real_type
real_type;
110 virtual field_type
dot (
const X& x,
const X& y)
118 virtual real_type
norm (
const X& x)
124 template<
class X,
class C>
137 return new ScalarProduct();
Default implementation for the scalar case.
Definition: scalarproducts.hh:95
FieldTraits< field_type >::real_type real_type
Definition: scalarproducts.hh:49
X::field_type field_type
Definition: scalarproducts.hh:100
SeqScalarProduct< X > ScalarProduct
The type of the scalar product for the sequential case.
Definition: scalarproducts.hh:128
Choose the approriate scalar product for a solver category.
Definition: scalarproducts.hh:76
X domain_type
export types
Definition: scalarproducts.hh:99
X domain_type
export types, they come from the derived class
Definition: scalarproducts.hh:47
Categories for the solvers.
Definition: solvercategory.hh:17
FieldTraits< field_type >::real_type real_type
Definition: scalarproducts.hh:101
Category for sequential solvers.
Definition: solvercategory.hh:21
virtual field_type dot(const X &x, const X &y)=0
Dot product of two vectors. It is assumed that the vectors are consistent on the interior+border part...
virtual ~ScalarProduct()
every abstract base class has a virtual destructor
Definition: scalarproducts.hh:63
virtual field_type dot(const X &x, const X &y)
Dot product of two vectors. In the complex case, the first argument is conjugated. It is assumed that the vectors are consistent on the interior+border partition.
Definition: scalarproducts.hh:110
static ScalarProduct * construct(const C &)
Definition: scalarproducts.hh:135
Definition: basearray.hh:19
C communication_type
The type of the communication object.
Definition: scalarproducts.hh:79
This file implements a vector space as a tensor product of a given vector space. The number of compon...
X::field_type field_type
Definition: scalarproducts.hh:48
Base class for scalar product and norm computation.
Definition: scalarproducts.hh:44
virtual real_type norm(const X &x)=0
Norm of a right-hand side vector. The vector must be consistent on the interior+border partition...
virtual real_type norm(const X &x)
Norm of a right-hand side vector. The vector must be consistent on the interior+border partition...
Definition: scalarproducts.hh:118