Skip to content
Snippets Groups Projects
Commit 225e95cf authored by Timo Koch's avatar Timo Koch
Browse files

[fvlocalassembler] Remove superfluous member function

parent a878e4c8
No related branches found
No related tags found
1 merge request!737Improve assembly more
...@@ -41,9 +41,9 @@ namespace Dumux { ...@@ -41,9 +41,9 @@ namespace Dumux {
* \brief A base class for all local assemblers * \brief A base class for all local assemblers
* \tparam TypeTag The TypeTag * \tparam TypeTag The TypeTag
* \tparam Assembler The assembler type * \tparam Assembler The assembler type
* \tparam implicit Specifies whether the time discretization is implicit or not not (i.e. explicit) * \tparam isImplicit Specifies whether the time discretization is implicit or not not (i.e. explicit)
*/ */
template<class TypeTag, class Assembler, class Implementation, bool implicit> template<class TypeTag, class Assembler, class Implementation, bool isImplicit>
class FVLocalAssemblerBase class FVLocalAssemblerBase
{ {
using Problem = typename GET_PROP_TYPE(TypeTag, Problem); using Problem = typename GET_PROP_TYPE(TypeTag, Problem);
...@@ -88,7 +88,7 @@ public: ...@@ -88,7 +88,7 @@ public:
*/ */
auto evalLocalResidual() const auto evalLocalResidual() const
{ {
if(this->assembler().isStationaryProblem() && !isImplicit()) if(this->assembler().isStationaryProblem() && !isImplicit)
DUNE_THROW(Dune::InvalidStateException, "Using explicit jacobian assembler with stationary local residual"); DUNE_THROW(Dune::InvalidStateException, "Using explicit jacobian assembler with stationary local residual");
if(elementIsGhost()) if(elementIsGhost())
...@@ -97,8 +97,8 @@ public: ...@@ -97,8 +97,8 @@ public:
return ResdiualType(0.0); return ResdiualType(0.0);
} }
return isImplicit() ? evalLocalResidual(curElemVolVars()) return isImplicit ? evalLocalResidual(curElemVolVars())
: evalLocalResidual(prevElemVolVars()); : evalLocalResidual(prevElemVolVars());
} }
/*! /*!
...@@ -124,8 +124,8 @@ public: ...@@ -124,8 +124,8 @@ public:
*/ */
auto evalLocalFluxAndSourceResidual() const auto evalLocalFluxAndSourceResidual() const
{ {
return isImplicit() ? evalLocalFluxAndSourceResidual(curElemVolVars()) return isImplicit ? evalLocalFluxAndSourceResidual(curElemVolVars())
: evalLocalFluxAndSourceResidual(prevElemVolVars()); : evalLocalFluxAndSourceResidual(prevElemVolVars());
} }
/*! /*!
...@@ -167,7 +167,7 @@ public: ...@@ -167,7 +167,7 @@ public:
// bind the caches // bind the caches
fvGeometry.bind(element); fvGeometry.bind(element);
if(isImplicit()) if(isImplicit)
{ {
curElemVolVars.bind(element, fvGeometry, curSol); curElemVolVars.bind(element, fvGeometry, curSol);
elemFluxVarsCache.bind(element, fvGeometry, curElemVolVars); elemFluxVarsCache.bind(element, fvGeometry, curElemVolVars);
...@@ -250,9 +250,6 @@ public: ...@@ -250,9 +250,6 @@ public:
const LocalResidual& localResidual() const const LocalResidual& localResidual() const
{ return localResidual_; } { return localResidual_; }
constexpr bool isImplicit() const
{ return implicit; }
protected: protected:
Implementation &asImp_() Implementation &asImp_()
{ return *static_cast<Implementation*>(this); } { return *static_cast<Implementation*>(this); }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment