CopperTop
CopperTop
Joined: Dec 28, 2017
  • Threads: 2
  • Posts: 3
September 12th, 2019 at 1:40:20 AM permalink
Some years back I found Michael's computer-generated simulated-craps dice-results data set with something like 100,000 or maybe even a million numbers in it. Unfortunately, my laptop was stolen, and now I can't find the PDF again. Does anyone know where it is online? I appreciate any help.
Wizard
Administrator
Wizard
Joined: Oct 14, 2009
  • Threads: 1223
  • Posts: 20327
Thanks for this post from:
CopperTop
September 12th, 2019 at 6:12:20 AM permalink
I forgot about that. Maybe I'll recreate it. How would you like the file laid out?
It's not whether you win or lose; it's whether or not you had a good bet.
cowboy
cowboy
Joined: Apr 22, 2013
  • Threads: 5
  • Posts: 157
September 14th, 2019 at 9:59:31 AM permalink
csv format 100 by 1000 or 1000 by 1000 would work for me.

How would it be different than using the RND function? Or different than a file from random.org? (after 1D6 plus 1D6 processing for both, that is)
Wizard
Administrator
Wizard
Joined: Oct 14, 2009
  • Threads: 1223
  • Posts: 20327
September 14th, 2019 at 11:16:58 AM permalink
Quote: cowboy

csv format 100 by 1000 or 1000 by 1000 would work for me.

How would it be different than using the RND function? Or different than a file from random.org? (after 1D6 plus 1D6 processing for both, that is)



Anything from random.org should be fine.
It's not whether you win or lose; it's whether or not you had a good bet.
MichaelBluejay
MichaelBluejay
Joined: Sep 17, 2010
  • Threads: 29
  • Posts: 774
Thanks for this post from:
LuckyPhow
September 15th, 2019 at 10:07:41 PM permalink
My site, Easy Vegas, has a Craps Rolls Generator. Let me know if you'd like the output in a different format.
7craps
7craps
Joined: Jan 23, 2010
  • Threads: 18
  • Posts: 1852
September 16th, 2019 at 11:56:56 AM permalink
I looked in my old collection of web-pdfs and did not see having a copy of the Wiz craps rolls from the OP
Quote: MichaelBluejay

My site, Easy Vegas, has a Craps Rolls Generator. Let me know if you'd like the output in a different format.

That is nice to use.

Many will not use any computer generated rolls for a craps tester (actual rolls are wanted and prefered)
as both javascript and Excel have had serious issues in the past, especially failing most all statistical 'run' tests. (already well documented)

not that this is important, you use an interesting seed method for Math.random() I have never seen B4 (except from you) as seen in some of your code.

others have a Mersenne Twister implementation in javascript (that still has some issues as JS does not use arbitrary precision, but there seems to be good work-a-rounds) that can take a seed value to be able to always use the same results for testing.
example found here: https://gist.github.com/banksean/300494

It might be worth (or might not) getting the best possible code for this - even IF it is slightly slower than Math.random()

at least you added this to your site. better than nothing at all.
winsome johnny (not Win some johnny)
MichaelBluejay
MichaelBluejay
Joined: Sep 17, 2010
  • Threads: 29
  • Posts: 774
Thanks for this post from:
CrystalMathLuckyPhow
September 16th, 2019 at 12:06:23 PM permalink
Quote: 7craps

at least you added this to your site. better than nothing at all.

It's far better than "better than nothing at all", it's in fact absolutely useful with no downsides.

Javascript used an inferior random method until 2015 when it was upgraded to Xorshift+128, which is way more than adequate for this task. If someone will accept only actual craps rolls from a casino as legitimate, the problem is their delusion, not any actual inadequacy of my generator.
charliepatrick
charliepatrick
Joined: Jun 17, 2011
  • Threads: 29
  • Posts: 1702
September 17th, 2019 at 12:03:16 PM permalink
I've had no problems with javascript and Mersenne for my sims. Although I can't be 100% sure, I tested the RNG against a few tests and most results, such as Blackjack, are close to the expected results. Due to the limitations of the size a computer/compiler can keep numbers, technically the probabilities of each roll isn't exactly 1/6.
MichaelBluejay
MichaelBluejay
Joined: Sep 17, 2010
  • Threads: 29
  • Posts: 774
Thanks for this post from:
7craps
September 17th, 2019 at 12:38:35 PM permalink
A sim of a game could return the expected result even with bad random quality. As an extreme example, if you pick random numbers from 1-100, the average should be 50.5, and a generator that picked 50.5 every time would pass the "average = 50.5" test.

Here's a good table comparing different popular algorithms.
7craps
7craps
Joined: Jan 23, 2010
  • Threads: 18
  • Posts: 1852
September 17th, 2019 at 12:52:06 PM permalink
Quote: MichaelBluejay

Javascript used an inferior random method until 2015 when it was upgraded to Xorshift+128, which is way more than adequate for this task.

After some reading on the subject I agree.
a problem I have come across with Xorshift+128 is the seeding or that lack of it to produce repeatable results. My readings say the browser does the initial seeding unless one writes code for it. I have not yet looked into it as I do not intend to use javascript for simulations. (never say never) But some do just that.

But seeing things like this (Xorshift+128)


makes me want to learn how to avoid duplicating those results and getting results that look more like this
.

the top photo was using a seeding method I have seen used for Math.random()
example
	die1 = Math.floor(Math.random(seed)*6)+1;
die2 = Math.floor(Math.random(seed)*6)+1;

I was under the impression that function does not take a seed. I could be wrong here too.

so much to learn if one wants to learn
winsome johnny (not Win some johnny)

  • Jump to: