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
f56916b2
Commit
f56916b2
authored
Dec 15, 2017
by
Kilian Weishaupt
Committed by
Timo Koch
Dec 19, 2017
Browse files
[navierstokes] Adapt indices
* add method to determine the velocity index for a given direction
parent
f2399bb1
Changes
1
Hide whitespace changes
Inline
Side-by-side
dumux/freeflow/navierstokes/indices.hh
View file @
f56916b2
...
...
@@ -55,11 +55,15 @@ struct NavierStokesCommonIndices
static
constexpr
int
momentumXBalanceIdx
=
momentumBalanceIdx
;
//!< Index of the momentum balance equation
static
constexpr
int
momentumYBalanceIdx
=
momentumBalanceIdx
+
1
;
//!< Index of the momentum balance equation
static
constexpr
int
momentumZBalanceIdx
=
momentumBalanceIdx
+
2
;
//!< Index of the momentum balance equation
static
constexpr
int
velocityIdx
=
momentumBalanceIdx
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityXIdx
=
velocityIdx
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityYIdx
=
velocityIdx
+
1
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityZIdx
=
velocityIdx
+
2
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityXIdx
=
momentumBalanceIdx
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityYIdx
=
momentumBalanceIdx
+
1
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocityZIdx
=
momentumBalanceIdx
+
2
;
//!< Index of the velocity in a solution vector
static
constexpr
int
velocity
(
int
dirIdx
)
//!< Index of the velocity in a solution vector given a certain dimension
{
return
dirIdx
+
momentumBalanceIdx
;
}
};
// \}
...
...
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