diff --git a/fem/discretefunction/adaptivefunction.cc b/fem/discretefunction/adaptivefunction.cc index 3a9357dfd455cb65acf11cf87866290af0c2b6ca..c4cc06de8aed6149377455d4ab2a0016867e4e74 100644 --- a/fem/discretefunction/adaptivefunction.cc +++ b/fem/discretefunction/adaptivefunction.cc @@ -16,7 +16,9 @@ namespace Dune { DofStorageType& dofVec) : spc_(spc), dofVec_(dofVec), - values_() + values_(), + tmp_(0.0), + tmpGrad_(0.0) {} template <class DiscreteFunctionSpaceImp, class DofManagerImp> @@ -24,7 +26,9 @@ namespace Dune { AdaptiveLocalFunction(const ThisType& other) : spc_(other.spc_), dofVec_(other.dofVec_), - values_() + values_(), + tmp_(0.0), + tmpGrad_(0.0) {} template <class DiscreteFunctionSpaceImp, class DofManagerImp> @@ -64,7 +68,7 @@ namespace Dune { const BaseFunctionSetType& bSet = spc_.getBaseFunctionSet(en); for (int i = 0; i < bSet.getNumberOfBaseFunctions(); ++i) { - bSet.evaluate(i, x, tmp_); + bSet.eval(i, x, tmp_); for (int l = 0; l < dimRange; ++l) { ret[l] += (*values_[i]) * tmp_[l]; } @@ -79,7 +83,7 @@ namespace Dune { int quadPoint, RangeType& ret) const { - evaluatueLocal(en, quad.point(quadPoint), ret); + evaluateLocal(en, quad.point(quadPoint), ret); } template <class DiscreteFunctionSpaceImp, class DofManagerImp> @@ -131,6 +135,7 @@ namespace Dune { } //- AdaptiveLocalFunction (Specialisation for CombinedSpace) + template <class ContainedFunctionSpaceImp, int N, DofStoragePolicy p, class DofManagerImp> AdaptiveLocalFunction< @@ -309,5 +314,4 @@ namespace Dune { } - } // end namespace Dune diff --git a/fem/discretefunction/adaptivefunction.hh b/fem/discretefunction/adaptivefunction.hh index 880df891a9318f379706122b9c21c0219c237c5b..bbdebfbd344d96b82143deca7714faca65961fe0 100644 --- a/fem/discretefunction/adaptivefunction.hh +++ b/fem/discretefunction/adaptivefunction.hh @@ -211,8 +211,8 @@ namespace Dune { mutable std::vector<RangeFieldType*> values_; - mutable RangeType& tmp_; - mutable JacobianRangeType& tmpGrad_; + mutable RangeType tmp_; + mutable JacobianRangeType tmpGrad_; }; // end class AdaptiveLocalFunction //- Specialisations