24#ifndef DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_SUBCONTROLVOLUMEFACE_HH
25#define DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_SUBCONTROLVOLUMEFACE_HH
29#include <dune/common/fvector.hh>
30#include <dune/geometry/type.hh>
31#include <dune/geometry/multilineargeometry.hh>
50template<
class Gr
idView>
53 using Grid =
typename GridView::Grid;
54 static constexpr int dim = Grid::dimension;
55 static constexpr int dimWorld = Grid::dimensionworld;
66 {
return Dune::GeometryTypes::simplex(
dim-1); }
73template<
class Gr
idView,
class T = FaceCenteredDiamondScvfGeometryTraits<Gr
idView>>
76 using Scalar =
typename T::Scalar;
77 using GridIndexType =
typename T::GridIndexType;
78 using LocalIndexType =
typename T::LocalIndexType;
79 using Geometry =
typename T::Geometry;
80 using BoundaryFlag =
typename T::BoundaryFlag;
94 const std::array<LocalIndexType, 2>& scvIndices,
95 const LocalIndexType localScvfIdx)
99 , localScvfIdx_(localScvfIdx)
100 , scvIndices_(scvIndices)
109 const std::array<LocalIndexType, 2>& scvIndices,
110 const LocalIndexType localScvfIdx,
111 const BoundaryFlag& bFlag)
113 , unitOuterNormal_(
normal)
115 , localScvfIdx_(localScvfIdx)
116 , scvIndices_(scvIndices)
118 , boundaryFlag_(bFlag)
131 {
return unitOuterNormal_; }
135 {
return scvIndices_[0]; }
139 {
return scvIndices_[1]; }
142 {
return static_cast<std::size_t
>(!
boundary()); }
145 {
return localScvfIdx_; }
148 {
return boundary_; }
156 return boundaryFlag_.get();
163 LocalIndexType localScvfIdx_;
164 std::array<LocalIndexType, 2> scvIndices_;
A helper function for class member function introspection.
Boundary flag to store e.g. in sub control volume faces.
Defines the index types used for grid and local indices.
Base class for a sub control volume face.
Vector normal(const Vector &v)
Create a vector normal to the given one (v is expected to be non-zero)
Definition: normal.hh:38
Adaption of the non-isothermal two-phase two-component flow model to problems with CO2.
Definition: adapt.hh:29
std::size_t value_type
Definition: boundaryflag.hh:51
Boundary flag to store e.g. in sub control volume faces.
Definition: boundaryflag.hh:67
typename GridView::IndexSet::IndexType GridIndex
Definition: indextraits.hh:39
std::uint_least8_t SmallLocalIndex
Definition: indextraits.hh:41
Traits for an efficient corner storage for fc diamond method.
Definition: discretization/facecentered/diamond/geometryhelper.hh:41
Default traits class to be used for the sub-control volumes for the cell-centered finite volume schem...
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:52
typename IndexTraits< GridView >::GridIndex GridIndexType
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:57
static constexpr int dimWorld
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:55
typename CornerStorage::value_type GlobalPosition
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:62
typename IndexTraits< GridView >::SmallLocalIndex LocalIndexType
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:58
typename Grid::ctype Scalar
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:59
typename FCDiamondMLGeometryTraits< Scalar >::template CornerStorage< dim-1, dimWorld >::Type CornerStorage
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:61
static constexpr int dim
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:54
static constexpr Dune::GeometryType interiorGeometryType(Dune::GeometryType)
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:65
typename GridView::Grid Grid
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:53
Dune::MultiLinearGeometry< Scalar, dim-1, dimWorld, FCDiamondMLGeometryTraits< Scalar > > Geometry
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:60
The SCVF implementation for diamond.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:75
bool boundary() const
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:147
FaceCenteredDiamondSubControlVolumeFace()=default
std::size_t numOutsideScvs() const
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:141
GridIndexType insideScvIdx() const
Index of the inside sub control volume.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:134
const GlobalPosition unitOuterNormal() const
The unit outer normal.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:130
const GlobalPosition & ipGlobal() const
The integration point of the sub control volume face.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:126
Scalar area() const
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:150
FaceCenteredDiamondSubControlVolumeFace(const GlobalPosition ¢er, const Scalar area, const GlobalPosition &normal, const std::array< LocalIndexType, 2 > &scvIndices, const LocalIndexType localScvfIdx, const BoundaryFlag &bFlag)
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:106
T Traits
state the traits public and thus export all types
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:84
GridIndexType index() const
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:144
BoundaryFlag::value_type boundaryFlag() const
Return the boundary flag.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:154
GridIndexType outsideScvIdx() const
index of the outside sub control volume
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:138
FaceCenteredDiamondSubControlVolumeFace(const GlobalPosition ¢er, const Scalar area, const GlobalPosition &normal, const std::array< LocalIndexType, 2 > &scvIndices, const LocalIndexType localScvfIdx)
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:91
const GlobalPosition & center() const
The center of the sub control volume face.
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:122
typename T::GlobalPosition GlobalPosition
Definition: discretization/facecentered/diamond/subcontrolvolumeface.hh:86