Commit 35190092 authored by Bernd Flemisch's avatar Bernd Flemisch Committed by Timo Koch
Browse files

[material] replace typedef by using

parent f2753bdd
......@@ -60,8 +60,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
typedef Dumux::Air<Scalar> Air;
typedef Dumux::Mesitylene<Scalar> Mesitylene;
using Air = Dumux::Air<Scalar>;
using Mesitylene = Dumux::Mesitylene<Scalar>;
using std::min;
using std::max;
......
......@@ -60,8 +60,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
typedef Dumux::Air<Scalar> Air;
typedef Dumux::Xylene<Scalar> Xylene;
using Air = Dumux::Air<Scalar>;
using Xylene = Dumux::Xylene<Scalar>;
using std::min;
using std::max;
......
......@@ -37,10 +37,10 @@ namespace BinaryCoeff {
*/
template<class Scalar, class Air, bool verbose = true>
class Brine_Air {
typedef Dumux::H2O<Scalar> H2O;
// typedef Dumux::Air<Scalar> Air;
typedef Dumux::Brine<Scalar,H2O> Brine;
typedef Dumux::IdealGas<Scalar> IdealGas;
using H2O = Dumux::H2O<Scalar>;
// using Air = Dumux::Air<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
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
......@@ -397,10 +397,10 @@ private:
template<class Scalar, class Air, bool verbose = true>
class Brine_Air_Old
{
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::Brine<Scalar,H2O> Brine;
// typedef Dumux::Air<Scalar> Air;
typedef Dumux::IdealGas<Scalar> IdealGas;
using H2O = Dumux::H2O<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
// using Air = Dumux::Air<Scalar>;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
......@@ -37,9 +37,9 @@ namespace BinaryCoeff {
*/
template<class Scalar, class CO2Tables, bool verbose = true>
class Brine_CO2 {
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::CO2<Scalar, CO2Tables> CO2;
typedef Dumux::IdealGas<Scalar> IdealGas;
using H2O = Dumux::H2O<Scalar>;
using CO2 = Dumux::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
......@@ -381,10 +381,10 @@ private:
template<class Scalar, class CO2Tables, bool verbose = true>
class Brine_CO2_Old
{
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::Brine<Scalar,H2O> Brine;
typedef Dumux::CO2<Scalar, CO2Tables> CO2;
typedef Dumux::IdealGas<Scalar> IdealGas;
using H2O = Dumux::H2O<Scalar>;
using Brine = Dumux::Brine<Scalar,H2O>;
using CO2 = Dumux::CO2<Scalar, CO2Tables>;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
......@@ -65,8 +65,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::Mesitylene<Scalar> Mesitylene;
using H2O = Dumux::H2O<Scalar>;
using Mesitylene = Dumux::Mesitylene<Scalar>;
using std::min;
using std::max;
......
......@@ -67,8 +67,8 @@ public:
template <class Scalar>
static Scalar gasDiffCoeff(Scalar temperature, Scalar pressure)
{
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::N2<Scalar> N2;
using H2O = Dumux::H2O<Scalar>;
using N2 = Dumux::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)
{
typedef Dumux::H2O<Scalar> H2O;
typedef O2<Scalar> O2;
using H2O = Dumux::H2O<Scalar>;
using O2 = 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)
{
typedef Dumux::H2O<Scalar> H2O;
typedef Dumux::Xylene<Scalar> Xylene;
using H2O = Dumux::H2O<Scalar>;
using Xylene = Dumux::Xylene<Scalar>;
using std::min;
using std::max;
......
......@@ -56,7 +56,7 @@ inline Scalar henryIAPWS(Scalar E,
Scalar H,
Scalar temperature)
{
typedef Dumux::H2O<Scalar> H2O;
using H2O = Dumux::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)
{
typedef Dumux::N2<Scalar> N2;
typedef Dumux::O2<Scalar> O2;
using N2 = Dumux::N2<Scalar>;
using O2 = Dumux::O2<Scalar>;
// atomic diffusion volumes
const Scalar SigmaNu[2] = { 18.1 /* N2 */, 16.3 /* O2 */ };
......
......@@ -49,19 +49,19 @@ enum ElectroChemistryModel { Ochs, Acosta };
template <class TypeTag, ElectroChemistryModel electroChemistryModel>
class ElectroChemistry
{
typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar;
typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem;
typedef typename GET_PROP_TYPE(TypeTag, VolumeVariables) VolumeVariables;
typedef typename GET_PROP_TYPE(TypeTag, NumEqVector) SourceValues;
typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView;
typedef typename GridView::template Codim<0>::Entity Element;
typedef typename GET_PROP_TYPE(TypeTag, FVElementGeometry) FVElementGeometry;
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using VolumeVariables = typename GET_PROP_TYPE(TypeTag, VolumeVariables);
using SourceValues = typename GET_PROP_TYPE(TypeTag, NumEqVector);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using Element = typename GridView::template Codim<0>::Entity;
using FVElementGeometry = typename GET_PROP_TYPE(TypeTag, FVElementGeometry);
typedef Constants<Scalar> Constant;
using Constant = Constants<Scalar>;
typedef ElectroChemistry<TypeTag, electroChemistryModel> ThisType;
using ThisType = ElectroChemistry<TypeTag, electroChemistryModel>;
typedef typename GET_PROP_TYPE(TypeTag, Indices) Indices;
using Indices = typename GET_PROP_TYPE(TypeTag, Indices);
enum {
//indices of the phases
......
......@@ -41,17 +41,17 @@ namespace Dumux
template <class TypeTag, ElectroChemistryModel electroChemistryModel>
class ElectroChemistryNI : public ElectroChemistry<TypeTag, electroChemistryModel>
{
typedef ElectroChemistry<TypeTag, electroChemistryModel> ParentType;
using ParentType = ElectroChemistry<TypeTag, electroChemistryModel>;
typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar;
typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView;
typedef typename GET_PROP_TYPE(TypeTag, FluidSystem) FluidSystem;
typedef typename GET_PROP_TYPE(TypeTag, VolumeVariables) VolumeVariables;
typedef typename GET_PROP_TYPE(TypeTag, NumEqVector) SourceValues;
using Scalar = typename GET_PROP_TYPE(TypeTag, Scalar);
using GridView = typename GET_PROP_TYPE(TypeTag, GridView);
using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
using VolumeVariables = typename GET_PROP_TYPE(TypeTag, VolumeVariables);
using SourceValues = typename GET_PROP_TYPE(TypeTag, NumEqVector);
typedef Constants<Scalar> Constant;
using Constant = Constants<Scalar>;
typedef typename GET_PROP_TYPE(TypeTag, Indices) Indices;
using Indices = typename GET_PROP_TYPE(TypeTag, Indices);
enum {
//indices of the components
wCompIdx = FluidSystem::wCompIdx, //major component of the liquid phase
......
......@@ -42,7 +42,7 @@ namespace Dumux
template <class Scalar>
class Air : public Component<Scalar, Air<Scalar> >
{
typedef Dumux::IdealGas<Scalar> IdealGas;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
......@@ -45,7 +45,7 @@ namespace Dumux
template <class Scalar>
class CH4 : public Component<Scalar, CH4<Scalar> >
{
typedef Dumux::IdealGas<Scalar> IdealGas;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
......@@ -51,7 +51,7 @@ template <class Scalar, class CO2Tables>
class CO2 : public Component<Scalar, CO2<Scalar, CO2Tables> >
{
static const Scalar R;
typedef Dumux::IdealGas<Scalar> IdealGas;
using IdealGas = Dumux::IdealGas<Scalar>;
static bool warningThrown;
......
......@@ -36,7 +36,7 @@ namespace Dumux {
template <class Traits>
class TabulatedCO2Properties
{
typedef typename Traits::Scalar Scalar;
using Scalar = typename Traits::Scalar;
enum { numTempSteps = Traits::numTempSteps, numPressSteps = Traits::numPressSteps };
public:
......
......@@ -45,7 +45,7 @@ namespace Dumux
template <class Scalar>
class H2 : public Component<Scalar, H2<Scalar> >
{
typedef Dumux::IdealGas<Scalar> IdealGas;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
......@@ -42,7 +42,7 @@ namespace Dumux
template <class Scalar>
class HeavyOil : public Component<Scalar, HeavyOil<Scalar> >
{
typedef Dumux::Constants<Scalar> Consts;
using Consts = Dumux::Constants<Scalar>;
public:
/*!
......
......@@ -42,7 +42,7 @@ namespace Dumux
template <class Scalar>
class Mesitylene : public Component<Scalar, Mesitylene<Scalar> >
{
typedef Constants<Scalar> Consts;
using Consts = Constants<Scalar>;;
public:
/*!
......
......@@ -45,7 +45,7 @@ namespace Dumux
template <class Scalar>
class N2 : public Component<Scalar, N2<Scalar> >
{
typedef Dumux::IdealGas<Scalar> IdealGas;
using IdealGas = Dumux::IdealGas<Scalar>;
public:
/*!
......
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