Commit 2a3b89f0 authored by Melanie Lipp's avatar Melanie Lipp Committed by Timo Koch
Browse files

Remove all deprecation warning related to Components.

With contributions of Ned Coltman  <edward.coltman@iws.uni-stuttgart.de>.
parent 4c50c9d1
......@@ -60,8 +60,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using Air = Dumux::Air<Scalar>;
using Mesitylene = Dumux::Mesitylene<Scalar>;
using Air = Dumux::Components::Air<Scalar>;
using Mesitylene = Dumux::Components::Mesitylene<Scalar>;
using std::min;
using std::max;
......
......@@ -60,8 +60,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using Air = Dumux::Air<Scalar>;
using Xylene = Dumux::Xylene<Scalar>;
using Air = Dumux::Components::Air<Scalar>;
using Xylene = Dumux::Components::Xylene<Scalar>;
using std::min;
using std::max;
......
......@@ -37,9 +37,9 @@ namespace BinaryCoeff {
*/
template<class Scalar, class Air, bool verbose = true>
class Brine_Air {
using H2O = Dumux::H2O<Scalar>;
// using Air = Dumux::Air<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
using H2O = Dumux::Components::H2O<Scalar>;
// using Air = Dumux::Components::Air<Scalar>;
using Brine = Dumux::Components::Brine<Scalar,H2O>;
using IdealGas = Dumux::IdealGas<Scalar>;
static const int wPhaseIdx = 0; // index of the liquid phase
static const int nPhaseIdx = 1; // index of the gas phase
......@@ -397,9 +397,9 @@ private:
template<class Scalar, class Air, bool verbose = true>
class Brine_Air_Old
{
using H2O = Dumux::H2O<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
// using Air = Dumux::Air<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
using Brine = Dumux::Components::Brine<Scalar,H2O>;
// using Air = Dumux::Components::Air<Scalar>;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
......
......@@ -37,8 +37,8 @@ namespace BinaryCoeff {
*/
template<class Scalar, class CO2Tables, bool verbose = true>
class Brine_CO2 {
using H2O = Dumux::H2O<Scalar>;
using CO2 = Dumux::CO2<Scalar, CO2Tables>;
using H2O = Dumux::Components::H2O<Scalar>;
using CO2 = Dumux::Components::CO2<Scalar, CO2Tables>;
using IdealGas = Dumux::IdealGas<Scalar>;
static const int lPhaseIdx = 0; // index of the liquid phase
static const int gPhaseIdx = 1; // index of the gas phase
......@@ -380,9 +380,9 @@ private:
template<class Scalar, class CO2Tables, bool verbose = true>
class Brine_CO2_Old
{
using H2O = Dumux::H2O<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
using CO2 = Dumux::CO2<Scalar, CO2Tables>;
using H2O = Dumux::Components::H2O<Scalar>;
using Brine = Dumux::Components::Brine<Scalar,H2O>;
using CO2 = Dumux::Components::CO2<Scalar, CO2Tables>;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
......
......@@ -74,8 +74,8 @@ public:
{
// DUNE_THROW(Dune::NotImplemented, "diffusion coefficient for gasous water and methane");
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::CH4<Scalar> CH4;
typedef Dumux::Components::H2O<Scalar> H2O;
typedef Dumux::Components::CH4<Scalar> CH4;
// atomic diffusion volumes
// Vch4 = sum(ni*Vi) = 15.9 + 4*2.31 = 25.14 (Tang et al., 2015)--> method, (Poling et al., 2001, p.11.11)--> values
......
......@@ -64,8 +64,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using H2O = Dumux::H2O<Scalar>;
using Mesitylene = Dumux::Mesitylene<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
using Mesitylene = Dumux::Components::Mesitylene<Scalar>;
using std::min;
using std::max;
......
......@@ -67,8 +67,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using H2O = Dumux::H2O<Scalar>;
using N2 = Dumux::N2<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
using N2 = Dumux::Components::N2<Scalar>;
// atomic diffusion volumes
const Scalar SigmaNu[2] = { 13.1 /* H2O */, 18.5 /* N2 */ };
......
......@@ -67,8 +67,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using H2O = Dumux::H2O<Scalar>;
using O2 = O2<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
using O2 = Components::O2<Scalar>;
// atomic diffusion volumes
const Scalar SigmaNu[2] = { 13.1 /* H2O */, 16.3 /* O2 */ };
......
......@@ -67,8 +67,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using H2O = Dumux::H2O<Scalar>;
using Xylene = Dumux::Xylene<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
using Xylene = Dumux::Components::Xylene<Scalar>;
using std::min;
using std::max;
......
......@@ -55,7 +55,7 @@ inline Scalar henryIAPWS(Scalar E,
Scalar H,
Scalar temperature)
{
using H2O = Dumux::H2O<Scalar>;
using H2O = Dumux::Components::H2O<Scalar>;
// regularizing temperature helps for stability.
// Results are unphysical!
......
......@@ -62,8 +62,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
using N2 = Dumux::N2<Scalar>;
using O2 = Dumux::O2<Scalar>;
using N2 = Dumux::Components::N2<Scalar>;
using O2 = Dumux::Components::O2<Scalar>;
// atomic diffusion volumes
const Scalar SigmaNu[2] = { 18.1 /* N2 */, 16.3 /* O2 */ };
......
......@@ -31,7 +31,7 @@
#include <dumux/common/exceptions.hh>
#include <dumux/discretization/methods.hh>
#include <dumux/material/constants.hh>
#include <dumux/material/components/component.hh>
#include <dumux/material/fluidsystems/h2on2o2.hh>
namespace Dumux {
......
......@@ -11,7 +11,6 @@ ch4.hh
co2.hh
co2tablereader.hh
co2tables.inc
component.hh
constant.hh
h2.hh
h2o.hh
......@@ -24,6 +23,5 @@ simpleco2.hh
simpleh2o.hh
tabulatedcomponent.hh
trichloroethene.hh
unit.hh
xylene.hh
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/dumux/material/components)
......@@ -25,10 +25,10 @@
#define DUMUX_AIR_HH
#include <dumux/common/exceptions.hh>
#include <dumux/material/components/component.hh>
#include <dumux/material/idealgas.hh>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/gas.hh>
namespace Dumux {
namespace Components {
......@@ -40,8 +40,9 @@ namespace Components {
* \tparam Scalar The type used for scalar values
*/
template <class Scalar>
class Air : public Components::Base<Scalar, Air<Scalar> >,
public Components::Gas<Scalar, Air<Scalar> >
class Air
: public Components::Base<Scalar, Air<Scalar> >
, public Components::Gas<Scalar, Air<Scalar> >
{
using IdealGas = Dumux::IdealGas<Scalar>;
......@@ -337,9 +338,6 @@ public:
} // end namespace Components
template<class Scalar>
using Air DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::Air<Scalar>;
} // end namespace Dumux
#endif
......@@ -25,9 +25,10 @@
#define DUMUX_BENZENE_HH
#include <dumux/material/idealgas.hh>
#include "component.hh"
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/liquid.hh>
#include <dumux/material/components/gas.hh>
namespace Dumux {
namespace Components {
......@@ -39,7 +40,10 @@ namespace Components {
* \tparam Scalar The type used for scalar values
*/
template <class Scalar>
class Benzene : public Component<Scalar, Benzene<Scalar> >
class Benzene
: public Components::Base<Scalar, Benzene<Scalar> >
, public Components::Liquid<Scalar, Benzene<Scalar> >
, public Components::Gas<Scalar, Benzene<Scalar> >
{
public:
......@@ -93,9 +97,6 @@ public:
} // end namespace Components
template<class Scalar>
using Benzene DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::Benzene<Scalar>;
} // end namespace Dumux
#endif
......@@ -25,14 +25,15 @@
#define DUMUX_BRINE_HH
#include <dumux/material/components/component.hh>
#include <dumux/material/components/h2o.hh>
#include <dumux/material/components/nacl.hh>
#include <dumux/material/components/tabulatedcomponent.hh>
#include <cmath>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/liquid.hh>
#include <dumux/material/components/gas.hh>
namespace Dumux {
namespace Components {
......@@ -45,12 +46,14 @@ namespace Components {
* \tparam H2O Static polymorphism: the Brine class can access all properties of the H2O class
*/
template <class Scalar,
class H2O_Tabulated = TabulatedComponent<H2O<Scalar>>>
class Brine : public Component<Scalar, Brine<Scalar, H2O_Tabulated> >
class H2O_Tabulated = Components::TabulatedComponent<Components::H2O<Scalar>>>
class Brine
: public Components::Base<Scalar, Brine<Scalar, H2O_Tabulated> >
, public Components::Liquid<Scalar, Brine<Scalar, H2O_Tabulated> >
, public Components::Gas<Scalar, Brine<Scalar, H2O_Tabulated> >
{
public:
using H2O = TabulatedComponent<Dumux::H2O<Scalar>>;
using H2O = Components::TabulatedComponent<Dumux::Components::H2O<Scalar>>;
//HACK: If salinity is a pseudo-component, a constat value is used
static Scalar constantSalinity;
......@@ -68,7 +71,7 @@ public:
static Scalar molarMass(Scalar salinity = constantSalinity)
{
const Scalar M1 = H2O::molarMass();
const Scalar M2 = NaCl<Scalar>::molarMass(); // molar mass of NaCl [kg/mol]
const Scalar M2 = Components::NaCl<Scalar>::molarMass(); // molar mass of NaCl [kg/mol]
const Scalar X2 = salinity; // mass fraction of salt in brine
return M1*M2/(M2 + X2*(M1 - M2));
};
......@@ -396,9 +399,6 @@ Scalar Brine<Scalar, H2O>::constantSalinity = 0.1;
} // end namespace Components
template <class Scalar, class H2O = TabulatedComponent<H2O<Scalar>>>
using Brine DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::Brine<Scalar, H2O>;
} // end namespace Dumux
#endif
......@@ -25,13 +25,12 @@
#define DUMUX_CAO_HH
#include <dumux/common/exceptions.hh>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/component.hh>
#include <cmath>
#include <iostream>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/solid.hh>
namespace Dumux {
namespace Components {
......@@ -41,7 +40,9 @@ namespace Components {
* \brief A class for the CaO properties
*/
template <class Scalar>
class CaO : public Component<Scalar, CaO<Scalar> >
class CaO
: public Components::Base<Scalar, CaO<Scalar> >
, public Components::Solid<Scalar, CaO<Scalar> >
{
public:
/*!
......@@ -79,9 +80,6 @@ public:
} // end namespace Components
template<class Scalar>
using CaO DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::CaO<Scalar>;
} // end namespace Dumux
#endif
......@@ -26,12 +26,12 @@
#include <dumux/common/exceptions.hh>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/component.hh>
#include <cmath>
#include <iostream>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/solid.hh>
namespace Dumux {
namespace Components {
......@@ -41,7 +41,9 @@ namespace Components {
* \brief A class for the CaO2H2 properties
*/
template <class Scalar>
class CaO2H2 : public Component<Scalar, CaO2H2<Scalar> >
class CaO2H2
: public Components::Base<Scalar, CaO2H2<Scalar> >
, public Components::Solid<Scalar, CaO2H2<Scalar> >
{
public:
/*!
......@@ -79,9 +81,6 @@ public:
} // end namespace Components
template<class Scalar>
using CaO2H2 DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::CaO2H2<Scalar>;
} // end namespace Dumux
#endif
......@@ -26,11 +26,10 @@
#include <dumux/material/idealgas.hh>
#include "component.hh"
#include <cmath>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/gas.hh>
namespace Dumux {
namespace Components {
......@@ -41,7 +40,9 @@ namespace Components {
* \tparam Scalar The type used for scalar values
*/
template <class Scalar>
class CH4 : public Component<Scalar, CH4<Scalar> >
class CH4
: public Components::Base<Scalar, CH4<Scalar> >
, public Components::Gas<Scalar, CH4<Scalar> >
{
using IdealGas = Dumux::IdealGas<Scalar>;
......@@ -232,9 +233,6 @@ public:
} // end namespace Components
template<class Scalar>
using CH4 DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::CH4<Scalar>;
} // end namespace Dumux
#endif
......@@ -25,14 +25,15 @@
#define DUMUX_CO2_HH
#include <dumux/common/exceptions.hh>
#include <dumux/material/components/component.hh>
#include <dumux/material/constants.hh>
#include <dumux/material/idealgas.hh>
#include <cmath>
#include <iostream>
#include <dune/common/deprecated.hh>
#include <dumux/material/components/base.hh>
#include <dumux/material/components/liquid.hh>
#include <dumux/material/components/gas.hh>
namespace Dumux {
namespace Components {
......@@ -50,7 +51,10 @@ namespace Components {
// TODO: Is this component limited to supercritical conditions?
template <class Scalar, class CO2Tables>
class CO2 : public Component<Scalar, CO2<Scalar, CO2Tables> >
class CO2
: public Components::Base<Scalar, CO2<Scalar, CO2Tables> >
, public Components::Liquid<Scalar, CO2<Scalar, CO2Tables> >
, public Components::Gas<Scalar, CO2<Scalar, CO2Tables> >
{
static const Scalar R;
using IdealGas = Dumux::IdealGas<Scalar>;
......@@ -392,9 +396,6 @@ bool CO2<Scalar, CO2Tables>::warningThrown = false;
} // end namespace Components
template <class Scalar, class CO2Tables>
using CO2 DUNE_DEPRECATED_MSG("Now in the namespace: Components") = Dumux::Components::CO2<Scalar, CO2Tables>;
} // end namespace Dumux
#endif
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