bugfix: remove references to results of calculations and function returns
Fix several bugs like this:
const fvec &dzli = 1. / (zl - targZ);
here dzli is a reference to a temporary calculation result. The code has potentially unpredicted behavior because it is not clear how long the calculation result will be kept in a temporary place.
And anyhow the code has no advantages over the conventional code:
const fvec dzli = 1. / (zl - targZ);