A python script to generate results on rolling dice implementing a quantum number generator as source of randomness.
Go to file
pxi ef360a7759 ¯\_▐ ☯ ︿ ☯ ▐_/¯ 2023-12-11 21:57:17 +01:00
bin ¯\_▐ ☯ ︿ ☯ ▐_/¯ 2023-12-11 21:57:17 +01:00
LICENSE Initial commit 2023-12-11 20:56:03 +00:00
README.md ¯\_▐ ☯ ︿ ☯ ▐_/¯ 2023-12-11 21:57:17 +01:00

README.md

🎲 3d6 Re-roll Lowest 🆚 4d6 Drop Lowest 🎲

A python script to generate results on rolling dice implementing a quantum number generator (qrng.anu.edu) as source of randomness.

Thanks to @philvuchetich@bsd.network for the help and pointers making this work.

How to use this script

Install the random generator

pip3 install quantumrandom

Run the script

./bin/3d6rl-vs-4d6dl.py

Method Explanation

4d6DL

Roll 4 six-sided dice and drop the lowest result.

  • Using only 6 sided dice roll a set of 4 dice.
  • Remove the lowest result from the set.
  • Add the three remaining dice and note the total sum.

3d6RL

Roll 3 six-sided dice and re-roll the lowest result.

  • Using only 6 sided dice roll a set of 3 dice.
  • Re-roll the lowest dice.
  • If the result is higher keep the use this value instead.
  • Add the three dice together and note the total sum.

Thesis

The result average for both methods (4d6DL and 3d6RL) should be close, if not the same. And tend towards equality the more the two methods it are tested.

This script generates results sets using a digital version of the above mentioned methods, ideally the more sets used the closer to zero the difference should be.

Results

The results for 10.000 where 4d6DL rolled 0.20500% more than 3d6RL, using 100.000 3d6rl with 0.02133%, and finally 1.000.000 samples 4d6DL again with 0.01322% difference.

Result sample

$ ./bin/3d6rl-vs-4d6dl.py
3d6 Re-roll Lowest - 1000000 samples
Distribution (result : times)
3 : 776
4 : 3093
5 : 7667
6 : 16344
7 : 29745
8 : 47978
9 : 70516
10 : 93752
11 : 114493
12 : 128574
13 : 132726
14 : 122853
15 : 101249
16 : 72396
17 : 41686
18 : 16152
67.99701% (12239462 of 18000000).

4d6 Drop Lowest - 1000000 samples
Distribution (result : times)
3 : 813
4 : 3181
5 : 7796
6 : 16136
7 : 29519
8 : 47601
9 : 70463
10 : 93906
11 : 114615
12 : 128518
13 : 132829
14 : 123235
15 : 101007
16 : 72473
17 : 41851
18 : 16057
68.01023% (12241841 of 18000000).

4d6dl rolled more by 0.01322%