diff --git a/core/include/engine/Solver_Heun.hpp b/core/include/engine/Solver_Heun.hpp index 4cb85d2f0..d72820c60 100644 --- a/core/include/engine/Solver_Heun.hpp +++ b/core/include/engine/Solver_Heun.hpp @@ -65,7 +65,7 @@ void Method_Solver::Iteration () // Second step - Corrector Backend::par::apply( nos, [conf, conf_predictor, f_virtual, f_virtual_predictor] SPIRIT_LAMBDA (int idx) { conf[idx] = ( - conf[idx] + 0.5*( conf[idx] - 0.5*conf[idx].cross(f_virtual[idx]) - conf_predictor[idx].cross(f_virtual_predictor[idx]) ) + conf[idx] - 0.5 * ( conf[idx].cross( f_virtual[idx] ) + conf_predictor[idx].cross(f_virtual_predictor[idx]) ) ).normalized(); } ); } diff --git a/core/include/engine/Solver_SIB.hpp b/core/include/engine/Solver_SIB.hpp index 179f4d4ca..e79be815d 100644 --- a/core/include/engine/Solver_SIB.hpp +++ b/core/include/engine/Solver_SIB.hpp @@ -30,8 +30,8 @@ void Method_Solver::Iteration () this->Calculate_Force_Virtual(this->configurations, this->forces, this->forces_virtual); for (int i = 0; i < this->noi; ++i) { - auto image = *this->systems[i]->spins; - auto predictor = *this->configurations_predictor[i]; + auto& image = *this->systems[i]->spins; + auto& predictor = *this->configurations_predictor[i]; Solver_Kernels::sib_transform(image, forces_virtual[i], predictor); auto imagep = this->systems[i]->spins->data();