Geometric sample size determination in Bayesian analysis