updated distribution function