From 888262c8990c26486c8fa45ad1bc7abb49fb7449 Mon Sep 17 00:00:00 2001 From: Jonathan Youett <youett@math.fu-berlin.de> Date: Wed, 25 Mar 2015 16:52:56 +0100 Subject: [PATCH] Rename member from A/f to A_/f_ and make compile --- .../common/nonlinearelasticityproblem.cc | 16 ++++++++-------- .../common/nonlinearelasticityproblem.hh | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/dune/elasticity/common/nonlinearelasticityproblem.cc b/dune/elasticity/common/nonlinearelasticityproblem.cc index 39fc4b5..0694f0c 100644 --- a/dune/elasticity/common/nonlinearelasticityproblem.cc +++ b/dune/elasticity/common/nonlinearelasticityproblem.cc @@ -10,17 +10,17 @@ void NonlinearElasticityProblem<VectorType, MatrixType, Basis>::assembleQP(const const Basis& basis = material_->basis(); - GridFunctionPtr displace = std::make_shared<BasisGridFunction<Basis,VectorType> >(basis,iterate);A + GridFunctionPtr displace = std::make_shared<BasisGridFunction<Basis,VectorType> >(basis,iterate); // assemble quadratic term OperatorAssembler<Basis,Basis> globalAssembler(basis,basis); - globalAssembler.assemble(material_->secondDerivative(displace), A); + globalAssembler.assemble(material_->secondDerivative(displace), A_); // assemble linear term FunctionalAssembler<Basis> funcAssembler(basis); - funcAssembler.assemble(material_->firstDerivative(displace), f); - f -= *extForces_; - f *= -1; + funcAssembler.assemble(material_->firstDerivative(displace), f_); + f_ -= *extForces_; + f_ *= -1; } template <class VectorType, class MatrixType, class Basis> @@ -94,11 +94,11 @@ typename VectorType::field_type NonlinearElasticityProblem<VectorType,MatrixType template <class VectorType, class MatrixType, class Basis> typename VectorType::field_type NonlinearElasticityProblem<VectorType,MatrixType, Basis>::modelDecrease(const VectorType& correction) const { - // the model decrease is simply <f,corr> - 0.5 <corr, H corr> + // the model decrease is simply -<f,corr> - 0.5 <corr, H corr> VectorType tmp(correction.size()); - A.mv(correction, tmp); + A_.mv(correction, tmp); - return (f*correction) - 0.5 * (correction*tmp); + return (f_*correction) - 0.5 * (correction*tmp); } diff --git a/dune/elasticity/common/nonlinearelasticityproblem.hh b/dune/elasticity/common/nonlinearelasticityproblem.hh index 2a80781..f2da69b 100644 --- a/dune/elasticity/common/nonlinearelasticityproblem.hh +++ b/dune/elasticity/common/nonlinearelasticityproblem.hh @@ -44,9 +44,9 @@ public: field_type modelDecrease(const VectorType& correction) const; //! The quadratic part - MatrixType A; + MatrixType A_; //! The linear functional - VectorType f; + VectorType f_; private: //! The involved materials -- GitLab