version 3.10.0
Loading...
Searching...
No Matches
fcdiamond.hh
Go to the documentation of this file.
1// -*- mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2// vi: set et ts=4 sw=4 sts=4:
3//
4// SPDX-FileCopyrightText: Copyright © DuMux Project contributors, see AUTHORS.md in root folder
5// SPDX-License-Identifier: GPL-3.0-or-later
6//
13
14#ifndef DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_HH
15#define DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_HH
16
17#include <concepts>
18#include <type_traits>
19
22
29
36
37namespace Dumux::Properties {
38
40// Create new type tags
41namespace TTag {
42struct FaceCenteredDiamondModel { using InheritsFrom = std::tuple<FiniteVolumeModel>; };
43} // end namespace TTag
44
46template<class TypeTag>
47struct GridGeometry<TypeTag, TTag::FaceCenteredDiamondModel>
48{
49private:
50 static constexpr bool enableCache = getPropValue<TypeTag, Properties::EnableGridGeometryCache>();
52public:
54};
55
57template<class TypeTag>
58struct GridVolumeVariables<TypeTag, TTag::FaceCenteredDiamondModel>
59{
60private:
65public:
67};
68
70template<class TypeTag>
71struct GridFluxVariablesCache<TypeTag, TTag::FaceCenteredDiamondModel>
72{
73private:
74 static constexpr bool enableCache = getPropValue<TypeTag, Properties::EnableGridFluxVariablesCache>();
76
78 using FluxVariablesCache = GetPropTypeOr<TypeTag,
79 Properties::FluxVariablesCache, FluxVariablesCaching::EmptyCache<Scalar>
80 >;
81public:
83};
84
86template<class TypeTag>
87struct GridVariables<TypeTag, TTag::FaceCenteredDiamondModel>
88{
89private:
93public:
95};
96
98template<class TypeTag>
99struct FluxVariablesCache<TypeTag, TTag::FaceCenteredDiamondModel>
100{
101private:
104public:
106};
107
109template<class TypeTag>
110struct ElementBoundaryTypes<TypeTag, TTag::FaceCenteredDiamondModel>
111{
112private:
114 using BoundaryTypes = typename ProblemTraits<Problem>::BoundaryTypes;
115public:
117};
118
119} // namespace Dumux::Properties
120
121namespace Dumux::Detail {
122
123template<class Problem>
125{
126private:
127 using GG = std::decay_t<decltype(std::declval<Problem>().gridGeometry())>;
128 using Element = typename GG::GridView::template Codim<0>::Entity;
129 using SubControlVolumeFace = typename GG::SubControlVolumeFace;
130public:
131 using GridGeometry = GG;
132 // BoundaryTypes is whatever the problem returns from boundaryTypes(element, scv)
133 using BoundaryTypes = std::decay_t<decltype(std::declval<Problem>().boundaryTypes(std::declval<Element>(), std::declval<SubControlVolumeFace>()))>;
134};
135
136template<class GridView>
138{
139 static constexpr int dim = GridView::dimension;
140 // Dofs are located at the facets
141 static constexpr int numCubeElementDofs = 2*dim;
142};
143
144template<class TypeTag>
145concept FaceCenteredDiamondModel = std::is_same_v<
148>;
149
150template<FaceCenteredDiamondModel TypeTag>
152{
154};
155
156} // end namespace Dumux::Detail
157
158#endif
This class stores an array of BoundaryTypes objects.
Definition cvfe/elementboundarytypes.hh:28
Flux variables cache class for control-volume finite element schemes. For control-volume finite eleme...
Definition discretization/cvfe/fluxvariablescache.hh:27
Flux variable caches on a gridview.
Definition discretization/cvfe/gridfluxvariablescache.hh:46
Base class for the grid volume variables.
Definition cvfe/gridvolumevariables.hh:42
The element-wise residual for control-volume finite element schemes.
Definition cvfelocalresidual.hh:60
The grid variable class for finite volume schemes storing variables on scv and scvf (volume and flux ...
Definition discretization/fvgridvariables.hh:30
Grid geometry for the diamond discretization.
Definition discretization/facecentered/diamond/fvgridgeometry.hh:76
Defines all properties used in Dumux.
Type traits for problem classes.
Definition fcdiamond.hh:145
Boundary types gathered on an element.
The local element solution class for control-volume finite element methods.
The grid volume variables class for control-volume finite element methods.
Calculates the element-wise residual for control-volume finite element schemes.
The default local operator than can be specialized for each discretization scheme.
Flux variables cache class for control-volume finite element schemes.
Global flux variable cache.
Grid geometry for the diamond discretization.
Classes related to flux variables caching.
Declares properties required for finite-volume models models.
constexpr auto getPropValue()
get the value data member of a property
Definition propertysystem.hh:310
typename GetProp< TypeTag, Property >::type GetPropType
get the type alias defined in the property
Definition propertysystem.hh:296
typename GetPropOr< TypeTag, Property, T >::type GetPropTypeOr
get the type alias defined in the property or the type T if the property is undefined
Definition propertysystem.hh:303
Element-specific traits of grid geometries / discretization schemes.
The available discretization methods in Dumux.
Definition discretization/facecentered/diamond/geometryhelper.hh:39
Distance implementation details.
Definition cvfelocalresidual.hh:25
Definition method.hh:20
CVFE< CVFEMethods::CR_RT > FCDiamond
Definition method.hh:101
Type tag for numeric models.
Definition grid.hh:24
The energy balance equation for a porous solid.
Definition common/properties.hh:26
Definition cvfe/gridvolumevariables.hh:29
CVFELocalResidual< TypeTag > type
Definition box.hh:147
Definition defaultlocaloperator.hh:19
static constexpr int numCubeElementDofs
Definition fcdiamond.hh:141
Definition localdoftraits.hh:18
std::decay_t< decltype(std::declval< Problem >().boundaryTypes(std::declval< Element >(), std::declval< SubControlVolumeFace >()))> BoundaryTypes
Definition fcdiamond.hh:133
Definition common/typetraits/problem.hh:23
An empty flux variables cache.
Definition fluxvariablescaching.hh:35
typename Detail::template ProblemTraits< Problem, typename GridGeometry::DiscretizationMethod >::BoundaryTypes BoundaryTypes
Definition common/typetraits/problem.hh:34
CVFEElementBoundaryTypes< BoundaryTypes > type
Definition fcdiamond.hh:116
CVFEFluxVariablesCache< S, GG > type
Definition fcdiamond.hh:105
CVFEGridFluxVariablesCache< Problem, FluxVariablesCache, enableCache > type
Definition fcdiamond.hh:82
FaceCenteredDiamondFVGridGeometry< GridView, enableCache > type
Definition fcdiamond.hh:53
FVGridVariables< GG, GVV, GFVC > type
Definition fcdiamond.hh:94
CVFEGridVolumeVariables< Traits, enableCache > type
Definition fcdiamond.hh:66
std::tuple< FiniteVolumeModel > InheritsFrom
Definition fcdiamond.hh:42