math people: I need your help!

Mundane & Pointless Stuff I Must Share: The Off Topic Forum

Moderator: Moderators

Post Reply
MrWaeseL
Duke
Posts: 1249
Joined: Fri Mar 07, 2008 7:54 pm

math people: I need your help!

Post by MrWaeseL »

On another board I visit, a poster asked for help on a problem of chance:

guy wrote:What I need to know is this:
What are the odds of a success when using this die sequence?

First roll a d4, whatever number you result in from that roll write down. You then need to roll that number or higher on a d6. Then roll the result or higher on a d8, d12, and d20 as before.

If possible, I would like to know the odds of success for the entire series and the odds of success if you omit the d4; the d4 and d6; the d4, d6, and d8; and omitting the d4, d6, d8, and d12.


I couldn't figure it out and since I don't know any math forums I thought I'd ask it here.

Now, as I see it this is a function dependant on 5 variables (the rolls for each type of die) where each variable has to be higher than the last. Is there a way to calculate this properly without going through all 46080 combinations to see which are successes and which aren't?
User avatar
Josh_Kablack
King
Posts: 5318
Joined: Fri Mar 07, 2008 7:54 pm
Location: Online. duh

Re: math people: I need your help!

Post by Josh_Kablack »

MrWaeseL at [unixtime wrote:1110378816[/unixtime]]On another board I visit, a poster asked for help on a problem of chance:

guy wrote:What I need to know is this:
What are the odds of a success when using this die sequence?

First roll a d4, whatever number you result in from that roll write down. You then need to roll that number or higher on a d6. Then roll the result or higher on a d8, d12, and d20 as before.

If possible, I would like to know the odds of success for the entire series and the odds of success if you omit the d4; the d4 and d6; the d4, d6, and d8; and omitting the d4, d6, d8, and d12.


I am totally unclear as to what the actual question here is. But it seems to be small enough that we can largely use lisitings of possiblities in the sample space to solve it:

# on d4 1
chance of rolling equal or higher on d6: 6/6

#on d4 2
chance of rolling eqaul or higher on d6: 5/6

#on d4 3
chance of rolling equal or higher on d6: 4/6

#on d4 4
chance of rolling equal of higher on d6: 3/6

overall chance of rolling higher on d6 than on prior roll on d4: 18/24

# on d4 1
chance of rolling equal or higher on d8: 8/8

#on d4 2
chance of rolling eqaul or higher on d6: 7/8

#on d4 3
chance of rolling equal or higher on d6: 6/8

#on d4 4
chance of rolling equal or higher on d6: 5/8
overall chance of rolling equal or higher on d8 than on a prior roll on a d4: 26/32

now, I'm going to state a general hypothesis: the overall chance of rolling equal or higher on a second die of size B than on a prior roll on a die of size A, (where B >=A, and each die is numbered with succesive positive integers can be represented as

(B) + (B-1) + (B-2).......(B-A+1)] / A*B

Now what I'm unclear about is wheather the question is asking if each sucessive roll just has to beat the initial d4 roll, or whether each successive roll has to beat the imeddiately preceeding roll which had to beat the roll which preceeded it and so forth. I'm also unclear if success is determined solely by beating the initial die on all dice involved, or whether partial successes matter or not
"But transportation issues are social-justice issues. The toll of bad transit policies and worse infrastructure—trains and buses that don’t run well and badly serve low-income neighborhoods, vehicular traffic that pollutes the environment and endangers the lives of cyclists and pedestrians—is borne disproportionately by black and brown communities."
Username17
Serious Badass
Posts: 29894
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Username17 »

I think he means that the next die has to roll higher than the current die. In which case, your thingy would look a bit more like:

Code: Select all

[br]5/6 + 4/6 + 3/6 + 2/6[br]-----------------------[br]         4


So your chances of "beating" the d4 on the d6 is 7/12.

Your chances in the abstract of beating the 6 on the d8 is similarly 9/16.

In general it's going to be (N*(N-1)-1)/N/(N-2) in which N is the larger die (for dies size d4-d12, obviously we'd have to adjust the numbers for using the d20). But of course, it's also just (N+1)/(2N) for those dice. So the chances of beating a d8 on a d10 is 11/20, the chances of beating a d10 on a d12 is 13/24.

But your chances of beating each of the dice in succession is worse than that - because the 1 oin the d6 has no chance of having beaten the d4. So you can't just multiply the chances together.

So your chances of rolling a d8 that beats a d6 that itself beats a d4 is multiplying the chances for each number. So it looks like this:

Code: Select all

[br]1/4*6/8 + 2/4*5/8 + 3/4*4/8 + 4/4*3/8 + 4/4*2/8[br]-----------------------------------------[br]                        6

