24#ifndef DUMUX_SUBCONTROLVOLUME_HH
25#define DUMUX_SUBCONTROLVOLUME_HH
36template<
class Imp,
class ScvGeometryTraits>
39 using Implementation = Imp;
40 using GridIndexType =
typename ScvGeometryTraits::GridIndexType;
41 using LocalIndexType =
typename ScvGeometryTraits::LocalIndexType;
42 using Scalar =
typename ScvGeometryTraits::Scalar;
53 return asImp_().center();
59 return asImp_().volume();
65 return asImp_().dofIndex();
71 return asImp_().localDofIndex();
77 return asImp_().dofPosition();
83 return asImp_().elementIndex();
87 const Implementation& asImp_()
const
88 {
return *
static_cast<const Implementation*
>(
this);}
90 Implementation& asImp_()
91 {
return *
static_cast<Implementation*
>(
this);}
Base class for a sub control volume, i.e a part of the control volume we are making the balance for....
Definition: subcontrolvolumebase.hh:38
GridIndexType dofIndex() const
The index of the dof this scv is embedded in (ccfv)
Definition: subcontrolvolumebase.hh:63
ScvGeometryTraits Traits
state the traits public and thus export all types
Definition: subcontrolvolumebase.hh:48
typename ScvGeometryTraits::GlobalPosition GlobalPosition
export the type used for global coordinates
Definition: subcontrolvolumebase.hh:46
Scalar volume() const
The volume of the sub control volume.
Definition: subcontrolvolumebase.hh:57
LocalIndexType localDofIndex() const
The index of the dof this scv is embedded in (box)
Definition: subcontrolvolumebase.hh:69
GlobalPosition dofPosition() const
Definition: subcontrolvolumebase.hh:75
GlobalPosition center() const
The center of the sub control volume.
Definition: subcontrolvolumebase.hh:51
GridIndexType elementIndex() const
The global index of the element this scv is embedded in.
Definition: subcontrolvolumebase.hh:81