Hamiltonian::addContribution should have this signature:
void addContribution(double, const StateVectorLow&, StateVectorLow&, double, bool replace) const
(or even)
void addContribution(double, const StateVectorLow&, StateVectorLow&&, double, bool replace) const
Then, it could replace with its contribution, instead of adding
=> in MCWF_Trajectory::derivs Psi=0 initialization not necessaly
Master rho=0 ditto
Liouvillean::actWithJ should have this signature:
void actWithJ_v(double, const StateVectorLow& psiIN, StateVectorLow& psiOUT, size_t) const
(or even)
void actWithJ_v(double, const StateVectorLow& psiIN, StateVectorLow&& psiOUT, size_t) const
(noting that psiOUT might be the same as psiIN)
=> copy of rho in Master::step not necessary
Exact::actWithU ditto.