Ace2
Ace2
Joined: Oct 2, 2017
  • Threads: 31
  • Posts: 1984
Thanks for this post from:
camapl
September 22nd, 2022 at 12:12:44 PM permalink
Quote: MichaelBluejay

Some of us can code but aren't skilled in math.

That sounds like a very bad combination for coding probability simulations
Itís all about making that GTA
TumblingBones
TumblingBones
Joined: Dec 25, 2016
  • Threads: 29
  • Posts: 510
September 22nd, 2022 at 12:29:00 PM permalink
For simulations I've pretty much stuck with Java. One reason is that it's easy to whip up a GUI to let me control settings. Another plus with Java is that there are some good Apache libraries for statistical analysis. If you really want to get fancy you can also access Python from Java and do all sorts of plotting and analysis. When dealing with the need to do some sort of exhaustive analysis of all possible outcomes I've used C since I can optimize memory usage. Last time I did one I had 2^^18 paths to consider. It took ~20 minutes running on my desktop PC which was pretty state-of-the art at the time (2005).

As to programing back in the days of yore, FORTRAN was the 1st language I learned and used (1969 thru 1970) but then I switched to ALGOL (1971 to ~ 1976), then Assembler for various architectures, followed by C starting in 1982. There's probably about another dozen or so I've used since then but I take great satisfaction in never having learned COBOL.
My goal of being well informed conflicts with my goal of remaining sane.
TumblingBones
TumblingBones
Joined: Dec 25, 2016
  • Threads: 29
  • Posts: 510
September 22nd, 2022 at 12:34:17 PM permalink
Quote: Ace2

Quote: Talldude90


The most complicated thing i have done so far is craps, but if you are able to convert all the rules into code I don't see why it shouldn't be easy to sim anything you want in excel or any normal programming language.

Why would you need to program/simulate anything for craps? Those calculations are so easy you can do them in your head
link to original post


I wrote one to use in training an AI. I wanted to evaluate some ML optimization techniques and craps seemed like a good test case.
My goal of being well informed conflicts with my goal of remaining sane.
DRich
DRich
Joined: Jul 6, 2012
  • Threads: 80
  • Posts: 8987
September 22nd, 2022 at 2:59:28 PM permalink
Quote: TumblingBones


As to programing back in the days of yore, FORTRAN was the 1st language I learned and used (1969 thru 1970) but then I switched to ALGOL (1971 to ~ 1976), then Assembler for various architectures, followed by C starting in 1982. There's probably about another dozen or so I've used since then but I take great satisfaction in never having learned COBOL.



I was sure you were going to say you programmed in 'B'. 1982 is much earlier than I started using 'C'. Probably 1987 for me. Yes, COBOL was my second language.
Order from chaos
Talldude90
Talldude90
Joined: Aug 24, 2022
  • Threads: 6
  • Posts: 56
September 22nd, 2022 at 3:59:42 PM permalink
I get people saying FORTRAN is old and making fun of it, but to be clear, it is still the Industry Standard for MCNP (Monte Carlo N-Particle). It is that way because it is the fastest option. It IS still used today, and I graduated college in 2012 and it was a required part of my degree.
camapl
camapl
Joined: Jun 22, 2010
  • Threads: 8
  • Posts: 419
Thanks for this post from:
Mukke
September 22nd, 2022 at 4:13:29 PM permalink
Am I the only one who learned PASCAL?
* Actual results may vary.
Talldude90
Talldude90
Joined: Aug 24, 2022
  • Threads: 6
  • Posts: 56
September 22nd, 2022 at 4:22:03 PM permalink
Quote: teliot

The random number generator that comes with Excel (and is used in VBA) has a cycle of length 2^24 = 16,777,216, (as I recall), which makes VBA and Excel unusable for any large simulation of pretty much anything without programing your own RNG. Fortunately, strong long cycle RNGs are fairly easy to code.

Good on you for programming in Fortran, I used that up until about 1984 on punch cards. Sometime later I upleveled from punch cards to an ADM-5. That 300 BAUD modem was lightning fast.
link to original post



So, does this mean that it repeats itself after 1.68E7 uses? The methodology I was using had randbetween(x,x) in column A for 100k rows. I took the end results and paste-valued them which caused a re-calc each time I pasted the final result. On a couple of the sheets I did 1E6 at a time, but I preferred doing 100k at the time so I didn't have to wait on the calculating. One weird thing, the bottom of the screen said it was using 12 cores, and I couldn't do anything in Excel till it finished (a few seconds) but task manager only showed the % going up on CPU utilization to about 50%.
ChesterDog
ChesterDog
Joined: Jul 26, 2010
  • Threads: 8
  • Posts: 1047
Thanks for this post from:
MichaelBluejay
September 22nd, 2022 at 4:55:01 PM permalink
Quote: Talldude90

Quote: teliot

The random number generator that comes with Excel (and is used in VBA) has a cycle of length 2^24 = 16,777,216, (as I recall), which makes VBA and Excel unusable for any large simulation of pretty much anything without programing your own RNG. Fortunately, strong long cycle RNGs are fairly easy to code.

Good on you for programming in Fortran, I used that up until about 1984 on punch cards. Sometime later I upleveled from punch cards to an ADM-5. That 300 BAUD modem was lightning fast.
link to original post



So, does this mean that it repeats itself after 1.68E7 uses? The methodology I was using had randbetween(x,x) in column A for 100k rows. I took the end results and paste-valued them which caused a re-calc each time I pasted the final result. On a couple of the sheets I did 1E6 at a time, but I preferred doing 100k at the time so I didn't have to wait on the calculating. One weird thing, the bottom of the screen said it was using 12 cores, and I couldn't do anything in Excel till it finished (a few seconds) but task manager only showed the % going up on CPU utilization to about 50%.
link to original post



Did Microsoft improve their Excel rand() function in 2010?

See https://support.microsoft.com/en-us/office/rand-function-4cbfa695-8869-4788-8d90-021ea9f5be73
teliot
teliot
Joined: Oct 19, 2009
  • Threads: 42
  • Posts: 2391
September 22nd, 2022 at 5:04:01 PM permalink
Quote: Talldude90

So, does this mean that it repeats itself after 1.68E7 uses? The methodology I was using had randbetween(x,x) in column A for 100k rows. I took the end results and paste-valued them which caused a re-calc each time I pasted the final result. On a couple of the sheets I did 1E6 at a time, but I preferred doing 100k at the time so I didn't have to wait on the calculating. One weird thing, the bottom of the screen said it was using 12 cores, and I couldn't do anything in Excel till it finished (a few seconds) but task manager only showed the % going up on CPU utilization to about 50%.

It looks like my information is old, I used Excel 2007 until about 2015. Now Excel uses the Mersenne Twister for its RNG which is as good as you'll ever need. That said, if you are simulating any betting systems or progressions, please just stop and use your considerable intelligence in a more worthwhile fashion.

https://support.microsoft.com/en-us/office/rand-function-4cbfa695-8869-4788-8d90-021ea9f5be73
Climate Casino: https://climatecasino.net/climate-casino/
DRich
DRich
Joined: Jul 6, 2012
  • Threads: 80
  • Posts: 8987
Thanks for this post from:
camapl
September 22nd, 2022 at 5:10:11 PM permalink
Quote: camapl

Am I the only one who learned PASCAL?
link to original post



I wrote some PASCAL today.
Order from chaos

  • Jump to: