Changes in logging of movement at spectrometers.
This commit is contained in:
@@ -25,7 +25,7 @@ void E_Mover_Drift::doWallInteraction(Particle *movePart, vec3 *oldLoc_m, double
|
|||||||
vec3 reverseLoc_m = *oldLoc_m;
|
vec3 reverseLoc_m = *oldLoc_m;
|
||||||
|
|
||||||
// Log Movement before Reflection
|
// Log Movement before Reflection
|
||||||
reverseLoc_m[2] = z_WGTS_end_m;
|
reverseLoc_m[2] = z_WGTS_end_m ;
|
||||||
movePart->set_x_m(reverseLoc_m);
|
movePart->set_x_m(reverseLoc_m);
|
||||||
Logger->log(*movePart, *oldLoc_m);
|
Logger->log(*movePart, *oldLoc_m);
|
||||||
Population->increase_density(*movePart, *oldLoc_m);
|
Population->increase_density(*movePart, *oldLoc_m);
|
||||||
|
|||||||
@@ -62,11 +62,10 @@ inline void MultiZ_Particle_Logger::log(const Particle &logPart, const vec3 &old
|
|||||||
if (!logging) {
|
if (!logging) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
double zold = oldLoc_m[2];
|
double zold = oldLoc_m[2];
|
||||||
double znew = logPart.get_x_m()[2];
|
double znew = logPart.get_x_m()[2];
|
||||||
double zmin = std::min(zold,znew);
|
double zmin = std::min(zold, znew);
|
||||||
double zmax = std::max(zold,znew);
|
double zmax = std::max(zold, znew);
|
||||||
for (int i=0;i<numberZBins;i++) {
|
for (int i=0;i<numberZBins;i++) {
|
||||||
if (zLogValues[i]>=zmin && zLogValues[i]<=zmax) {
|
if (zLogValues[i]>=zmin && zLogValues[i]<=zmax) {
|
||||||
h5tb[i].write(logPart); // Location wrong, because set to new Location, instead of logging location.
|
h5tb[i].write(logPart); // Location wrong, because set to new Location, instead of logging location.
|
||||||
|
|||||||
Reference in New Issue
Block a user