multinomial sampler