Page 6 of 11

Re: dice used in catan is biased

Posted: 20 July 2024, 17:54
by Nekojin
One of humanity's distinct traits - something that some say differentiates us from animals - is that we are capable of recognizing patterns, even when none actually exist.

Re: dice used in catan is biased

Posted: 21 July 2024, 02:12
by Rufasu
Since this is not well communicated, let me give you a clear example.
What do you think when you see the following dice in a game?

6 6 6 6 3 11
6 6 6 6 3 11
6 6 6 6 3 11

If we consider only probability theory, we can say that “anything can happen.
However, those who have studied computer science think like this.
This program is making a mistake.

Re: dice used in catan is biased

Posted: 21 July 2024, 02:16
by Rufasu
Here are some references on programming with random numbers.
Techniques of Computer Programming, Volume 2.

Re: dice used in catan is biased

Posted: 21 July 2024, 04:18
by twsansbury
With a background in computer science, I can confidently affirm that the sample set in the example is too small to determine if the generator is random or not random. For those interested in understanding the complexity of proving or disproving randomness, see NIST SP 800-22, A Statistical Test Suite for Random and Pseudorandom Number.

Re: dice used in catan is biased

Posted: 21 July 2024, 04:37
by Suoivax
Rufasu wrote: 21 July 2024, 02:12 Since this is not well communicated, let me give you a clear example.
What do you think when you see the following dice in a game?

6 6 6 6 3 11
6 6 6 6 3 11
6 6 6 6 3 11

If we consider only probability theory, we can say that “anything can happen.
However, those who have studied computer science think like this.
This program is making a mistake.
A sample set of 21 proves nothing though.

Re: dice used in catan is biased

Posted: 21 July 2024, 09:09
by Gulchen
Suoivax wrote: 21 July 2024, 04:37
Rufasu wrote: 21 July 2024, 02:12 Since this is not well communicated, let me give you a clear example.
What do you think when you see the following dice in a game?

6 6 6 6 3 11
6 6 6 6 3 11
6 6 6 6 3 11

If we consider only probability theory, we can say that “anything can happen.
However, those who have studied computer science think like this.
This program is making a mistake.
A sample set of 21 proves nothing though.
Do you mean 18?

Re: dice used in catan is biased

Posted: 21 July 2024, 09:28
by euklid314
Rufasu wrote: 21 July 2024, 02:12 Since this is not well communicated, let me give you a clear example.
What do you think when you see the following dice in a game?

6 6 6 6 3 11
6 6 6 6 3 11
6 6 6 6 3 11

If we consider only probability theory, we can say that “anything can happen.
However, those who have studied computer science think like this.
This program is making a mistake.
If the PHP function random_int() which is cryptographically secure and is used at BGA (read the FAQ) gives this 18-number sequence one can safely assume that this program is not making a mistake. This pattern will not repeat the next 100 rolls.

It is completely normal to see such short patterns within random sequences since there are millions of possible patterns that the human brain can identify.

If you are a programmer you can test all your hypotheses with the RNG random_int().

Re: dice used in catan is biased

Posted: 21 July 2024, 12:35
by Suoivax
Gulchen wrote: 21 July 2024, 09:09
Suoivax wrote: 21 July 2024, 04:37
Rufasu wrote: 21 July 2024, 02:12 Since this is not well communicated, let me give you a clear example.
What do you think when you see the following dice in a game?

6 6 6 6 3 11
6 6 6 6 3 11
6 6 6 6 3 11

If we consider only probability theory, we can say that “anything can happen.
However, those who have studied computer science think like this.
This program is making a mistake.
A sample set of 21 proves nothing though.
Do you mean 18?
i guess that depends on if those are ones or elevens. Although to be fair there are no ones in Catan.

Re: dice used in catan is biased

Posted: 26 July 2024, 06:03
by Rufasu
I question the attitude that anything is possible if the odds are high.
It is now faith.
If you are a programmer, you should think of a better program.
They should consider whether their use of PHP functions is correct.
Some people are not satisfied with the random number function of the PHP library and have implemented their own random number algorithm.
I must say that this is unprofessional.

Re: dice used in catan is biased

Posted: 27 July 2024, 08:20
by Nekojin
Rufasu wrote: 26 July 2024, 06:03 I question the attitude that anything is possible if the odds are high.
It is now faith.
If you are a programmer, you should think of a better program.
They should consider whether their use of PHP functions is correct.
Some people are not satisfied with the random number function of the PHP library and have implemented their own random number algorithm.
I must say that this is unprofessional.
This is nonsense. The actual code has been shown to you. If you have any programming skill, you can go examine it yourself. Or do actual, properly-managed scientific testing of its results. If you can actually find a flaw, and report it accurately, programmers everywhere who use this code will be very grateful to you and your work.

But that's hard work. Complaining that you think it's broken is easy - that doesn't require proof or evidence. Just an opinion, and a willingness to (ab)use it.

Telling programmers that they need to do better when there's no evidence that there's actually anything wrong is insulting. And this is not "faith." It's reality. You want to take a tiny snippet of data and use that as your foundation for a claim that there's something wrong. But in making these claims, you're exposing your own ignorance. You don't understand probability. Just like that guy who went and wrote code that made every 36 rolls have every possible roll show up exactly once each - that's not random. That's not how any of this works.