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
86cd2150
Commit
86cd2150
authored
Dec 17, 2017
by
Kilian Weishaupt
Committed by
Timo Koch
Dec 19, 2017
Browse files
[navierstokes][problem] Add method to set init face solution
* staggered grid specific method to set velocity
parent
4ce22b43
Changes
1
Hide whitespace changes
Inline
Side-by-side
dumux/freeflow/navierstokes/problem.hh
View file @
86cd2150
...
...
@@ -63,6 +63,10 @@ class NavierStokesProblem : public NavierStokesParentProblem<TypeTag>
using
Scalar
=
typename
GET_PROP_TYPE
(
TypeTag
,
Scalar
);
using
FVGridGeometry
=
typename
GET_PROP_TYPE
(
TypeTag
,
FVGridGeometry
);
using
SubControlVolumeFace
=
typename
GET_PROP_TYPE
(
TypeTag
,
SubControlVolumeFace
);
using
SolutionVector
=
typename
GET_PROP_TYPE
(
TypeTag
,
SolutionVector
);
using
PrimaryVariables
=
typename
GET_PROP_TYPE
(
TypeTag
,
PrimaryVariables
);
using
Indices
=
typename
GET_PROP_TYPE
(
TypeTag
,
Indices
);
enum
{
dim
=
Grid
::
dimension
,
...
...
@@ -113,6 +117,18 @@ public:
const
GlobalPosition
&
gravity
()
const
{
return
gravity_
;
}
//! Applys the initial face solution. Specialization for staggered grid discretization.
template
<
class
T
=
TypeTag
>
typename
std
::
enable_if
<
GET_PROP_VALUE
(
T
,
DiscretizationMethod
)
==
DiscretizationMethods
::
Staggered
,
void
>::
type
applyInititalFaceSolution
(
SolutionVector
&
sol
,
const
SubControlVolumeFace
&
scvf
,
const
PrimaryVariables
&
initSol
)
const
{
typename
GET_PROP
(
TypeTag
,
DofTypeIndices
)
::
FaceIdx
faceIdx
;
const
auto
numEqCellCenter
=
GET_PROP_VALUE
(
TypeTag
,
NumEqCellCenter
);
sol
[
faceIdx
][
scvf
.
dofIndex
()][
numEqCellCenter
]
=
initSol
[
Indices
::
velocity
(
scvf
.
directionIndex
())];
}
// \}
private:
...
...
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