Commit df9145d9 authored by Markus Wolff's avatar Markus Wolff
Browse files

Changed grouping of parameters and properties which are default

parameters according to the Dumux meeting at 26.07.12 (see
/doc/propparams.ods)



git-svn-id: svn://svn.iws.uni-stuttgart.de/DUMUX/dumux/trunk@8803 2fb0f335-1f38-0410-981e-8018bf24f1b0
parent 2afc31a8
......@@ -77,7 +77,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
upwindWeight_ = GET_PARAM(TypeTag, Scalar, UpwindWeight);
upwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -59,8 +59,10 @@ NEW_PROP_TAG(SpatialParams); //!< The type of the spatial parameters object
NEW_PROP_TAG(SpatialParameters); //!< DEPRECATED The type of the spatial parameters object
NEW_PROP_TAG(FluidSystem); //!< The type of the fluid system to use
NEW_PROP_TAG(Fluid); //!< The fluid used for the default fluid system
NEW_PROP_TAG(EnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(UpwindWeight); //!< Returns weight of the upwind cell when calculating fluxes
NEW_PROP_TAG(ProblemEnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(EnableGravity); //!< DEPRECATED Returns whether gravity is considered in the problem
NEW_PROP_TAG(UpwindWeight); //!< DEPRECATED Returns weight of the upwind cell when calculating fluxes
NEW_PROP_TAG(ImplicitMassUpwindWeight); //!< Returns weight of the upwind cell when calculating fluxes
NEW_PROP_TAG(MobilityUpwindWeight); //!< Weight for the upwind mobility in the velocity calculation
// \}
......
......@@ -81,7 +81,8 @@ SET_TYPE_PROP(BoxOneP, SpatialParameters, typename GET_PROP_TYPE(TypeTag, Spatia
//! The weight of the upwind control volume when calculating
//! fluxes. Use central differences by default.
SET_SCALAR_PROP(BoxOneP, UpwindWeight, 0.5);
SET_SCALAR_PROP(BoxOneP, ImplicitMassUpwindWeight, GET_PROP_VALUE(TypeTag, UpwindWeight));
SET_SCALAR_PROP(BoxOneP, UpwindWeight, 0.5);//DEPRECATED
//! weight for the upwind mobility in the velocity calculation
SET_SCALAR_PROP(BoxOneP, MobilityUpwindWeight, 1.0);
......@@ -96,6 +97,9 @@ public:
typedef Dumux::LiquidPhase<Scalar, Dumux::NullComponent<Scalar> > type;
};
//Has to be removed if DEPRECATED EnableGravity is removed!
SET_BOOL_PROP(BoxOneP, ProblemEnableGravity, GET_PROP_VALUE(TypeTag, EnableGravity));
// \}
} // end namepace Properties
......
......@@ -406,7 +406,7 @@ protected:
///////////////
// correct the pressure gradients by the gravitational acceleration
///////////////
if (GET_PARAM(TypeTag, bool, EnableGravity)) {
if (GET_PARAM_FROM_GROUP(TypeTag, bool, Problem, EnableGravity)) {
// calculate the phase density at the integration point. we
// only do this if the wetting phase is present in both cells
Scalar rhoI = elemVolVars[face().i].density();
......
......@@ -104,7 +104,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
upwindWeight_ = GET_PARAM(TypeTag, Scalar, UpwindWeight);
upwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -105,7 +105,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
upwindWeight_ = GET_PARAM(TypeTag, Scalar, UpwindWeight);
upwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
}
/*!
......
......@@ -62,8 +62,10 @@ NEW_PROP_TAG(Indices); //!< Enumerations for the model
NEW_PROP_TAG(SpatialParams); //!< The type of the spatial parameters
NEW_PROP_TAG(SpatialParameters); //!< DEPRECATED The type of the spatial parameters
NEW_PROP_TAG(FluidSystem); //!< Type of the multi-component relations
NEW_PROP_TAG(UpwindWeight); //!< The default value of the upwind weight
NEW_PROP_TAG(EnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(UpwindWeight); //!< DEPRECATED The default value of the upwind weight
NEW_PROP_TAG(ImplicitMassUpwindWeight); //!< The default value of the upwind weight
NEW_PROP_TAG(ProblemEnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(EnableGravity); //!< DEPRECATED Returns whether gravity is considered in the problem
NEW_PROP_TAG(UseMoles); //!Defines whether mole (true) or mass (false) fractions are used
NEW_PROP_TAG(Scaling); //!Defines Scaling of the model
}
......
......@@ -70,7 +70,8 @@ SET_TYPE_PROP(BoxOnePTwoC, VolumeVariables, OnePTwoCVolumeVariables<TypeTag>);
SET_TYPE_PROP(BoxOnePTwoC, FluxVariables, OnePTwoCFluxVariables<TypeTag>);
//! set default upwind weight to 1.0, i.e. fully upwind
SET_SCALAR_PROP(BoxOnePTwoC, UpwindWeight, 1.0);
SET_SCALAR_PROP(BoxOnePTwoC, ImplicitMassUpwindWeight, GET_PROP_VALUE(TypeTag, UpwindWeight));
SET_SCALAR_PROP(BoxOnePTwoC, UpwindWeight, 1.0);//DEPRECATED!!
//! Set the indices used by the 1p2c model
SET_TYPE_PROP(BoxOnePTwoC, Indices, Dumux::OnePTwoCIndices<TypeTag, 0>);
......@@ -83,6 +84,9 @@ SET_TYPE_PROP(BoxOnePTwoC, SpatialParameters, typename GET_PROP_TYPE(TypeTag, Sp
//! Set the phaseIndex per default to zero (important for two-phase fluidsystems).
SET_INT_PROP(BoxOnePTwoC, PhaseIdx, 0);
//Has to be removed if DEPRECATED EnableGravity is removed!
SET_BOOL_PROP(BoxOnePTwoC, ProblemEnableGravity, GET_PROP_VALUE(TypeTag, EnableGravity));
}
// \}
}
......
......@@ -78,7 +78,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -129,7 +129,7 @@ public:
void addOutputVtkFields(const SolutionVector &sol,
MultiWriter &writer)
{
bool velocityOutput = GET_PROP_VALUE(TypeTag, EnableVelocityOutput);
bool velocityOutput = GET_PARAM_FROM_GROUP(TypeTag, bool, Vtk, AddVelocity);
typedef Dune::BlockVector<Dune::FieldVector<double, 1> > ScalarField;
typedef Dune::BlockVector<Dune::FieldVector<double, dim> > VectorField;
......
......@@ -59,8 +59,10 @@ NEW_TYPE_TAG(BoxTwoP, INHERITS_FROM(BoxModel));
//////////////////////////////////////////////////////////////////
NEW_PROP_TAG(NumPhases); //!< Number of fluid phases in the system
NEW_PROP_TAG(EnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(MassUpwindWeight); //!< The value of the weight of the upwind direction in the mass conservation equations
NEW_PROP_TAG(ProblemEnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(EnableGravity); //!< DEPRECATED Returns whether gravity is considered in the problem
NEW_PROP_TAG(ImplicitMassUpwindWeight); //!< The value of the weight of the upwind direction in the mass conservation equations
NEW_PROP_TAG(MassUpwindWeight); //!< DEPRECATED The value of the weight of the upwind direction in the mass conservation equations
NEW_PROP_TAG(MobilityUpwindWeight); //!< Weight for the upwind mobility in the velocity calculation
NEW_PROP_TAG(Formulation); //!< The formulation of the model
NEW_PROP_TAG(TwoPIndices); //!< DEPRECATED Enumerations for the 2p models
......@@ -73,7 +75,8 @@ NEW_PROP_TAG(WettingPhase); //!< The wetting phase for two-phase models
NEW_PROP_TAG(NonwettingPhase); //!< The non-wetting phase for two-phase models
NEW_PROP_TAG(FluidSystem); //!<The fluid systems including the information about the phases
NEW_PROP_TAG(FluidState); //!<The phases state
NEW_PROP_TAG(EnableVelocityOutput); //!< Returns whether vertex velocity vectors are written into the vtk output
NEW_PROP_TAG(VtkAddVelocity); //!< Returns whether velocity vectors are written into the vtk output
NEW_PROP_TAG(EnableVelocityOutput); //!< DEPRECATED Returns whether vertex velocity vectors are written into the vtk output
}
}
......
......@@ -76,7 +76,8 @@ SET_TYPE_PROP(BoxTwoP, VolumeVariables, TwoPVolumeVariables<TypeTag>);
SET_TYPE_PROP(BoxTwoP, FluxVariables, BoxDarcyFluxVariables<TypeTag>);
//! the upwind weight for the mass conservation equations.
SET_SCALAR_PROP(BoxTwoP, MassUpwindWeight, 1.0);
SET_SCALAR_PROP(BoxTwoP, ImplicitMassUpwindWeight, GET_PROP_VALUE(TypeTag, MassUpwindWeight));
SET_SCALAR_PROP(BoxTwoP, MassUpwindWeight, 1.0);//DEPRECATED
//! weight for the upwind mobility in the velocity calculation
SET_SCALAR_PROP(BoxTwoP, MobilityUpwindWeight, 1.0);
......@@ -136,8 +137,11 @@ public:
};
// disable velocity output by default
SET_BOOL_PROP(BoxTwoP, EnableVelocityOutput, false);
SET_BOOL_PROP(BoxTwoP, VtkAddVelocity, GET_PROP_VALUE(TypeTag, EnableVelocityOutput));
SET_BOOL_PROP(BoxTwoP, EnableVelocityOutput, false);//DEPRECATED
//Has to be removed if DEPRECATED EnableGravity is removed!
SET_BOOL_PROP(BoxTwoP, ProblemEnableGravity, GET_PROP_VALUE(TypeTag, EnableGravity));
}
//
......
......@@ -184,7 +184,7 @@ protected:
///////////////
// correct the pressure gradients by the gravitational acceleration
///////////////
if (GET_PARAM(TypeTag, bool, EnableGravity)) {
if (GET_PARAM_FROM_GROUP(TypeTag, bool, Problem, EnableGravity)) {
// estimate the gravitational acceleration at a given SCV face
// using the arithmetic mean
DimVector g(problem.boxGravity(element, fvGeometry_, face().i));
......
......@@ -102,7 +102,7 @@ class TwoPTwoCLocalResidual: public GET_PROP_TYPE(TypeTag, BaseLocalResidual)
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -153,7 +153,7 @@ public:
setSwitched_(false);
// check, if velocity output can be used (works only for cubes so far)
velocityOutput_ = GET_PARAM(TypeTag, bool, EnableVelocityOutput);
velocityOutput_ = GET_PARAM_FROM_GROUP(TypeTag, bool, Vtk, AddVelocity);
ElementIterator eIt = this->gridView_().template begin<0>();
ElementIterator eEndIt = this->gridView_().template end<0>();
for (; eIt != eEndIt; ++eIt)
......@@ -162,7 +162,7 @@ public:
velocityOutput_ = false;
}
}
if (velocityOutput_ != GET_PARAM(TypeTag, bool, EnableVelocityOutput))
if (velocityOutput_ != GET_PARAM_FROM_GROUP(TypeTag, bool, Vtk, AddVelocity))
std::cout << "ATTENTION: Velocity output only works for cubes and is set to false for simplices\n";
VertexIterator vIt = this->gridView_().template begin<dim> ();
......@@ -182,7 +182,7 @@ public:
= staticVertexDat_[globalIdx].phasePresence;
}
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
}
/*!
......@@ -432,7 +432,7 @@ public:
// Get the Darcy velocities. The Darcy velocities are divided by the area of the subcontrolvolume
// face in the reference element.
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
PhasesVector flux;
flux[phaseIdx] = fluxVars.KmvpNormal(phaseIdx)
* (massUpwindWeight_
......
......@@ -65,10 +65,13 @@ NEW_PROP_TAG(FluidSystem); //!< Type of the multi-component relations
NEW_PROP_TAG(MaterialLaw); //!< The material law which ought to be used (extracted from the spatial parameters)
NEW_PROP_TAG(MaterialLawParams); //!< The parameters of the material law (extracted from the spatial parameters)
NEW_PROP_TAG(EnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(MassUpwindWeight); //!< The value of the upwind weight for the mass conservation equations
NEW_PROP_TAG(ProblemEnableGravity); //!< Returns whether gravity is considered in the problem
NEW_PROP_TAG(EnableGravity); //!< DEPRECATED Returns whether gravity is considered in the problem
NEW_PROP_TAG(ImplicitMassUpwindWeight); //!< The value of the upwind weight for the mass conservation equations
NEW_PROP_TAG(MassUpwindWeight); //!< DEPRECATED The value of the upwind weight for the mass conservation equations
NEW_PROP_TAG(ReplaceCompEqIdx); //!< The index of the total mass balance equation, if one component balance is replaced (ReplaceCompEqIdx < NumComponents)
NEW_PROP_TAG(EnableVelocityOutput); //!< Returns whether vertex velocity vectors are written into the vtk output
NEW_PROP_TAG(VtkAddVelocity); //!< Returns whether velocity vectors are written into the vtk output
NEW_PROP_TAG(EnableVelocityOutput); //!< DEPRECATED Returns whether vertex velocity vectors are written into the vtk output
}
}
......
......@@ -123,7 +123,8 @@ SET_TYPE_PROP(BoxTwoPTwoC, VolumeVariables, TwoPTwoCVolumeVariables<TypeTag>);
SET_TYPE_PROP(BoxTwoPTwoC, FluxVariables, TwoPTwoCFluxVariables<TypeTag>);
//! the upwind weight for the mass conservation equations.
SET_SCALAR_PROP(BoxTwoPTwoC, MassUpwindWeight, 1.0);
SET_SCALAR_PROP(BoxTwoPTwoC, ImplicitMassUpwindWeight, GET_PROP_VALUE(TypeTag, MassUpwindWeight));
SET_SCALAR_PROP(BoxTwoPTwoC, MassUpwindWeight, 1.0);//DEPRECATED
//! The indices required by the isothermal 2p2c model
SET_PROP(BoxTwoPTwoC,
......@@ -141,8 +142,12 @@ SET_TYPE_PROP(BoxTwoPTwoC, TwoPTwoCIndices, typename GET_PROP_TYPE(TypeTag, Indi
SET_TYPE_PROP(BoxTwoPTwoC, SpatialParameters, typename GET_PROP_TYPE(TypeTag, SpatialParams));
// disable velocity output by default
SET_BOOL_PROP(BoxTwoPTwoC, VtkAddVelocity, GET_PROP_VALUE(TypeTag, EnableVelocityOutput));
SET_BOOL_PROP(BoxTwoPTwoC, EnableVelocityOutput, false);
//Has to be removed if DEPRECATED EnableGravity is removed!
SET_BOOL_PROP(BoxTwoPTwoC, ProblemEnableGravity, GET_PROP_VALUE(TypeTag, EnableGravity));
//
}
......
......@@ -75,7 +75,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -81,7 +81,7 @@ public:
// retrieve the upwind weight for the mass conservation equations. Use the value
// specified via the property system as default, and overwrite
// it by the run-time parameter from the Dune::ParameterTree
massUpwindWeight_ = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
massUpwindWeight_ = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
};
/*!
......
......@@ -158,7 +158,7 @@ public:
void computeAdvectiveFlux(PrimaryVariables &flux, const FluxVariables &fluxVars) const
{
Scalar massUpwindWeight = GET_PARAM(TypeTag, Scalar, MassUpwindWeight);
Scalar massUpwindWeight = GET_PARAM_FROM_GROUP(TypeTag, Scalar, Implicit, MassUpwindWeight);
////////
// advective fluxes of all components in all phases
......
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