News for hackers. Stuff that matters.
Re:How many draws of a random number [0,1] are needed to sum... by mturmon on Sunday February 24, 2013 @03:02PM (#5275674)
Hey, nice answer. If you are comfortable with the formula (http://en.wikipedia.org/wiki/Expected_value#Discrete_distrib...):

  E[N] = Sum_{i >= 0} P(N >= i)
then you can reduce some of your calculations and edge considerations.

Because the chance that (N >= i) is the volume below the standard simplex, which, as you note, is just 1/i!. Plug in to the above and you get

  E[N] = Sum_{i >= 0} 1/i! = 1/e
Re:How many draws of a random number [0,1] are needed to sum... by Sniffnoy on Sunday February 24, 2013 @03:45PM (#5275821)
Yeah, I guess that neatly encapsulates the bit about subtracting off to make it exact before multiplying by n...