PDA

View Full Version : Some game statistics math

Yakk
2006-12-23, 03:41 PM
E is "Expected value". Otherwise known as "average".

1.96*sqrt(V) is the statistical 95% confidence interval. In general, such a confidence interval only really works after you add up a reasonable number of random events (such as 3d6).

E(1dX) = (1+X)/2
V(1dX) = (1+X)(1-X)/12

V(1d1) = 0 (aka, +1)
V(1d2) = 3/12 = 1/4
V(1d3) = 8/12 = 2/3
V(1d4) = 15/12 = 1 & 1/4
V(1d6) = 35/12 =~ 2.9
V(1d8) = 63/12 = 5 & 1/4
V(1d10) = 99/12 = 8 & 1/4
V(1d12) = 143/12 =~ 11.9
V(1d20) = 399/12 = 33 & 1/4
V(1d100) = 9999/12 = 833 & 1/4

Both E and V are linear when you add multiple dice together. Ie:
V(2d6) = V(1d6)*2
and V(1d4+1d6-1d8) = V(1d4) + V(1d6) + V(1d8)

When you multiply dice by a constant K, E goes up by K, while V goes up by K^2.

Ie:
V(1d6 * 2) = 4 * V(1d6) > V(2d6)
E(1d6 * 2) = 2 * E(1d6) = E(2d6)

If you have a situation like "roll 1d20. On a 20, event A happens, otherwise event B happens"
E = 1/20 * E(A) + 19/20 * E(B)
V = 1/20 * V(A) + 19/20 * V(B) - 2 E(A)*E(B)*1/20 * 19/20

If the chances are different, the 1/20 and 19/20 fractions change.

So, for hit-or-miss, where B is miss, E(B) = 0 and V(B) = 0. So
E = hit_chance * E(hit)
V = hit_chance * V(hit)

For crits... well it gets more complicated. :)

magic8BALL
2006-12-25, 08:12 PM
sure, and this post on year 10 maths proves..?

Put somthing decent up there:

on 2d6 (greatsword) it is:
1/6 likely to score average of 7.
1/36 likely to score max of 12.
1/36 likely to score min of 2.

vs

on 1d12 (greataxe) it is:
1/12 likely to score max of 12.
1/12 likely to score min of 1.
THERE IS NO AVERAGE, AS EACH OUTCOME IS JUST AS LIKELY AS EACH OTHER ON ANY SINGLE DICE ROLL EVER!!!

If you have a number of dice, ydx:
the average outcome = (y/2)*(x+1)
max value = y*x
min value = y
there are also x^2 possible outcomes, with the average hapening x times, the max and min one time each.

so between 6d10 and 10d6:
6d10 rolls higher more often.
6d10 rolls lower mor often.

Its just 6d10 is more ramdom, lots of small dice is not "higher on average", it's "more likely to roll average".

Of cause, nothing beats rolling a single dice, and seeing two digets come up for damage...

danielf
2006-12-25, 08:29 PM
don't forget the Murphy's law :)

Yakk
2006-12-26, 12:40 AM
sure, and this post on year 10 maths proves..?

Put somthing decent up there:

on 2d6 (greatsword) it is:
1/6 likely to score average of 7.
1/36 likely to score max of 12.
1/36 likely to score min of 2.

That is what the variance describes.

V(2d6) = 2*V(1d6) = 70/12
V(1d12) = 143/12

Notice that the Variance on 2d6 is much smaller than the Variance on 1d12. This reflects the greater tendency towards the central when you roll 2d6 than when you roll 1d12.

vs

on 1d12 (greataxe) it is:
1/12 likely to score max of 12.
1/12 likely to score min of 1.
THERE IS NO AVERAGE, AS EACH OUTCOME IS JUST AS LIKELY AS EACH OTHER ON ANY SINGLE DICE ROLL EVER!!!

There is an average -- a mean. There is no mode. There is a median as well, which happens to equal the mean.

so between 6d10 and 10d6:
6d10 rolls higher more often.
6d10 rolls lower mor often.