Added sampling for pi