PH test starts growing alternate trees; algorithm takes additional parameters; plus minor fixes