version 3.8
freeflow/shallowwater/indices.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//
12#ifndef DUMUX_FREEFLOW_SHALLOW_WATER_INDICES_HH
13#define DUMUX_FREEFLOW_SHALLOW_WATER_INDICES_HH
14
15namespace Dumux {
16
17// \{
23{
24 static constexpr int dimXIdx = 0;
25 static constexpr int dimYIdx = 1;
26
27 static constexpr int massBalanceIdx = 0;
28 static constexpr int momentumXBalanceIdx = 1;
29 static constexpr int momentumYBalanceIdx = 2;
30
31 static constexpr int waterdepthIdx = massBalanceIdx;
32 static constexpr int velocityXIdx = momentumXBalanceIdx;
33 static constexpr int velocityYIdx = momentumYBalanceIdx;
34 static constexpr int velocityOffset = velocityXIdx;
35};
36
37// \}
38} // end namespace Dumux
39
40#endif
Definition: adapt.hh:17
The common indices for the shallow water equations model.
Definition: freeflow/shallowwater/indices.hh:23
static constexpr int dimYIdx
Index of the y-component of a vector of size dim.
Definition: freeflow/shallowwater/indices.hh:25
static constexpr int waterdepthIdx
Index of the velocity in a solution vector.
Definition: freeflow/shallowwater/indices.hh:31
static constexpr int velocityXIdx
Index of the velocity in a solution vector.
Definition: freeflow/shallowwater/indices.hh:32
static constexpr int momentumYBalanceIdx
Index of the y momentum balance equation.
Definition: freeflow/shallowwater/indices.hh:29
static constexpr int massBalanceIdx
Index of the mass balance equation.
Definition: freeflow/shallowwater/indices.hh:27
static constexpr int velocityYIdx
Index of the velocity in a solution vector.
Definition: freeflow/shallowwater/indices.hh:33
static constexpr int momentumXBalanceIdx
Index of the x momentum balance equation.
Definition: freeflow/shallowwater/indices.hh:28
static constexpr int velocityOffset
Offset for the velocity index.
Definition: freeflow/shallowwater/indices.hh:34
static constexpr int dimXIdx
Index of the x-component of a vector of size dim.
Definition: freeflow/shallowwater/indices.hh:24