When Lz < 4 · rMaxLimit, the stencil cannot reach every reacting pair
z = std::max(4, ...) forces four z-cells regardless of the box thickness, and check_dimensions() reapplies the same floor rather than correcting it.
Below Lz = 4 · rMaxLimit, the cells become thinner than the interaction range, and the ±1 stencil no longer covers the full range. Pairs separated by two cells along z are therefore never passed to check_bimolecular_reactions().
Measured using the rev_3D model—with 2,000 molecules, rMaxLimit = 16.70 nm, 1,000 steps, and 19 snapshots—while varying the box thickness and counting every pair by brute force:
Box Lz |
cells_z |
Z-cell size |
rMaxLimit |
Pairs in range |
Reached by stencil |
Missed |
| 30 nm |
4 |
7.50 nm |
16.70 nm |
29,123 |
26,951 |
2,172 (7.5%) |
| 50 nm |
4 |
12.50 nm |
16.70 nm |
20,475 |
20,391 |
84 (0.41%) |
| 100 nm |
5 |
20.00 nm |
16.70 nm |
11,350 |
11,350 |
0 |
| 940 nm |
30 |
31.33 nm |
16.70 nm |
1,328 |
1,328 |
0 |
The boundary is exactly where the arithmetic predicts:
- Zero missed pairs whenever the z-cell size is greater than or equal to
rMaxLimit.
- Nonzero missed pairs as soon as the four-cell floor forces the z-cell size below
rMaxLimit.
This produces a systematic bias in the association rate, not a statistical fluctuation, and it occurs silently.
Origin
This issue is pre-existing. The implementations in Dimensions() and check_dimensions() are byte-identical to those on master; the nerdss-optimized branch neither introduced nor fixed the problem.
When
Lz < 4 · rMaxLimit, the stencil cannot reach every reacting pairz = std::max(4, ...)forces four z-cells regardless of the box thickness, andcheck_dimensions()reapplies the same floor rather than correcting it.Below
Lz = 4 · rMaxLimit, the cells become thinner than the interaction range, and the ±1 stencil no longer covers the full range. Pairs separated by two cells along z are therefore never passed tocheck_bimolecular_reactions().Measured using the
rev_3Dmodel—with 2,000 molecules,rMaxLimit = 16.70 nm, 1,000 steps, and 19 snapshots—while varying the box thickness and counting every pair by brute force:Lzcells_zrMaxLimitThe boundary is exactly where the arithmetic predicts:
rMaxLimit.rMaxLimit.This produces a systematic bias in the association rate, not a statistical fluctuation, and it occurs silently.
Origin
This issue is pre-existing. The implementations in
Dimensions()andcheck_dimensions()are byte-identical to those onmaster; thenerdss-optimizedbranch neither introduced nor fixed the problem.