added inverse cdf method