added better stopping conditions
added max rounds
when minRounds>=0 use exact denoms
merge 17.18
fix maxRounds / simplify conditions
fix progress bar