code: static boolean sum2one(final double[] probabilities) {
  		final double sum = probabilities.length > 0
  			? DoubleAdder.sum(probabilities)
  			: 1.0;
  		return abs(ulpDistance(sum, 1.0)) < MAX_ULP_DISTANCE;
  	}
docs: Check if the given probabilities sum to one.
  
  @param probabilities the probabilities to check.
  @return {@code true} if the sum of the probabilities are within the error
  range, {@code false} otherwise.