public void setProbability(bool b, double d) { distribution.set(d, b); if (isRoot()) { distribution.set(1.0 - d, !b); } }