preprocessor now filters debug output
This commit is contained in:
@@ -186,12 +186,14 @@ bool DynamicDensityField::changedPitchAngleBin(double old_mu,
|
||||
const int old_bin = pitch_angle_binning_.bin(old_mu);
|
||||
const int new_bin = pitch_angle_binning_.bin(new_mu);
|
||||
|
||||
#ifdef debug_level3
|
||||
if(!(old_bin == new_bin)) {
|
||||
DEBUG_LEVEL_3("old mu: " + std::to_string(old_mu));
|
||||
DEBUG_LEVEL_3("old bin: " + std::to_string(old_bin));
|
||||
DEBUG_LEVEL_3("new mu: " + std::to_string(new_mu));
|
||||
DEBUG_LEVEL_3("new bin: " + std::to_string(new_bin));
|
||||
}
|
||||
#endif
|
||||
|
||||
return !(old_bin == new_bin);
|
||||
}
|
||||
@@ -225,7 +227,9 @@ void DynamicDensityField::logMovement(const Coordinate& position,
|
||||
// }
|
||||
|
||||
blitz::Array<double, 3> DynamicDensityField::densityArray() {
|
||||
#ifdef debug_level3
|
||||
DEBUG_LEVEL_3("recalc Density array");
|
||||
#endif
|
||||
recalculateDensityArray();
|
||||
|
||||
blitz::TinyVector<int,3> lowerbound(density_per_m3_.lbound(0),
|
||||
@@ -237,7 +241,7 @@ blitz::Array<double, 3> DynamicDensityField::densityArray() {
|
||||
blitz::Array<double, 3> density(lowerbound, extent);
|
||||
|
||||
blitz::fourthIndex iE;
|
||||
DEBUG_LEVEL_3("density sum");
|
||||
// DEBUG_LEVEL_3("density sum");
|
||||
density = blitz::sum(density_per_m3_, iE);
|
||||
return density.copy();
|
||||
}
|
||||
@@ -303,7 +307,9 @@ void DynamicDensityField::recalculateDensityArray() {
|
||||
double DynamicDensityField::particleNumber() {
|
||||
blitz::Array<double, 3> density = densityArray();
|
||||
double particleNumber = blitz::sum(density * bin_volume_m3_);
|
||||
#ifdef debug_level3
|
||||
DEBUG_LEVEL_3("particle number: " + std::to_string(particleNumber));
|
||||
#endif
|
||||
return particleNumber;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user