Probability of the union and intersection of independent events