Skip to main content
Tweeted twitter.com/#!/StackMma/status/419922151417057280
edited title
Link
Dr. belisarius
  • 116.8k
  • 13
  • 208
  • 466

Probability of the sum of the largest 4n samples

added 39 characters in body
Source Link
bobbym
  • 2.7k
  • 2
  • 17
  • 20

15 numbers are randomly chosen from U(0,1), what is the probability that the sum of largest four numbers is greater than 3.5?

 With[{f = OrderDistribution[{UniformDistribution[], 15}, #] &}, Probability[a + b + c + d > 3 + 1 / 2, {a \[Distributed] f[15], b \[Distributed] f[14], c \[Distributed] f[13], d\[Distributed] f[12]}]] 

Trouble is, it is very, very slow. I shut it down after 30 minutes. When I used NProbability it converged on the wrong answer but it did warn me with numerous error messages. Another CAS could do the above code but it also returned the same wrong answer. The right answer is supposed to be (it at least agrees with a simulation):

$\frac{224077804910008595}{584325558976905216} $

$\approx 0.383481094515780$

How do I do this using Mathematica?

15 numbers are randomly chosen from U(0,1), what is the probability that the sum of largest four numbers is greater than 3.5?

 With[{f = OrderDistribution[{UniformDistribution[], 15}, #] &}, Probability[a + b + c + d > 3 + 1 / 2, {a \[Distributed] f[15], b \[Distributed] f[14], c \[Distributed] f[13], d\[Distributed] f[12]}]] 

Trouble is, it is very, very slow. I shut it down after 30 minutes. When I used NProbability it converged on the wrong answer but it did warn me with numerous error messages. Another CAS could do the above code but it also returned the same wrong answer. The right answer is supposed to be:

$\frac{224077804910008595}{584325558976905216} $

$\approx 0.383481094515780$

How do I do this using Mathematica?

15 numbers are randomly chosen from U(0,1), what is the probability that the sum of largest four numbers is greater than 3.5?

 With[{f = OrderDistribution[{UniformDistribution[], 15}, #] &}, Probability[a + b + c + d > 3 + 1 / 2, {a \[Distributed] f[15], b \[Distributed] f[14], c \[Distributed] f[13], d\[Distributed] f[12]}]] 

Trouble is, it is very, very slow. I shut it down after 30 minutes. When I used NProbability it converged on the wrong answer but it did warn me with numerous error messages. Another CAS could do the above code but it also returned the same wrong answer. The right answer is supposed to be (it at least agrees with a simulation):

$\frac{224077804910008595}{584325558976905216} $

$\approx 0.383481094515780$

How do I do this using Mathematica?

Source Link
bobbym
  • 2.7k
  • 2
  • 17
  • 20

Probability of the largest 4

15 numbers are randomly chosen from U(0,1), what is the probability that the sum of largest four numbers is greater than 3.5?

 With[{f = OrderDistribution[{UniformDistribution[], 15}, #] &}, Probability[a + b + c + d > 3 + 1 / 2, {a \[Distributed] f[15], b \[Distributed] f[14], c \[Distributed] f[13], d\[Distributed] f[12]}]] 

Trouble is, it is very, very slow. I shut it down after 30 minutes. When I used NProbability it converged on the wrong answer but it did warn me with numerous error messages. Another CAS could do the above code but it also returned the same wrong answer. The right answer is supposed to be:

$\frac{224077804910008595}{584325558976905216} $

$\approx 0.383481094515780$

How do I do this using Mathematica?