Wikipedia:Reference desk/Archives/Mathematics/2017 November 29
Mathematics desk | ||
---|---|---|
< November 28 | << Oct | November | Dec >> | November 30 > |
Welcome to the Wikipedia Mathematics Reference Desk Archives |
---|
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages. |
November 29
editSimple dice probability question
editOn an online forum about debugging a new computer game, someone opined that the dice were biased.
Another user reported:
"I logged 500 rolls:
1 - 17.80%
2 - 18.60%
3 - 16.20%
4 - 13.40%
5 - 17.00%
6 - 17.00%"
How likely is it that the above result shows a bias? More importantly, what is the best way to calculate this? --Guy Macon (talk) 01:39, 29 November 2017 (UTC)
- The natural way to measure the deviation is to subtract each of those percentages from 1/6, square the results, and add them. In this case, you get 0.0016.... I think that some form of the chi-squared test is the right tool. It is also possible to do this with simulated data: when I simulate the dice rolls 1000 times, I get numbers ranging from 0.0001013... to 0.008205... with median 0.001453... and 60th percentile value 0.0017253.... This fails to reject the null hypothesis of "fair dice" at any reasonable standard. --JBL (talk) 02:02, 29 November 2017 (UTC)
- Going by the approximation sigma^2=npq, #4 is just about 1 standard deviation under the mean. In practice, this amount of deviation proves nothing at all. 93.136.72.241 (talk) 02:32, 29 November 2017 (UTC)
- Right, but that's not really the question. That would be the test if you were wanting to know whether the die was specifically biased against the number 4. JBL has it right — use a Χ2 test.
- As it happens, Pearson's chi-squared test#Fairness of dice gives almost exactly this example. --Trovatore (talk) 08:58, 29 November 2017 (UTC)
- Going by the approximation sigma^2=npq, #4 is just about 1 standard deviation under the mean. In practice, this amount of deviation proves nothing at all. 93.136.72.241 (talk) 02:32, 29 November 2017 (UTC)
The reported results are x1=89, x2=93, x3=81, x4=67, x5=85, x6=85, and . The probabilities are where . They have the dirichlet distribution. They are estimated by where the mean value is and the eccentricity is . Note that so the degree of freedom is k = 6-1 = 5. The Pearson test statistics is . This Chi-squared distribution has , so . The J expression below shows that . The observations do not indicate that the die is biased.
(%:10)%~5-~+/(*:mu-%6)%mu*507%~1-mu=.506%~1+89 93 81 67 85 85 0.429046
Bo Jacoby (talk) 23:51, 29 November 2017 (UTC).
Logic: I'm looking for three formulas of propositional calculus
editeach of which can be inferred from the other two, yet not from either - of the other two - apart. HOTmag (talk) 08:53, 29 November 2017 (UTC)
- Unless I make a mental mistake, consider a&b, a&c, b&c. --Stephan Schulz (talk) 08:58, 29 November 2017 (UTC)
- I don't think that works. Suppose a∧b and b∧c are both false. Is a∧c true or false? Could be true, if b is false and a and c are true, but could be false, if a, b, and c are all false. --Trovatore (talk) 09:05, 29 November 2017 (UTC)
- You made a good start, though. Instead of "and", use "exclusive or" — a⊕b, a⊕c, b⊕c. Then (for example) a⊕c = (a⊕b)⊕(b⊕c) (because ⊕ is associative, and b⊕b cancels out). --Trovatore (talk) 09:11, 29 November 2017 (UTC)
- Did you respond to me or to Stephan? HOTmag (talk) 09:08, 29 November 2017 (UTC)
- To Stephan — that's why I fixed the indent. --Trovatore (talk) 09:12, 29 November 2017 (UTC)
- Typically, for inferences you only require that every model of the premisses is a model of the conclusion. I.e. if whenever both and evaluate to true under an interpretation, then must also be true under it. I think that is the case. What happens when one of the premisses is false is irrelevant. But I didn't have my coffee yet...--Stephan Schulz (talk) 09:14, 29 November 2017 (UTC)
- Oh, I took it to mean that the truth value of each of the three formulas could be inferred from the truth value of the other two. But your interpretation makes sense, and is probably a more literal reading of the question. --Trovatore (talk) 09:23, 29 November 2017 (UTC)
- Correct. Anyway, Stephan's interpretation was what I really meant. Thanks to both of you. HOTmag (talk) 09:39, 29 November 2017 (UTC)
- Oh, I took it to mean that the truth value of each of the three formulas could be inferred from the truth value of the other two. But your interpretation makes sense, and is probably a more literal reading of the question. --Trovatore (talk) 09:23, 29 November 2017 (UTC)
- Did you respond to me or to Stephan? HOTmag (talk) 09:08, 29 November 2017 (UTC)