cleaned up procedure for checking for 'obviously bad' voids; no longer filters on density contrast since this only affects edge voids anyway

This commit is contained in:
Paul M. Sutter 2025-03-25 14:49:41 -04:00
parent 93d847b158
commit f9fc9e8990

View file

@ -277,7 +277,7 @@ int main(int argc, char **argv) {
volNorm = numPartTot/(boxLen[0]*boxLen[1]*boxLen[2]);
printf(" VOL NORM = %f\n", volNorm);
printf(" CENTRAL DEN = %f\n", args.maxCentralDen_arg);
printf(" MAX CENTRAL DEN = %e\n", args.maxCentralDen_arg);
fread(&dummy, 1, 4, fp);
fread(temp, numPartTot, 4, fp);
@ -823,8 +823,8 @@ int main(int argc, char **argv) {
// toss out voids that are obviously wrong
int iGood = 0;
for (iVoid = 0; iVoid < voids.size(); iVoid++) {
if (voids[iVoid].densCon > 1.e4 || isnan(voids[iVoid].vol) ||
isinf(voids[iVoid].vol)) {
if (isnan(voids[iVoid].vol) || isinf(voids[iVoid].vol)) {
numWrong++;
} else {
voids[iGood++] = voids[iVoid];