Commit c2be0703 authored by Timo Koch's avatar Timo Koch
Browse files

[cleanup] Use constexpr bool for use moles

parent f6c53701
......@@ -78,7 +78,7 @@ class OnePNCVolumeVariables : public PorousMediumFlowVolumeVariables<TypeTag>
};
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const int dim = GridView::dimension;
static const int dimWorld = GridView::dimensionworld;
......
......@@ -77,7 +77,7 @@ protected:
};
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
public:
using ParentType::ParentType;
......
......@@ -82,7 +82,7 @@ class TwoPTwoCCO2VolumeVariables : public TwoPTwoCVolumeVariables<TypeTag>
pressureIdx = Indices::pressureIdx
};
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
public:
//! The type of the object returned by the fluidState() method
......
......@@ -330,7 +330,7 @@ class RichardsNCVolumeVariables : public RichardsBaseVolumeVariables<TypeTag>
pressureIdx = Indices::pressureIdx
};
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const int dim = GridView::dimension;
static const int dimWorld = GridView::dimensionworld;
static const int numComponents = GET_PROP_VALUE(TypeTag, NumComponents);
......
......@@ -134,7 +134,7 @@ class OnePTwoCNIConductionProblem : public PorousMediumFlowProblem<TypeTag>
};
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const auto phaseIdx = GET_PROP_VALUE(TypeTag, PhaseIdx);
static const bool isBox = GET_PROP_VALUE(TypeTag, DiscretizationMethod) == DiscretizationMethods::Box;
......
......@@ -134,7 +134,7 @@ class OnePTwoCNIConvectionProblem : public PorousMediumFlowProblem<TypeTag>
};
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const auto phaseIdx = GET_PROP_VALUE(TypeTag, PhaseIdx);
static const bool isBox = GET_PROP_VALUE(TypeTag, DiscretizationMethod) == DiscretizationMethods::Box;
......
......@@ -129,7 +129,7 @@ class OnePTwoCTestProblem : public PorousMediumFlowProblem<TypeTag>
};
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const auto phaseIdx = GET_PROP_VALUE(TypeTag, PhaseIdx);
static const bool isBox = GET_PROP_VALUE(TypeTag, DiscretizationMethod) == DiscretizationMethods::Box;
......
......@@ -143,7 +143,7 @@ class WaterAirProblem : public PorousMediumFlowProblem<TypeTag>
using GlobalPosition = Dune::FieldVector<Scalar, dimWorld>;
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
public:
/*!
......
......@@ -108,7 +108,7 @@ class TwoPNCDiffusionProblem : public PorousMediumFlowProblem<TypeTag>
using FVGridGeometry = typename GET_PROP_TYPE(TypeTag, FVGridGeometry);
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
public:
/*!
......
......@@ -168,7 +168,7 @@ class HeterogeneousProblem : public PorousMediumFlowProblem<TypeTag>
using CO2 = Dumux::CO2<Scalar, HeterogeneousCO2Tables::CO2Tables>;
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
// the discretization method we are using
static constexpr auto discMethod = GET_PROP_VALUE(TypeTag, DiscretizationMethod);
......
......@@ -146,7 +146,7 @@ class TracerTestProblem : public PorousMediumFlowProblem<TypeTag>
using SpatialParams = typename GET_PROP_TYPE(TypeTag, SpatialParams);
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const int dimWorld = GridView::dimensionworld;
using GlobalPosition = Dune::FieldVector<Scalar, dimWorld>;
......
......@@ -168,7 +168,7 @@ class TracerTest : public PorousMediumFlowProblem<TypeTag>
using SpatialParams = typename GET_PROP_TYPE(TypeTag, SpatialParams);
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const int dimWorld = GridView::dimensionworld;
using GlobalPosition = Dune::FieldVector<Scalar, dimWorld>;
......
......@@ -188,7 +188,7 @@ class MaxwellStefanTestProblem : public PorousMediumFlowProblem<TypeTag>
using ElementSolutionVector = typename GET_PROP_TYPE(TypeTag, ElementSolutionVector);
//! property that defines whether mole or mass fractions are used
static const bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static constexpr bool useMoles = GET_PROP_VALUE(TypeTag, UseMoles);
static const int dimWorld = GridView::dimensionworld;
using GlobalPosition = Dune::FieldVector<Scalar, dimWorld>;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment