version 3.8
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-FileCopyrightInfo: Copyright © DuMux Project contributors, see AUTHORS.md in root folder
5// SPDX-License-Identifier: GPL-3.0-or-later
6//
14#ifndef DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_HH
15#define DUMUX_DISCRETIZATION_FACECENTERED_DIAMOND_HH
16
19
25
32
33namespace Dumux::Properties {
34
36// Create new type tags
37namespace TTag {
38struct FaceCenteredDiamondModel { using InheritsFrom = std::tuple<FiniteVolumeModel>; };
39} // end namespace TTag
40
42template<class TypeTag>
43struct GridGeometry<TypeTag, TTag::FaceCenteredDiamondModel>
44{
45private:
46 static constexpr bool enableCache = getPropValue<TypeTag, Properties::EnableGridGeometryCache>();
48public:
50};
51
53template<class TypeTag>
54struct GridVolumeVariables<TypeTag, TTag::FaceCenteredDiamondModel>
55{
56private:
57 static constexpr bool enableCache = getPropValue<TypeTag, Properties::EnableGridVolumeVariablesCache>();
61public:
63};
64
66template<class TypeTag>
67struct GridFluxVariablesCache<TypeTag, TTag::FaceCenteredDiamondModel>
68{
69private:
70 static constexpr bool enableCache = getPropValue<TypeTag, Properties::EnableGridFluxVariablesCache>();
72
74 using FluxVariablesCache = GetPropTypeOr<TypeTag,
75 Properties::FluxVariablesCache, FluxVariablesCaching::EmptyCache<Scalar>
76 >;
77public:
79};
80
82template<class TypeTag>
83struct GridVariables<TypeTag, TTag::FaceCenteredDiamondModel>
84{
85private:
89public:
91};
92
94template<class TypeTag>
95struct BaseLocalResidual<TypeTag, TTag::FaceCenteredDiamondModel>
97
99template<class TypeTag>
100struct FluxVariablesCache<TypeTag, TTag::FaceCenteredDiamondModel>
101{
102private:
105public:
107};
108
110template<class TypeTag>
111struct ElementBoundaryTypes<TypeTag, TTag::FaceCenteredDiamondModel>
112{
113private:
115 using BoundaryTypes = typename ProblemTraits<Problem>::BoundaryTypes;
116public:
118};
119
120} // namespace Dumux::Properties
121
122namespace Dumux::Detail {
123
124template<class Problem>
125struct ProblemTraits<Problem, DiscretizationMethods::FCDiamond>
126{
127private:
128 using GG = std::decay_t<decltype(std::declval<Problem>().gridGeometry())>;
129 using Element = typename GG::GridView::template Codim<0>::Entity;
130 using SubControlVolumeFace = typename GG::SubControlVolumeFace;
131public:
132 using GridGeometry = GG;
133 // BoundaryTypes is whatever the problem returns from boundaryTypes(element, scv)
134 using BoundaryTypes = std::decay_t<decltype(std::declval<Problem>().boundaryTypes(std::declval<Element>(), std::declval<SubControlVolumeFace>()))>;
135};
136
137template<class GridView>
138struct LocalDofTraits<GridView, DiscretizationMethods::FCDiamond>
139{
140 static constexpr int dim = GridView::dimension;
141 // Dofs are located at the facets
142 static constexpr int numCubeElementDofs = 2*dim;
143};
144
145} // end namespace Dumux::Detail
146
147#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:74
Defines all properties used in Dumux.
Type traits for problem classes.
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.
Flux variables cache class for control-volume finite element schemes.
Global flux variable cache.
Classes related to flux variables caching.
Declares properties required for finite-volume models models.
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.
Distance implementation details.
Definition: cvfelocalresidual.hh:25
CVFE< CVFEMethods::CR_RT > FCDiamond
Definition: method.hh:101
The energy balance equation for a porous solid.
Definition: common/properties.hh:26
Definition: cvfe/gridvolumevariables.hh:29
Definition: localdoftraits.hh:18
std::decay_t< decltype(std::declval< Problem >().boundaryTypes(std::declval< Element >(), std::declval< SubControlVolumeFace >()))> BoundaryTypes
Definition: fcdiamond.hh:134
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
std::tuple< FiniteVolumeModel > InheritsFrom
Definition: fcdiamond.hh:38