From d7575b0397495e35785dd2a046be2f92270feb8a Mon Sep 17 00:00:00 2001 From: Arne Morten Kvarving Date: Tue, 18 Oct 2016 14:14:07 +0200 Subject: [PATCH] fixed: need to pass the solution vector on instance creation setting it in solveStep is too late as exported fields are registered for output before --- Apps/Common/SIMSolverAdap.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Apps/Common/SIMSolverAdap.h b/Apps/Common/SIMSolverAdap.h index b38680b9..69152a6a 100644 --- a/Apps/Common/SIMSolverAdap.h +++ b/Apps/Common/SIMSolverAdap.h @@ -28,7 +28,11 @@ template class SIMSolverAdap : public SIMSolver { public: //! \brief The constructor forwards to the parent class constructor. - SIMSolverAdap(T1& s1) : SIMSolver(s1), aSim(s1,false) {} + SIMSolverAdap(T1& s1) : SIMSolver(s1), aSim(s1,false) + { + this->S1.setSol(&aSim.getSolution()); + } + //! \brief Empty destructor. virtual ~SIMSolverAdap() {} @@ -39,7 +43,6 @@ public: if (exporter) exporter->setNormPrefixes(aSim.getNormPrefixes()); - this->S1.setSol(&aSim.getSolution()); aSim.setupProjections(); aSim.initAdaptor(0,2);