Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dumux-repositories
dumux
Commits
02cdfbce
Commit
02cdfbce
authored
Nov 14, 2017
by
Timo Koch
Browse files
[fvgridgeometry] Add dofmapper for box/cc/mpfa. Allows to use same main file in some cases.
parent
b4ef0e70
Changes
3
Hide whitespace changes
Inline
Side-by-side
dumux/discretization/box/fvgridgeometry.hh
View file @
02cdfbce
...
...
@@ -56,6 +56,7 @@ class BoxFVGridGeometry<TypeTag, true> : public BaseFVGridGeometry<TypeTag>
using
SubControlVolume
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolume
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
using
FVElementGeometry
=
typename
GET_PROP_TYPE
(
TypeTag
,
FVElementGeometry
);
using
VertexMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
VertexMapper
);
using
Element
=
typename
GridView
::
template
Codim
<
0
>
::
Entity
;
using
Scalar
=
typename
GET_PROP_TYPE
(
TypeTag
,
Scalar
);
...
...
@@ -75,6 +76,11 @@ public:
BoxFVGridGeometry
(
const
GridView
gridView
)
:
ParentType
(
gridView
)
{}
//! the vertex mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
VertexMapper
&
dofMapper
()
const
{
return
this
->
vertexMapper
();
}
//! The total number of sub control volumes
std
::
size_t
numScv
()
const
{
return
numScv_
;
}
...
...
@@ -240,6 +246,7 @@ class BoxFVGridGeometry<TypeTag, false> : public BaseFVGridGeometry<TypeTag>
using
SubControlVolume
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolume
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
using
FVElementGeometry
=
typename
GET_PROP_TYPE
(
TypeTag
,
FVElementGeometry
);
using
VertexMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
VertexMapper
);
static
const
int
dim
=
GridView
::
dimension
;
static
const
int
dimWorld
=
GridView
::
dimensionworld
;
...
...
@@ -259,6 +266,11 @@ public:
BoxFVGridGeometry
(
const
GridView
gridView
)
:
ParentType
(
gridView
)
{}
//! the vertex mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
VertexMapper
&
dofMapper
()
const
{
return
this
->
vertexMapper
();
}
//! The total number of sub control volumes
std
::
size_t
numScv
()
const
{
return
numScv_
;
}
...
...
dumux/discretization/cellcentered/mpfa/fvgridgeometry.hh
View file @
02cdfbce
...
...
@@ -55,6 +55,7 @@ class CCMpfaFVGridGeometry<TypeTag, true> : public BaseFVGridGeometry<TypeTag>
{
using
ParentType
=
BaseFVGridGeometry
<
TypeTag
>
;
using
Scalar
=
typename
GET_PROP_TYPE
(
TypeTag
,
Scalar
);
using
ElementMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
ElementMapper
);
using
MpfaHelper
=
typename
GET_PROP_TYPE
(
TypeTag
,
MpfaHelper
);
using
SubControlVolume
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolume
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
...
...
@@ -84,6 +85,11 @@ public:
:
ParentType
(
gridView
),
elementMap_
(
gridView
)
{}
//! the element mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
ElementMapper
&
dofMapper
()
const
{
return
this
->
elementMapper
();
}
/*!
* \brief Returns the total number of sub control volumes.
*/
...
...
@@ -444,6 +450,7 @@ class CCMpfaFVGridGeometry<TypeTag, false> : public BaseFVGridGeometry<TypeTag>
using
ConnectivityMap
=
CCMpfaConnectivityMap
<
TypeTag
>
;
using
GridView
=
typename
GET_PROP_TYPE
(
TypeTag
,
GridView
);
using
ElementMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
ElementMapper
);
static
constexpr
int
dim
=
GridView
::
dimension
;
static
constexpr
int
dimWorld
=
GridView
::
dimensionworld
;
using
Element
=
typename
GridView
::
template
Codim
<
0
>
::
Entity
;
...
...
@@ -464,6 +471,11 @@ public:
:
ParentType
(
gridView
),
elementMap_
(
gridView
)
{}
//! the element mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
ElementMapper
&
dofMapper
()
const
{
return
this
->
elementMapper
();
}
/*!
* \brief Returns the total number of sub control volumes.
*/
...
...
dumux/discretization/cellcentered/tpfa/fvgridgeometry.hh
View file @
02cdfbce
...
...
@@ -58,6 +58,7 @@ class CCTpfaFVGridGeometry<TypeTag, true> : public BaseFVGridGeometry<TypeTag>
using
SubControlVolume
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolume
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
using
FVElementGeometry
=
typename
GET_PROP_TYPE
(
TypeTag
,
FVElementGeometry
);
using
ElementMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
ElementMapper
);
using
Element
=
typename
GridView
::
template
Codim
<
0
>
::
Entity
;
using
ConnectivityMap
=
CCSimpleConnectivityMap
<
TypeTag
>
;
...
...
@@ -77,6 +78,11 @@ public:
,
elementMap_
(
gridView
)
{}
//! the element mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
ElementMapper
&
dofMapper
()
const
{
return
this
->
elementMapper
();
}
//! The total number of sub control volumes
std
::
size_t
numScv
()
const
{
...
...
@@ -313,6 +319,7 @@ class CCTpfaFVGridGeometry<TypeTag, false> : public BaseFVGridGeometry<TypeTag>
using
SubControlVolume
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolume
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
using
FVElementGeometry
=
typename
GET_PROP_TYPE
(
TypeTag
,
FVElementGeometry
);
using
ElementMapper
=
typename
GET_PROP_TYPE
(
TypeTag
,
ElementMapper
);
using
Element
=
typename
GridView
::
template
Codim
<
0
>
::
Entity
;
using
ConnectivityMap
=
CCSimpleConnectivityMap
<
TypeTag
>
;
...
...
@@ -329,6 +336,11 @@ public:
,
elementMap_
(
gridView
)
{}
//! the element mapper is the dofMapper
//! this is convenience to have better chance to have the same main files for box/tpfa/mpfa...
const
ElementMapper
&
dofMapper
()
const
{
return
this
->
elementMapper
();
}
//! The total number of sub control volumes
std
::
size_t
numScv
()
const
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment