implement Bernoulli_sum as conversion from unweighted to weighted counting