24#ifndef DUMUX_DISCRETIZATION_FACECENTERED_STAGGERED_FV_GRID_GEOMETRY
25#define DUMUX_DISCRETIZATION_FACECENTERED_STAGGERED_FV_GRID_GEOMETRY
29#include <dune/common/rangeutilities.hh>
30#include <dune/grid/common/scsgmapper.hh>
58template<
class Gr
idView>
61 using ElementMapper = Dune::SingleCodimSingleGeomTypeMapper<GridView, 0>;
68 template<
class Gr
idGeometry>
71 template<
class Gr
idGeometry,
bool enableCache>
76 static constexpr auto dim = GridView::Grid::dimension;
94template<
class GridView,
95 bool cachingEnabled =
false,
105template<
class GV,
class Traits>
114 using Element =
typename GV::template Codim<0>::Entity;
116 using IntersectionMapper =
typename Traits::IntersectionMapper;
117 using ConnectivityMap =
typename Traits::template ConnectivityMap<ThisType>;
119 using Scalar =
typename GV::ctype;
121 static constexpr auto dim = Traits::StaticInfo::dim;
122 static constexpr auto numScvsPerElement = Traits::StaticInfo::numScvsPerElement;
123 static constexpr auto numLateralScvfsPerScv = Traits::StaticInfo::numLateralScvfsPerScv;
124 static constexpr auto numLateralScvfsPerElement = Traits::StaticInfo::numLateralScvfsPerElement;
125 static constexpr auto minNumScvfsPerElement = Traits::StaticInfo::minNumScvfsPerElement;
126 static constexpr auto maxNumScvfsPerElement = Traits::StaticInfo::maxNumScvfsPerElement;
128 using ScvfCornerStorage =
typename Traits::SubControlVolumeFace::Traits::CornerStorage;
129 using ScvCornerStorage =
typename Traits::SubControlVolume::Traits::CornerStorage;
136 static constexpr bool cachingEnabled =
true;
158 , intersectionMapper_(gridView)
162 DUNE_THROW(Dune::InvalidStateException,
"The staggered discretization method needs at least an overlap of 1 for parallel computations. "
163 <<
" Set the parameter \"Grid.Overlap\" in the input file.");
170 {
return scvs_.size(); }
174 {
return scvfs_.size(); }
178 {
return numBoundaryScv_; }
182 {
return numBoundaryScvf_; }
186 {
return intersectionMapper_.numIntersections(); }
190 {
return this->gridView().size(1); }
195 ParentType::update(gridView);
202 ParentType::update(std::move(gridView));
208 {
return scvs_[scvIdx]; }
214 auto begin = scvs_.cbegin() + numScvsPerElement*fvGeometry.elementIndex();
215 const auto end = begin + numScvsPerElement;
216 return Dune::IteratorRange<std::decay_t<
decltype(begin)>>(begin, end);
221 {
return scvfs_[scvfIdx]; }
225 {
return scvfIndicesOfElement_[eIdx]; }
232 {
return connectivityMap_; }
236 {
return hasBoundaryScvf_[eIdx]; }
240 {
return intersectionMapper_; }
244 {
return periodicFaceMap_.count(dofIdx); }
248 {
return periodicFaceMap_.at(dofIdx); }
252 {
return periodicFaceMap_; }
261 scvfIndicesOfElement_.clear();
262 intersectionMapper_.update(this->gridView());
265 const auto numElements = this->gridView().size(0);
266 scvfIndicesOfElement_.resize(numElements);
267 hasBoundaryScvf_.resize(numElements,
false);
269 outSideBoundaryVolVarIdx_ = 0;
271 numBoundaryScvf_ = 0;
273 GeometryHelper geometryHelper(this->gridView());
276 GridIndexType numScvfs = 0;
277 for (
const auto& element : elements(this->gridView()))
279 assert(numScvsPerElement == element.subEntities(1));
281 for (
const auto& intersection : intersections(this->gridView(), element))
287 numScvfs += numLateralScvfsPerScv;
290 if (onDomainBoundary_(intersection))
293 numBoundaryScv_ += numLateralScvfsPerScv;
302 const auto numScvs = numElements*numScvsPerElement;
303 scvs_.resize(numScvs);
304 scvfs_.reserve(numScvfs);
307 std::size_t globalScvfIdx = 0;
308 for (
const auto& element : elements(this->gridView()))
310 const auto eIdx = this->elementMapper().index(element);
311 auto& globalScvfIndices = scvfIndicesOfElement_[eIdx];
312 globalScvfIndices.resize(minNumScvfsPerElement);
313 globalScvfIndices.reserve(maxNumScvfsPerElement);
315 auto getGlobalScvIdx = [&](
const auto elementIdx,
const auto localScvIdx)
316 {
return numScvsPerElement*elementIdx + localScvIdx; };
318 LocalIntersectionMapper localIsMapper;
319 localIsMapper.update(this->gridView(),
element);
321 for (
const auto& intersection : intersections(this->gridView(), element))
323 const auto& intersectionUnitOuterNormal = intersection.centerUnitOuterNormal();
324 const auto localScvIdx = localIsMapper.realToRefIdx(intersection.indexInInside());
325 auto localScvfIdx = localScvIdx*(1 + numLateralScvfsPerScv);
327 const auto globalScvIdx = getGlobalScvIdx(eIdx, localScvIdx);
328 const auto dofIndex = intersectionMapper().globalIntersectionIndex(element, intersection.indexInInside());
329 const auto localOppositeScvIdx = geometryHelper.localOppositeIdx(localScvIdx);
330 const auto& intersectionGeometry = intersection.geometry();
331 const auto& elementGeometry =
element.geometry();
333 assert(localIsMapper.refToRealIdx(localScvIdx) == intersection.indexInInside());
336 if (onPeriodicBoundary_(intersection))
340 const auto& otherElement = intersection.outside();
342 SmallLocalIndexType otherIntersectionLocalIdx = 0;
343 bool periodicFaceFound =
false;
345 for (
const auto& otherIntersection : intersections(this->gridView(), otherElement))
347 if (periodicFaceFound)
350 if (Dune::FloatCmp::eq(intersectionUnitOuterNormal*otherIntersection.centerUnitOuterNormal(), -1.0, 1e-7))
352 const auto periodicDofIdx = intersectionMapper().globalIntersectionIndex(otherElement, otherIntersectionLocalIdx);
353 periodicFaceMap_[dofIndex] = periodicDofIdx;
354 periodicFaceFound =
true;
357 ++otherIntersectionLocalIdx;
362 scvs_[globalScvIdx] = SubControlVolume(
364 intersectionGeometry,
369 this->elementMapper().index(element),
370 onDomainBoundary_(intersection)
374 scvfs_.emplace_back(elementGeometry,
375 intersectionGeometry,
376 std::array{globalScvIdx, getGlobalScvIdx(eIdx, localOppositeScvIdx)},
379 intersectionUnitOuterNormal,
380 SubControlVolumeFace::FaceType::frontal,
381 SubControlVolumeFace::BoundaryType::interior
384 globalScvfIndices[localScvfIdx] = globalScvfIdx++;
388 for (
const auto lateralFacetIndex : Dune::transformedRangeView(geometryHelper.localLaterFaceIndices(localScvIdx),
389 [&](
auto&& idx) { return localIsMapper.refToRealIdx(idx) ;})
392 const auto& lateralIntersection = geometryHelper.intersection(lateralFacetIndex, element);
395 const auto globalScvIndicesForLateralFace = [&]
397 const auto globalOutsideScvIdx = [&]
399 if (lateralIntersection.neighbor())
401 const auto parallelElemIdx = this->elementMapper().index(lateralIntersection.outside());
402 return getGlobalScvIdx(parallelElemIdx, localScvIdx);
404 else if (onDomainBoundary_(lateralIntersection))
405 return numScvs + outSideBoundaryVolVarIdx_++;
410 return std::array{globalScvIdx, globalOutsideScvIdx};
413 const auto boundaryType = [&]
415 if (onProcessorBoundary_(lateralIntersection))
416 return SubControlVolumeFace::BoundaryType::processorBoundary;
417 else if (onDomainBoundary_(lateralIntersection))
418 return SubControlVolumeFace::BoundaryType::physicalBoundary;
420 return SubControlVolumeFace::BoundaryType::interior;
425 intersectionGeometry,
426 geometryHelper.facet(lateralFacetIndex, element).geometry(),
427 globalScvIndicesForLateralFace,
430 lateralIntersection.centerUnitOuterNormal(),
431 SubControlVolumeFace::FaceType::lateral,
435 globalScvfIndices[localScvfIdx] = globalScvfIdx++;
438 if (onDomainBoundary_(lateralIntersection))
441 hasBoundaryScvf_[eIdx] =
true;
448 int localScvfIdx = minNumScvfsPerElement;
449 for (
const auto& intersection : intersections(this->gridView(),
element))
452 if (onDomainBoundary_(intersection))
454 const auto localScvIdx = localIsMapper.realToRefIdx(intersection.indexInInside());
455 const auto globalScvIdx = getGlobalScvIdx(eIdx, localScvIdx);
461 intersection.geometry(),
462 std::array{globalScvIdx, globalScvIdx},
465 intersection.centerUnitOuterNormal(),
466 SubControlVolumeFace::FaceType::frontal,
467 SubControlVolumeFace::BoundaryType::physicalBoundary
470 globalScvfIndices.push_back(globalScvfIdx);
473 hasBoundaryScvf_[eIdx] =
true;
478 connectivityMap_.update(*
this);
481 bool onDomainBoundary_(
const typename GridView::Intersection& intersection)
const
483 return !intersection.neighbor() && intersection.boundary();
486 bool onProcessorBoundary_(
const typename GridView::Intersection& intersection)
const
488 return !intersection.neighbor() && !intersection.boundary();
491 bool onPeriodicBoundary_(
const typename GridView::Intersection& intersection)
const
493 return intersection.boundary() && intersection.neighbor();
497 ConnectivityMap connectivityMap_;
498 IntersectionMapper intersectionMapper_;
500 std::vector<SubControlVolume> scvs_;
501 std::vector<SubControlVolumeFace> scvfs_;
502 GridIndexType numBoundaryScv_;
503 GridIndexType numBoundaryScvf_;
504 GridIndexType outSideBoundaryVolVarIdx_;
505 std::vector<bool> hasBoundaryScvf_;
507 std::vector<std::vector<GridIndexType>> scvfIndicesOfElement_;
510 std::unordered_map<GridIndexType, GridIndexType> periodicFaceMap_;
519template<
class GV,
class Traits>
528 using Element =
typename GV::template Codim<0>::Entity;
530 using IntersectionMapper =
typename Traits::IntersectionMapper;
531 using ConnectivityMap =
typename Traits::template ConnectivityMap<ThisType>;
533 static constexpr auto dim = Traits::StaticInfo::dim;
534 static constexpr auto numScvsPerElement = Traits::StaticInfo::numScvsPerElement;
535 static constexpr auto numLateralScvfsPerScv = Traits::StaticInfo::numLateralScvfsPerScv;
536 static constexpr auto numLateralScvfsPerElement = Traits::StaticInfo::numLateralScvfsPerElement;
537 static constexpr auto minNumScvfsPerElement = Traits::StaticInfo::minNumScvfsPerElement;
538 static constexpr auto maxNumScvfsPerElement = Traits::StaticInfo::maxNumScvfsPerElement;
545 static constexpr bool cachingEnabled =
false;
567 , intersectionMapper_(gridView)
571 DUNE_THROW(Dune::InvalidStateException,
"The staggered discretization method needs at least an overlap of 1 for parallel computations. "
572 <<
" Set the parameter \"Grid.Overlap\" in the input file.");
587 {
return numBoundaryScv_; }
591 {
return numBoundaryScvf_; }
595 {
return intersectionMapper_.numIntersections(); }
599 {
return this->gridView().size(1); }
606 {
return connectivityMap_; }
610 {
return hasBoundaryScvf_[eIdx]; }
614 {
return intersectionMapper_; }
618 {
return scvfIndicesOfElement_[eIdx]; }
622 {
return outsideVolVarIndices_.at(scvfIdx); }
627 ParentType::update(gridView);
634 ParentType::update(std::move(gridView));
640 {
return periodicFaceMap_.count(dofIdx); }
644 {
return periodicFaceMap_.at(dofIdx); }
648 {
return periodicFaceMap_; }
654 intersectionMapper_.update(this->gridView());
659 numBoundaryScvf_ = 0;
660 hasBoundaryScvf_.clear();
661 scvfIndicesOfElement_.clear();
662 outsideVolVarIndices_.clear();
665 const auto numElements = this->gridView().size(0);
666 scvfIndicesOfElement_.resize(numElements);
667 hasBoundaryScvf_.resize(numElements,
false);
668 numScvs_ = numElements*numScvsPerElement;
670 GeometryHelper geometryHelper(this->gridView());
673 GridIndexType scvfIdx = 0;
675 GridIndexType neighborVolVarIdx = numScvs_;
677 for (
const auto& element : elements(this->gridView()))
679 const auto eIdx = this->elementMapper().index(element);
680 assert(numScvsPerElement == element.subEntities(1));
683 auto& globalScvfIndices = scvfIndicesOfElement_[eIdx];
684 globalScvfIndices.reserve(maxNumScvfsPerElement);
685 globalScvfIndices.resize(minNumScvfsPerElement);
688 std::size_t numFrontalBoundaryScvfs = 0;
691 LocalIntersectionIndexMapper localIsMapper;
692 localIsMapper.update(this->gridView(), element);
694 for (
const auto& intersection : intersections(this->gridView(), element))
696 const auto localScvIdx = localIsMapper.realToRefIdx(intersection.indexInInside());
697 auto localScvfIdx = localScvIdx*(1 + numLateralScvfsPerScv);
699 assert(localIsMapper.refToRealIdx(localScvIdx) == intersection.indexInInside());
701 globalScvfIndices[localScvfIdx] = scvfIdx++;
704 if constexpr(dim > 1)
707 for (
const auto lateralFacetIndex : Dune::transformedRangeView(geometryHelper.localLaterFaceIndices(localScvIdx),
708 [&](
auto idx) { return localIsMapper.refToRealIdx(idx) ;})
711 if (onDomainBoundary_(geometryHelper.intersection(lateralFacetIndex, element)))
713 outsideVolVarIndices_[scvfIdx] = neighborVolVarIdx++;
715 hasBoundaryScvf_[eIdx] =
true;
718 globalScvfIndices[localScvfIdx] = scvfIdx++;
724 if (onDomainBoundary_(intersection))
727 numBoundaryScv_ += numLateralScvfsPerScv;
728 ++numFrontalBoundaryScvfs;
730 hasBoundaryScvf_[eIdx] =
true;
734 if (onPeriodicBoundary_(intersection))
738 const auto& otherElement = intersection.outside();
740 SmallLocalIndexType otherIntersectionLocalIdx = 0;
741 bool periodicFaceFound =
false;
743 for (
const auto& otherIntersection : intersections(this->gridView(), otherElement))
745 if (periodicFaceFound)
748 if (Dune::FloatCmp::eq(intersection.centerUnitOuterNormal()*otherIntersection.centerUnitOuterNormal(), -1.0, 1e-7))
750 const auto periodicDofIdx = intersectionMapper().globalIntersectionIndex(otherElement, otherIntersectionLocalIdx);
751 const auto dofIndex = intersectionMapper().globalIntersectionIndex(element, localScvIdx);
752 periodicFaceMap_[dofIndex] = periodicDofIdx;
753 periodicFaceFound =
true;
756 ++otherIntersectionLocalIdx;
762 for (std::size_t i = 0; i < numFrontalBoundaryScvfs; ++i)
763 globalScvfIndices.push_back(scvfIdx++);
769 connectivityMap_.update(*
this);
772 bool onDomainBoundary_(
const typename GridView::Intersection& intersection)
const
774 return !intersection.neighbor() && intersection.boundary();
777 bool onProcessorBoundary_(
const typename GridView::Intersection& intersection)
const
779 return !intersection.neighbor() && !intersection.boundary();
782 bool onPeriodicBoundary_(
const typename GridView::Intersection& intersection)
const
784 return intersection.boundary() && intersection.neighbor();
788 ConnectivityMap connectivityMap_;
789 IntersectionMapper intersectionMapper_;
792 std::size_t numScvs_;
793 std::size_t numScvf_;
794 std::size_t numBoundaryScv_;
795 std::size_t numBoundaryScvf_;
796 std::vector<bool> hasBoundaryScvf_;
798 std::vector<std::vector<GridIndexType>> scvfIndicesOfElement_;
801 std::unordered_map<GridIndexType, GridIndexType> periodicFaceMap_;
802 std::unordered_map<GridIndexType, GridIndexType> outsideVolVarIndices_;
Defines the default element and vertex mapper types.
Defines the index types used for grid and local indices.
defines intersection mappers.
Define some often used mathematical functions.
Helper classes to compute the integration elements.
Base class for grid geometries.
Check the overlap size for different discretization methods.
Returns the normal axis index of a unit vector (0 = x, 1 = y, 2 = z)
The available discretization methods in Dumux.
typename Extrusion< T >::type Extrusion_t
Convenience alias for obtaining the extrusion type.
Definition: extrusion.hh:177
static std::size_t normalAxis(const Vector &v)
Definition: normalaxis.hh:39
Definition: defaultmappertraits.hh:35
EM ElementMapper
Definition: defaultmappertraits.hh:36
Struture to define the index types used for grid and local indices.
Definition: indextraits.hh:38
defines a standard intersection mapper for mapping of global DOFs assigned to faces....
Definition: intersectionmapper.hh:41
Base class for all finite volume grid geometries.
Definition: basegridgeometry.hh:51
GV GridView
export the grid view type
Definition: basegridgeometry.hh:66
Check if the overlap size is valid for a given discretization method.
Definition: checkoverlapsize.hh:40
Stores the dof indices corresponding to the neighboring scvs that contribute to the derivative calcul...
Definition: facecentered/staggered/connectivitymap.hh:42
Definition: discretization/facecentered/staggered/fvelementgeometry.hh:42
The default traits for the face-center staggered finite volume grid geometry Defines the scv and scvf...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:60
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:75
static constexpr auto numLateralScvfsPerElement
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:80
static constexpr auto maxNumScvfsPerElement
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:83
static constexpr auto numScvsPerElement
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:78
static constexpr auto numFacesPerElement
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:77
static constexpr auto dim
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:76
static constexpr auto numLateralScvfsPerScv
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:79
static constexpr auto minNumScvfsPerElement
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:81
Base class for the finite volume geometry vector for face-centered staggered models This builds up th...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:97
Base class for the finite volume geometry vector for staggered models This builds up the sub control ...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:108
const ConnectivityMap & connectivityMap() const
Returns the connectivity map of which dofs have derivatives with respect to a given dof.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:231
std::size_t numScvf() const
The total number of sub control volume faces.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:173
const IntersectionMapper & intersectionMapper() const
Return a reference to the intersection mapper.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:239
bool hasBoundaryScvf(GridIndexType eIdx) const
Returns whether one of the geometry's scvfs lies on a boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:235
void update(const GridView &gridView)
update all fvElementGeometries (call this after grid adaption)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:193
typename Traits::SubControlVolumeFace SubControlVolumeFace
export the type of sub control volume
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:143
typename Traits::LocalIntersectionMapper LocalIntersectionMapper
export the local intersection mapper
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:149
typename Traits::GeometryHelper GeometryHelper
export the geometry helper type
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:147
const std::vector< GridIndexType > & scvfIndicesOfElement(GridIndexType eIdx) const
Get the global sub control volume face indices of an element.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:224
typename Traits::StaticInfo StaticInformation
export static information
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:151
std::size_t numDofs() const
the total number of dofs
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:189
const std::unordered_map< GridIndexType, GridIndexType > & periodicVertexMap() const
Returns the map between dofs across periodic boundaries // TODO rename to periodic dof map in fvassem...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:251
std::size_t numBoundaryScv() const
The total number of boundary sub control volumes.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:177
FaceCenteredStaggeredFVGridGeometry(const GridView &gridView, const std::string ¶mGroup="")
Constructor.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:156
GridIndexType periodicallyMappedDof(GridIndexType dofIdx) const
The index of the d.o.f. on the other side of the periodic boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:247
const SubControlVolume & scv(GridIndexType scvIdx) const
Get a sub control volume with a global scv index.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:207
typename Traits::SubControlVolume SubControlVolume
export the type of sub control volume
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:141
typename Traits::template LocalView< ThisType, true > LocalView
export the type of the fv element geometry (the local view type)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:139
void update(GridView &&gridView)
update all fvElementGeometries (call this after grid adaption)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:200
Extrusion_t< Traits > Extrusion
export the type of extrusion
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:153
std::size_t numBoundaryScvf() const
The total number of boundary sub control volume faces.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:181
std::size_t numIntersections() const
The total number of intersections.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:185
const SubControlVolumeFace & scvf(GridIndexType scvfIdx) const
Get a sub control volume face with a global scvf index.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:220
bool dofOnPeriodicBoundary(GridIndexType dofIdx) const
If a d.o.f. is on a periodic boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:243
std::size_t numScv() const
The total number of sub control volumes.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:169
auto scvs(const LocalView &fvGeometry) const
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:212
Base class for the finite volume geometry vector for face-centered staggered models This builds up th...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:522
typename Traits::SubControlVolumeFace SubControlVolumeFace
export the type of sub control volume
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:552
typename Traits::GeometryHelper GeometryHelper
export the geometry helper type
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:556
typename Traits::SubControlVolume SubControlVolume
export the type of sub control volume
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:550
std::size_t numDofs() const
the total number of dofs
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:598
GridIndexType periodicallyMappedDof(GridIndexType dofIdx) const
The index of the d.o.f. on the other side of the periodic boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:643
const ConnectivityMap & connectivityMap() const
Returns the connectivity map of which dofs have derivatives with respect to a given dof.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:605
std::size_t numBoundaryScv() const
The total number of boundary sub control volumes.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:586
const IntersectionMapper & intersectionMapper() const
Return a reference to the intersection mapper.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:613
void update(GridView &&gridView)
update all fvElementGeometries (call this after grid adaption)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:632
FaceCenteredStaggeredFVGridGeometry(const GridView &gridView, const std::string ¶mGroup="")
Constructor.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:565
bool dofOnPeriodicBoundary(GridIndexType dofIdx) const
If a d.o.f. is on a periodic boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:639
typename Traits::StaticInfo StaticInformation
export static information
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:560
const std::vector< GridIndexType > & scvfIndicesOfElement(GridIndexType eIdx) const
Get the global sub control volume face indices of an element.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:617
bool hasBoundaryScvf(GridIndexType eIdx) const
Returns whether one of the geometry's scvfs lies on a boundary.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:609
const std::unordered_map< GridIndexType, GridIndexType > & periodicVertexMap() const
Returns the map between dofs across periodic boundaries // TODO rename to periodic dof map in fvassem...
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:647
std::size_t numScvf() const
The total number of sub control volume faces.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:582
std::size_t numBoundaryScvf() const
The total number of boundary sub control volume faces.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:590
std::size_t numScv() const
The total number of sub control volumes.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:578
typename Traits::LocalIntersectionMapper LocalIntersectionMapper
export the local intersection mapper
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:558
GridIndexType outsideVolVarIndex(GridIndexType scvfIdx) const
Get the global sub control volume face indices of an element.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:621
void update(const GridView &gridView)
update all fvElementGeometries (call this after grid adaption)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:625
std::size_t numIntersections() const
The total number of intersections.
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:594
Extrusion_t< Traits > Extrusion
export the type of extrusion
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:562
typename Traits::template LocalView< ThisType, false > LocalView
export the type of the fv element geometry (the local view type)
Definition: discretization/facecentered/staggered/fvgridgeometry.hh:548
Definition: discretization/facecentered/staggered/geometryhelper.hh:37
Definition: localintersectionindexmapper.hh:41
Face centered staggered sub control volume.
Definition: discretization/facecentered/staggered/subcontrolvolume.hh:64
Face centered staggered sub control volume face.
Definition: discretization/facecentered/staggered/subcontrolvolumeface.hh:67
Definition: method.hh:112
Geometry helper for face-centered staggered scheme.