From cd2bef15b3165c24d39423347d1e6ed6389bfe59 Mon Sep 17 00:00:00 2001 From: "P.M. Sutter" Date: Fri, 12 Jul 2013 03:15:13 -0500 Subject: [PATCH] stackVoidsZero now (partially) understands periodic boundaries --- python_tools/pipeline_source/prepareCatalogs.in.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/python_tools/pipeline_source/prepareCatalogs.in.py b/python_tools/pipeline_source/prepareCatalogs.in.py index 4586341..7aaa442 100644 --- a/python_tools/pipeline_source/prepareCatalogs.in.py +++ b/python_tools/pipeline_source/prepareCatalogs.in.py @@ -553,7 +553,11 @@ if (args.script or args.all) and haloFileBase != "": numPart += 1 inFile.close() - minRadius = int(np.ceil(lbox/numPart**(1./3.))) + meanDen = lbox/numPart**(1./3.) + if meanDen < 1: + minRadius = 4 + else: + minRadius = int(np.ceil(meanDen)) if minHaloMass != "none": strMinHaloMass = "%.2e" % minHaloMass