Comments on: complex dice probability make head esplode
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode/
Comments on Ask MetaFilter post complex dice probability make head esplodeFri, 21 Dec 2007 14:01:37 -0800Fri, 21 Dec 2007 14:01:37 -0800en-ushttp://blogs.law.harvard.edu/tech/rss60Question: complex dice probability make head esplode
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode
I need a tool to help me analyze the probability of certain events occurring regarding a pool of X dice for a game I am creating. See my examples below.
<br /><br /> I am looking for a dice statistics program or, baring that, a set of formulas I could input into excel, that can answer the following questions. Graphing capabilities are a plus.<br>
<br>
Some of the events I want to analyze:<br>
<br>
1) The probability that, from a pool of X dice, Y dice can be chosen by a player such that the sum of the Y dice is equal or lesser than a number N.<br>
<br>
2) Related to the previous question; of the pools that succeed what is the distribution of how close they are to hitting N, (for instance, if the sum of Y dice is 10 and the number the player was aiming for was 12 then they are only off by 2).<br>
<br>
3) In a pool of X dice How likely is it that there will be Z sets of doubles (say two 6s or snake eyes) and, more specifically, what are the chances of getting a specific set of doubles (say just snake eyes).<br>
<br>
I am pretty statistics theory inept (never took it in school) but I am average to above average with math in general... basically please keep any advice in laymen terms as much as possible. Thankspost:ask.metafilter.com,2007:site.79252Fri, 21 Dec 2007 13:52:56 -0800DetonatedManiacstatisticsdicegamesprobabilitymathoddsprogramsformulasexcelBy: aubilenon
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176570
For sort of complex stuff like this the easiest way to do it is to run a simulation, and actually roll X dice 5000 times and see how many times you can meet whatever criteria. Divide that by 5000 and that's very close to your probability.<br>
<br>
If you aren't a programmer, this might be a good project to learn python or something for. It shouldn't be very difficult.comment:ask.metafilter.com,2007:site.79252-1176570Fri, 21 Dec 2007 14:01:37 -0800aubilenonBy: geoff.
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176580
What you're looking for is the Monte Carlo method. The computer takes the underlying probabilities and then runs it an ungodly amount of times. It is sort of like cheating, and it has problems outside of physical processes.<br>
<br>
Regardless, there's a lot of data out there on how to implement Monte Carlo in practically any language or program that could support it.<br>
<br>
In any case you should get a shape of the probability distribution for what you're looking for.comment:ask.metafilter.com,2007:site.79252-1176580Fri, 21 Dec 2007 14:20:59 -0800geoff.By: mphuie
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176661
Excel plus the rand() / randbetween() function?comment:ask.metafilter.com,2007:site.79252-1176661Fri, 21 Dec 2007 15:30:02 -0800mphuieBy: plant
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176745
I haven't looked too closely at how it, and it seems like it'd have a bit of a learning curve, but you can probably make <a href="http://www.semistable.com/dicelab/">dicelab</a> give you the answers you want.comment:ask.metafilter.com,2007:site.79252-1176745Fri, 21 Dec 2007 17:01:01 -0800plantBy: Ian A.T.
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176910
I'm sure you'll get some great answers here, but you might want to try cross-posting this on Board Game Geek's Game Designer forums. The people on there literally spend hours a day thinking and writing about stuff like this, and giving them this question would be a wonderful Christmas gift that would appreciate with gusto.comment:ask.metafilter.com,2007:site.79252-1176910Fri, 21 Dec 2007 21:08:25 -0800Ian A.T.By: devilsbrigade
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176990
The proper way to do (1) and (3) is with combinatorics, some set theory, and the axioms of probability. The distributions in (2) will depend on how many times you roll the dice, but it'll end up being normal by the central limit theorem, for n > 30. <br>
<br>
The easy way to do all of this is to download R, which is a statistics programming language. There are plenty of R tutorials floating around. You can use a discrete uniform distribution to model dice (your sample space is {1,2,3,4,5,6} all with p = 1/6). R will let you generate as many random trials as you want, manipulate them however you want, and then print up a nice little histogram with everything you ever wanted to know.comment:ask.metafilter.com,2007:site.79252-1176990Sat, 22 Dec 2007 00:27:27 -0800devilsbrigadeBy: devilsbrigade
http://ask.metafilter.com/79252/complex-dice-probability-make-head-esplode#1176992
Slight correction: that sample space is for one die. If you're just doing sums, you can define your sample space as {2,3,4,5,6,7,8,9,10,11,12}, in which case it would no longer be uniform (there are multiple ways to sum to 6, but not to sum to 2). YYou may also find it easier to work with a sample space more like {{1,1},{1,2},{1,3}....{6,6}}, which will let you be more flexible. R does all of these things.comment:ask.metafilter.com,2007:site.79252-1176992Sat, 22 Dec 2007 00:30:45 -0800devilsbrigade