Calculation of molecular weight distributions in free-radical polymerization with chain branching