diff --git a/dumux/boxmodels/1p2c/1p2cmodel.hh b/dumux/boxmodels/1p2c/1p2cmodel.hh index 0326eb1cc1bfd36e0a33ca86286a1df6a6ce9488..11e0cf88bc38821977de7ab66f69fa1e02243764 100644 --- a/dumux/boxmodels/1p2c/1p2cmodel.hh +++ b/dumux/boxmodels/1p2c/1p2cmodel.hh @@ -135,7 +135,7 @@ public: ScalarField &velocityY = *writer.allocateManagedBuffer(numVertices); ScalarField &velocityZ = *writer.allocateManagedBuffer(numVertices); //use vertiacl faces for vx and horizontal faces for vy calculation - GlobalPosition boxSurface[numVertices]; + std::vector<GlobalPosition> boxSurface(numVertices); // initialize velocity fields for (int i = 0; i < numVertices; ++i) { diff --git a/dumux/common/propertysystem.hh b/dumux/common/propertysystem.hh index 1c8621eedd2d5106ee35efc75e739402f660528c..56ea18b473a9c61875aef9e600a687823db4f7d8 100644 --- a/dumux/common/propertysystem.hh +++ b/dumux/common/propertysystem.hh @@ -107,25 +107,21 @@ namespace Properties int PropertyInfo<TTAG(EffTypeTagName), PTAG_(PropTagName)>::foo = \ PropertyInfo<TTAG(EffTypeTagName), PTAG_(PropTagName)>::init(); -#define FA_TTAG_(TypeTagName, ...) TTAG(TypeTagName) - //! Internal macro which is only required if the property introspection is enabled -#define TTAG_INFO_(...) \ +#define TTAG_INFO_(TypeTagName, ...) \ template <> \ - struct TypeTagInfo<FA_TTAG_(__VA_ARGS__)> \ + struct TypeTagInfo<TypeTagName> \ { \ static int init() { \ - TypeTagRegistry::addChildren<__VA_ARGS__ >(); \ - return 0; \ - }; \ - static int foo; \ + TypeTagRegistry::addChildren<TypeTagName, ##__VA_ARGS__ >(); \ + return 0; \ + }; \ + static int foo; \ }; \ -int TypeTagInfo<FA_TTAG_(__VA_ARGS__)>::foo = \ - TypeTagInfo<FA_TTAG_(__VA_ARGS__)>::init(); + int TypeTagInfo<TypeTagName>::foo = \ + TypeTagInfo<TypeTagName>::init(); #else -//! Internal macro which is only required if the property introspection is enabled -//! //! Don't do anything if introspection is disabled #define PROP_INFO_(EffTypeTagName, PropKind, PropTagName, ...) #define TTAG_INFO_(EffTypeTagName, ...) @@ -308,14 +304,14 @@ int TypeTagInfo<FA_TTAG_(__VA_ARGS__)>::foo = \ * * The constant can be accessed by the 'value' attribute. */ -#define SET_INT_PROP(EffTypeTagName, PropTagName, Value, ...) \ +#define SET_INT_PROP(EffTypeTagName, PropTagName, /*Value*/...) \ SET_PROP_(EffTypeTagName, \ /*kind=*/"int ", \ PropTagName, \ - /*value=*/Value, ##__VA_ARGS__) \ + /*value=*/__VA_ARGS__) \ { \ typedef int type; \ - static constexpr int value = Value, ##__VA_ARGS__; \ + static constexpr int value = __VA_ARGS__; \ } /*! @@ -323,14 +319,14 @@ int TypeTagInfo<FA_TTAG_(__VA_ARGS__)>::foo = \ * * The constant can be accessed by the 'value' attribute. */ -#define SET_BOOL_PROP(EffTypeTagName, PropTagName, Value, ...) \ - SET_PROP_(EffTypeTagName, \ - /*kind=*/"bool ", \ - PropTagName, \ - /*value=*/Value, ##__VA_ARGS__) \ - { \ - typedef bool type; \ - static constexpr bool value = Value, ##__VA_ARGS__; \ +#define SET_BOOL_PROP(EffTypeTagName, PropTagName, /*Value*/...) \ + SET_PROP_(EffTypeTagName, \ + /*kind=*/"bool ", \ + PropTagName, \ + /*value=*/__VA_ARGS__) \ + { \ + typedef bool type; \ + static constexpr bool value = __VA_ARGS__; \ } /*! @@ -338,13 +334,13 @@ int TypeTagInfo<FA_TTAG_(__VA_ARGS__)>::foo = \ * * The type can be accessed by the 'type' attribute. */ -#define SET_TYPE_PROP(EffTypeTagName, PropTagName, Type, ...) \ - SET_PROP_(EffTypeTagName, \ - /*kind=*/"type ", \ - PropTagName, \ - /*value=*/Type, __VA_ARGS__) \ - { \ - typedef Type, ##__VA_ARGS__ type; \ +#define SET_TYPE_PROP(EffTypeTagName, PropTagName, /*Value*/...) \ + SET_PROP_(EffTypeTagName, \ + /*kind=*/"type ", \ + PropTagName, \ + /*value=*/__VA_ARGS__) \ + { \ + typedef __VA_ARGS__ type; \ } /*! diff --git a/dumux/common/quad.hh b/dumux/common/quad.hh index 75467eb1f79437f264bd491a66c363aadd94f2df..c5f9ba26c94d1e1a1ed738f09db0a53fb20cc6df 100644 --- a/dumux/common/quad.hh +++ b/dumux/common/quad.hh @@ -117,47 +117,47 @@ inline quad ceil(quad val) { return ceilq(val); } inline quad max(quad a, quad b) -{ return (a>b)?a:b; }; +{ return (a>b)?a:b; } inline quad min(quad a, quad b) -{ return (a<b)?a:b; }; +{ return (a<b)?a:b; } inline quad sqrt(quad val) -{ return sqrtq(val); }; +{ return sqrtq(val); } template <class ExpType> inline quad pow(quad base, ExpType exp) -{ return powq(base, exp); }; +{ return powq(base, exp); } inline quad exp(quad val) -{ return expq(val); }; +{ return expq(val); } inline quad log(quad val) -{ return logq(val); }; +{ return logq(val); } inline quad sin(quad val) -{ return sinq(val); }; +{ return sinq(val); } inline quad cos(quad val) -{ return cosq(val); }; +{ return cosq(val); } inline quad tan(quad val) -{ return tanq(val); }; +{ return tanq(val); } inline quad atan(quad val) -{ return atanq(val); }; +{ return atanq(val); } inline quad atan2(quad a, quad b) -{ return atan2q(a, b); }; +{ return atan2q(a, b); } inline bool isfinite(quad val) -{ return !isnanq(val) && !isinfq(val); }; +{ return !isnanq(val) && !isinfq(val); } inline bool isnan(quad val) -{ return isnanq(val); }; +{ return isnanq(val); } inline bool isinf(quad val) -{ return isinfq(val); }; +{ return isinfq(val); } } // namespace std @@ -211,14 +211,14 @@ template <class T> std::string className() { return ClassNameHelper_<T>::name(); -}; +} template <class T> std::string className(const T &t) { return ClassNameHelper_<T>::name(); -}; +} -}; +} #endif // DUMUX_QUAD_HH diff --git a/dumux/common/splinecommon_.hh b/dumux/common/splinecommon_.hh index b895d49f2b7d17e1639310ecc07d973d8473b2c8..ab7060f7325d70149868c28587b3cae533bd5207 100644 --- a/dumux/common/splinecommon_.hh +++ b/dumux/common/splinecommon_.hh @@ -39,7 +39,7 @@ #if __GNUC__ <= 4 && __GNUC_MINOR__ < 5 namespace std { using tr1::get; -}; +} #endif namespace Dumux diff --git a/dumux/common/valgrind.hh b/dumux/common/valgrind.hh index 3280ed90994a65841eda174cb44b9ffb97dfadd6..8a6cc8cc5a8af145061885bfbed5cefaeca0f265 100644 --- a/dumux/common/valgrind.hh +++ b/dumux/common/valgrind.hh @@ -41,8 +41,8 @@ // the BoundaryTypes class) namespace Valgrind { -bool boolBlubb() { return true; }; -void voidBlubb() { }; +bool boolBlubb() { return true; } +void voidBlubb() { } #define SetUndefined(t) voidBlubb() #define SetDefined(t) voidBlubb() diff --git a/dumux/material/components/h2o.hh b/dumux/material/components/h2o.hh index a4496fa898a3b487e9c71f56fb56edf24918efec..0c8e302fa8ee1e712bdb8874d283eccf23c157ab 100644 --- a/dumux/material/components/h2o.hh +++ b/dumux/material/components/h2o.hh @@ -68,7 +68,8 @@ class H2O : public Component<Scalar, H2O<Scalar> > typedef IAPWS::Region2<Scalar> Region2; typedef IAPWS::Region4<Scalar> Region4; - static constexpr Scalar Rs = Common::Rs; // specific gas constant of water + static const Scalar Rs; // specific gas constant of water + public: /*! * \brief A human readable name for the water. @@ -873,6 +874,9 @@ private: }; }; // end class +template <class Scalar> +const Scalar H2O<Scalar>::Rs = Common::Rs; + } // end namepace #endif diff --git a/dumux/material/components/iapws/common.hh b/dumux/material/components/iapws/common.hh index 531de33c02068069383c75f7d8c41bb4d7df94bf..be29ebe4e213496fb5edd10f0bbafb7a6dc836d3 100644 --- a/dumux/material/components/iapws/common.hh +++ b/dumux/material/components/iapws/common.hh @@ -66,31 +66,31 @@ class Common { public: //! The molar mass of water \f$\mathrm{[kg/mol]}\f$ - static constexpr Scalar molarMass = 18.01518e-3; + static const Scalar molarMass; //! Specific gas constant of water \f$\mathrm{[J/(kg*K)]}\f$ - static constexpr Scalar Rs = Dumux::Constants<Scalar>::R/molarMass; + static const Scalar Rs; //! Critical temperature of water \f$\mathrm{[K]}\f$ - static constexpr Scalar criticalTemperature = 647.096; + static const Scalar criticalTemperature; //! Critical pressure of water \f$\mathrm{[Pa]}\f$ - static constexpr Scalar criticalPressure = 22.064e6; + static const Scalar criticalPressure; //! Critical molar volume of water \f$\mathrm{[m^3/mol]}\f$ - static constexpr Scalar criticalMolarVolume = molarMass/322.0; + static const Scalar criticalMolarVolume; //! The acentric factor of water \f$\mathrm{[-]}\f$ - static constexpr Scalar acentricFactor = 0.344; + static const Scalar acentricFactor; //! Density of water at the critical point \f$\mathrm{[kg/m^3]}\f$ - static constexpr Scalar criticalDensity = 322; + static const Scalar criticalDensity; //! Triple temperature of water \f$\mathrm{[K]}\f$ - static constexpr Scalar tripleTemperature = 273.16; + static const Scalar tripleTemperature; //! Triple pressure of water \f$\mathrm{[Pa]}\f$ - static constexpr Scalar triplePressure = 611.657; + static const Scalar triplePressure; /*! * \brief The dynamic viscosity \f$\mathrm{[(N/m^2)*s]}\f$of pure water. @@ -153,6 +153,25 @@ public: } }; +template <class Scalar> +const Scalar Common<Scalar>::molarMass = 18.01518e-3; +template <class Scalar> +const Scalar Common<Scalar>::Rs = Dumux::Constants<Scalar>::R/Common<Scalar>::molarMass; +template <class Scalar> +const Scalar Common<Scalar>::criticalTemperature = 647.096; +template <class Scalar> +const Scalar Common<Scalar>::criticalPressure = 22.064e6; +template <class Scalar> +const Scalar Common<Scalar>::criticalMolarVolume = Common<Scalar>::molarMass/322.0; +template <class Scalar> +const Scalar Common<Scalar>::acentricFactor = 0.344; +template <class Scalar> +const Scalar Common<Scalar>::criticalDensity = 322; +template <class Scalar> +const Scalar Common<Scalar>::tripleTemperature = 273.16; +template <class Scalar> +const Scalar Common<Scalar>::triplePressure = 611.657; + } // end namepace IAPWS } // end namepace Dune diff --git a/dumux/material/components/simpleh2o.hh b/dumux/material/components/simpleh2o.hh index a10c616f13fb68a3d17882e76d8c869f4028c23a..fba5f30efe2322b5548b23a626b7c087ff385bef 100644 --- a/dumux/material/components/simpleh2o.hh +++ b/dumux/material/components/simpleh2o.hh @@ -50,7 +50,7 @@ class SimpleH2O : public Component<Scalar, SimpleH2O<Scalar> > typedef Component<Scalar, SimpleH2O<Scalar> > ParentType; typedef Dumux::IdealGas<Scalar> IdealGas; - static constexpr double R = 461.526; // specific gas constant of water + static const Scalar R; // specific gas constant of water public: /*! @@ -267,6 +267,9 @@ public: }; }; +template <class Scalar> +const Scalar SimpleH2O<Scalar>::R = Dumux::Constants<Scalar>::R / 18e-3; + } // end namepace #endif diff --git a/dumux/material/constants.hh b/dumux/material/constants.hh index f7e5cf3b4565b5cb9f9d625f0b4758c15904b2f2..1550ee4de11cdfaaca09accd9580d11fad9259bb 100644 --- a/dumux/material/constants.hh +++ b/dumux/material/constants.hh @@ -43,38 +43,53 @@ class Constants /*! * \brief The ideal gas constant [J/(mol K)] */ - static constexpr Scalar R = 8.314472; + static const Scalar R; /*! * \brief The Avogadro constant [1/mol] */ - static constexpr Scalar Na = 6.02214179e23; + static const Scalar Na; /*! * \brief The Boltzmann constant [J/K] */ - static constexpr Scalar kb = R/Na; + static const Scalar kb; /*! * \brief Speed of light in vacuum [m/s] */ - static constexpr Scalar c = 299792458; + static const Scalar c; /*! * \brief Newtonian constant of gravitation [m^3/(kg s^2)] */ - static constexpr Scalar G = 6.67428e-11; + static const Scalar G; /*! * \brief Planck constant [J s] */ - static constexpr Scalar h = 6.62606896e-34; + static const Scalar h; /*! * \brief Reduced Planck constant [J s] */ - static constexpr Scalar hRed = h / (2 * M_PI); + static const Scalar hRed; }; + +template<class Scalar> +const Scalar Constants<Scalar>::R = 8.314472; +template<class Scalar> +const Scalar Constants<Scalar>::Na = 6.02214179e23; +template<class Scalar> +const Scalar Constants<Scalar>::kb = Constants<Scalar>::R/Constants<Scalar>::Na; +template<class Scalar> +const Scalar Constants<Scalar>::c = 299792458; +template<class Scalar> +const Scalar Constants<Scalar>::G = 6.67428e-11; +template<class Scalar> +const Scalar Constants<Scalar>::h = 6.62606896e-34; +template<class Scalar> +const Scalar Constants<Scalar>::hRed = Constants<Scalar>::h / (2 * M_PI); } #endif diff --git a/dumux/material/idealgas.hh b/dumux/material/idealgas.hh index 21b4b57f8ad45dbccc67c38ff56e6a529e0fdc5d..56f42de2a3ef790e4855d584cd789179b1b4f90e 100644 --- a/dumux/material/idealgas.hh +++ b/dumux/material/idealgas.hh @@ -40,7 +40,7 @@ class IdealGas { public: //! The ideal gas constant \f$\mathrm{[J/mol/K]}\f$ - static constexpr Scalar R = Dumux::Constants<Scalar>::R; + static const Scalar R; /*! * \brief The density of the gas in \f$\mathrm{[kg/m^3]}\f$, depending on @@ -73,6 +73,9 @@ public: { return molarDensity(temperature, pressure); } }; +template <class Scalar> +const Scalar IdealGas<Scalar>::R = Dumux::Constants<Scalar>::R; + } // end namepace #endif diff --git a/test/boxmodels/1p2c/tissue_tumor_problem.hh b/test/boxmodels/1p2c/tissue_tumor_problem.hh index 8da4f28eeca7c0c0d1e393db061e81fee041b26f..69a405d72a768f4e2e0a31022512aaabd5b538b4 100644 --- a/test/boxmodels/1p2c/tissue_tumor_problem.hh +++ b/test/boxmodels/1p2c/tissue_tumor_problem.hh @@ -243,17 +243,6 @@ public: { //const GlobalPosition &globalPos = element.geometry().corner(scvIdx); values = 0; - - //int globalIdx = this->model().vertexMapper().map(element, scvIdx, dim); - - //Scalar lambda = (globalPos[1])/height_; -// if (globalPos[0] < eps_ ) { -// values[contiEqIdx] = -3.8676e-2; // [kg/(m^2 * s)] - - //values[transEqIdx] = -4.35064e-4; // [mol/(m^2*s) - //Robin-Boundary - //values[transEqIdx] = (*this->model().curSolFunction())[globalIdx][transEqIdx]; -// } } // \} @@ -337,7 +326,6 @@ private: } Scalar totalInjectionVolume_; - static constexpr Scalar eps_ = 1e-6; }; //end namespace } #endif diff --git a/test/boxmodels/2p/lensproblem.hh b/test/boxmodels/2p/lensproblem.hh index 34325e2c316eb347f0fa5252be062cd42ba0ab87..10db15f0ccf9992b706ca8f4526d2ee62c5016d9 100644 --- a/test/boxmodels/2p/lensproblem.hh +++ b/test/boxmodels/2p/lensproblem.hh @@ -216,6 +216,7 @@ public: const GlobalPosition &lensUpperRight) : ParentType(timeManager, gridView) { + eps_ = 3e-6; temperature_ = 273.15 + 20; // -> 20°C this->spatialParameters().setLensCoords(lensLowerLeft, lensUpperRight); } @@ -412,7 +413,7 @@ private: } Scalar temperature_; - static constexpr Scalar eps_ = 3e-6; + Scalar eps_; }; } //end namespace diff --git a/test/boxmodels/2p2c/injectionproblem.hh b/test/boxmodels/2p2c/injectionproblem.hh index ccdadbc70aeda4c02a4812027ec3fa23967a1f4d..a712447bdeb653ccd4c6deef01ebe13d3e9c2fa7 100644 --- a/test/boxmodels/2p2c/injectionproblem.hh +++ b/test/boxmodels/2p2c/injectionproblem.hh @@ -149,6 +149,10 @@ public: InjectionProblem(TimeManager &timeManager, const GridView &gridView) : ParentType(timeManager, gridView) { + temperature_ = 273.15 + 40; // [K] + depthBOR_ = 2700.0; // [m] + eps_ = 1e-6; + // initialize the tables of the fluid system //FluidSystem::init(); FluidSystem::init(/*Tmin=*/temperature_ - 1.0, @@ -336,9 +340,9 @@ private: values[Indices::switchIdx] = massFracLiquidN2; } - static constexpr Scalar temperature_ = 273.15 + 40; // [K] - static constexpr Scalar depthBOR_ = 2700.0; // [m] - static constexpr Scalar eps_ = 1e-6; + Scalar temperature_; + Scalar depthBOR_; + Scalar eps_; }; } //end namespace diff --git a/test/boxmodels/2p2cni/waterairproblem.hh b/test/boxmodels/2p2cni/waterairproblem.hh index cb5aaa62a4c5648d817879ec877b29d2f1a5f0e1..2aaf97a91ccb5ab0bba1c6d6a79b6390e9003caa 100644 --- a/test/boxmodels/2p2cni/waterairproblem.hh +++ b/test/boxmodels/2p2cni/waterairproblem.hh @@ -167,6 +167,9 @@ public: WaterAirProblem(TimeManager &timeManager, const GridView &gridView) : ParentType(timeManager, gridView) { + maxDepth_ = 1000.0; // [m] + eps_ = 1e-6; + FluidSystem::init(); } @@ -335,15 +338,15 @@ private: const GlobalPosition &globalPos) const { Scalar densityW = 1000.0; - values[pressureIdx] = 1e5 + (depthBOR_ - globalPos[1])*densityW*9.81; + values[pressureIdx] = 1e5 + (maxDepth_ - globalPos[1])*densityW*9.81; values[switchIdx] = 0.0; #if !ISOTHERMAL - values[temperatureIdx] = 283.0 + (depthBOR_ - globalPos[1])*0.03; + values[temperatureIdx] = 283.0 + (maxDepth_ - globalPos[1])*0.03; #endif } - static constexpr Scalar depthBOR_ = 1000.0; // [m] - static constexpr Scalar eps_ = 1e-6; + Scalar maxDepth_; + Scalar eps_; }; } //end namespace diff --git a/test/boxmodels/2pni/injectionproblem2pni.hh b/test/boxmodels/2pni/injectionproblem2pni.hh index c2b69331952063affe04ea54d8c9e04d8ac11f3f..cf147375afade411c7d31feacbc6e9b5f6cd0b73 100644 --- a/test/boxmodels/2pni/injectionproblem2pni.hh +++ b/test/boxmodels/2pni/injectionproblem2pni.hh @@ -197,6 +197,9 @@ public: InjectionProblem2PNI(TimeManager &timeManager, const GridView &gridView) : ParentType(timeManager, gridView) { + maxDepth_ = 2700.0; // [m] + eps_ = 1e-6; + // initialize the tables of the fluid system FluidSystem::init(/*tempMin=*/273.15, /*tempMax=*/423.15, @@ -287,10 +290,10 @@ public: const GlobalPosition globalPos = vertex.geometry().center(); Scalar densityW = 1000.0; - values[pressureIdx] = 1e5 + (depthBOR_ - globalPos[1])*densityW*9.81; + values[pressureIdx] = 1e5 + (maxDepth_ - globalPos[1])*densityW*9.81; values[saturationIdx] = 0.0; #if !ISOTHERMAL - values[temperatureIdx] = 283.0 + (depthBOR_ - globalPos[1])*0.03; + values[temperatureIdx] = 283.0 + (maxDepth_ - globalPos[1])*0.03; #endif } @@ -351,11 +354,11 @@ public: const GlobalPosition &globalPos = element.geometry().corner(scvIdx); Scalar densityW = 1000.0; - values[pressureIdx] = 1e5 + (depthBOR_ - globalPos[1])*densityW*9.81; + values[pressureIdx] = 1e5 + (maxDepth_ - globalPos[1])*densityW*9.81; values[saturationIdx] = 0.0; #if !ISOTHERMAL - values[temperatureIdx] = 283.0 + (depthBOR_ - globalPos[1])*0.03; + values[temperatureIdx] = 283.0 + (maxDepth_ - globalPos[1])*0.03; if (globalPos[0] > 20 && globalPos[0] < 30 && globalPos[1] > 5 && globalPos[1] < 35) values[temperatureIdx] = 380; #endif // !ISOTHERMAL @@ -363,8 +366,8 @@ public: // \} private: - static constexpr Scalar depthBOR_ = 2700.0; // [m] - static constexpr Scalar eps_ = 1e-6; + Scalar maxDepth_; + Scalar eps_; }; } //end namespace diff --git a/test/boxmodels/MpNc/obstacleproblem.hh b/test/boxmodels/MpNc/obstacleproblem.hh index fcf929dfbb254d7a58b90b3a95c7b357ce7b65e9..54b9d27f160e72a51a0b2ae720b5cea1016fb36c 100644 --- a/test/boxmodels/MpNc/obstacleproblem.hh +++ b/test/boxmodels/MpNc/obstacleproblem.hh @@ -178,6 +178,7 @@ public: ObstacleProblem(TimeManager &timeManager, const GridView &gridView) : ParentType(timeManager, gridView) { + eps_ = 1e-6; temperature_ = 273.15 + 25; // -> 25°C // initialize the tables of the fluid system @@ -450,7 +451,7 @@ private: }; Scalar temperature_; - static constexpr Scalar eps_ = 1e-6; + Scalar eps_; }; } //end namespace diff --git a/test/boxmodels/richards/richardslensproblem.hh b/test/boxmodels/richards/richardslensproblem.hh index 9df615ed360baa25cbb72635751edd3bd1d071f6..cc8703cfe4a72b68b07e38abf3eaa620d66679e0 100644 --- a/test/boxmodels/richards/richardslensproblem.hh +++ b/test/boxmodels/richards/richardslensproblem.hh @@ -160,13 +160,15 @@ public: const GridView &gridView) : ParentType(timeManager, gridView) { + eps_ = 3e-6; + pnRef_ = 1e5; + lensLowerLeft_[0] = 1.0; lensLowerLeft_[1] = 2.0; lensUpperRight_[0] = 4.0; lensUpperRight_[1] = 3.0; - pnRef_ = 1e5; this->spatialParameters().setLensCoords(lensLowerLeft_, lensUpperRight_); } @@ -333,8 +335,9 @@ private: return onUpperBoundary_(globalPos) && 0.5 < lambda && lambda < 2.0/3.0; } - static constexpr Scalar eps_ = 3e-6; + Scalar eps_; Scalar pnRef_; + GlobalPosition lensLowerLeft_; GlobalPosition lensUpperRight_; }; diff --git a/test/common/generalproblem/generallensproblem.hh b/test/common/generalproblem/generallensproblem.hh index 14bf15e837a41c67e8ba181cbca79811c541450b..422222afa26f6b32419ca7219969682fd5ef8bf1 100644 --- a/test/common/generalproblem/generallensproblem.hh +++ b/test/common/generalproblem/generallensproblem.hh @@ -259,6 +259,7 @@ public: const GlobalPosition &lensUpperRight) : ParentType(timeManager, gridView) { + eps_ = 3e-6; temperature_ = 273.15 + 20; // -> 20°C this->spatialParameters().setLensCoords(lensLowerLeft, lensUpperRight); this->timeManager().startNextEpisode(500); @@ -463,7 +464,7 @@ private: } Scalar temperature_; - static constexpr Scalar eps_ = 3e-6; + Scalar eps_; }; } //end namespace diff --git a/tutorial/tutorialproblem_coupled.hh b/tutorial/tutorialproblem_coupled.hh index cb4b9e370bc3c381b4fb7a86b1207bd260399a87..52cd3b69f09333e2527fbcc926f438d6112afb7e 100644 --- a/tutorial/tutorialproblem_coupled.hh +++ b/tutorial/tutorialproblem_coupled.hh @@ -130,6 +130,7 @@ public: TutorialProblemCoupled(TimeManager &timeManager, const GridView &gridView) : ParentType(timeManager, gridView) + , eps_(3e-6) { } @@ -234,7 +235,7 @@ public: private: // small epsilon value - static constexpr Scalar eps_ = 3e-6; + Scalar eps_; }; }