Which is 1/4.

So basically I would say that the chances of successively beating each of the dice is "really small". After just two attempts it falls to 1/4 (when both of the individual pieces was better than 1/2).

-Username17
Tae_Kwon_Dan
Journeyman
Posts: 169
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Tae_Kwon_Dan »

A guy in my group is an actuary. I'll put him on this when he gets back into town.
User3
Prince
Posts: 3974
Joined: Thu Jan 01, 1970 12:00 am

Re: math people: I need your help!

Post by User3 »

all dice: 16.84027777777778 %
d6 to d20: 26.93576388888889 %
d8 to d20: 46.25 %
d12 to d20: 72.5 %

Ahhh... QBASIC :)

Code: Select all

FOR d4 = 1 TO 4[br] FOR d6 = 1 TO 6[br]  FOR d8 = 1 TO 8[br]   FOR d12 = 1 TO 12[br]    FOR d20 = 1 TO 20[br]     IF d4 <= d6 AND d6 <= d8 AND d8 <= d12 AND d12 <= d20 THEN LET i = i + 1[br]    NEXT d20[br]   NEXT d12[br]  NEXT d8[br] NEXT d6[br]NEXT d4[br][br]PRINT "all dice:"; i * 100 / 46080; "%"[br][br]LET i = 0[br][br]FOR d6 = 1 TO 6[br] FOR d8 = 1 TO 8[br]  FOR d12 = 1 TO 12[br]   FOR d20 = 1 TO 20[br]    IF d6 <= d8 AND d8 <= d12 AND d12 <= d20 THEN LET i = i + 1[br]   NEXT d20[br]  NEXT d12[br] NEXT d8[br]NEXT d6[br][br]PRINT "d6 to d20:"; i * 100 / (46080 / 4); "%"[br][br][br]LET i = 0[br][br]FOR d8 = 1 TO 8[br] FOR d12 = 1 TO 12[br]  FOR d20 = 1 TO 20[br]   IF d8 <= d12 AND d12 <= d20 THEN LET i = i + 1[br]  NEXT d20[br] NEXT d12[br]NEXT d8[br][br]PRINT "d8 to d20:"; i * 100 / (46080 / 24); "%"[br][br]LET i = 0[br][br]FOR d12 = 1 TO 12[br] FOR d20 = 1 TO 20[br]  IF d12 <= d20 THEN LET i = i + 1[br] NEXT d20[br]NEXT d12[br][br]PRINT "d12 to d20:"; i * 100 / (46080 / (24 * 8)); "%"[br]
Aycarus
Journeyman
Posts: 110
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Aycarus »

Just wanted to add something to what Frank said... The general relation for two comparable dice is:

Pr(dM>dN) = (2M-N-1)/(2*M) assuming M > N

Pr(dM>dN) = (M-1)/(2*N) assuming M < N

So for M=6, N=4 you get 7/12 as demonstrated

You'll notice that these equations are equivilant if M = N
MrWaeseL
Duke
Posts: 1249
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by MrWaeseL »

Guest (Unregistered) at [unixtime wrote:1112745611[/unixtime]]all dice: 16.84027777777778 %


Thanks fwib.

So the chance is about 1 in 6? That's higher than I thought.
Username17
Serious Badass
Posts: 29894
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Username17 »

It's higher than I would have thought too. And by that I mean that the reported chances for the d20 to beat the d12 are 72.5%, and the actual chances are 67.5%.

The d20 automaticaly wins if it rolls 13 or higher, and then the remaining 12 numbers win 11/12 through 0/12 respectively. So that's 8/20*1 + 12/20*11/24 = 27/40.

27/40 is .675, which is significantly less than the QBASIC program would indicate. I don't know QBASIC well enough to debug the program, but I know probability well enough to see bullshit when I see it.

-Username17
Neeek
Knight-Baron
Posts: 652
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Neeek »

FrankTrollman at [unixtime wrote:1112803265[/unixtime]]

The d20 automaticaly wins if it rolls 13 or higher, and then the remaining 12 numbers win 11/12 through 0/12 respectively. So that's 8/20*1 + 12/20*11/24 = 27/40.


Not quite. (from OP) "You then need to roll that number or higher" so ties are okay, adding another 11 chances to the second half, and another 1 to the first half, or 9/20 + 11/20*5/11 = 14/20 or .7
Username17
Serious Badass
Posts: 29894
Joined: Fri Mar 07, 2008 7:54 pm

Re: math people: I need your help!

Post by Username17 »

Oh, if getting an equal number is OK, then the QBASIC program is good. It's actually 9/20*1+11/20*6/12 = 72.5%, as reported.

-Username17
Post Reply