Welcome Guest
( Log In | Register )
The time is now 7:27 am
You last visited January 18, 2017, 7:04 am
All times shown are
Eastern Time (GMT-5:00)

toying with excel's TIMER in VBA

Published:

interesting little experiment, works just like VB6 in that a call to RND(-1) always starts you at the same place in the list, brings up some interesting questions...

1.) does their RNG continue along the same path (no RNG(-1) call)?

2.) does the date play a factor?< RANDOMIZE(NOW()) vs. RANDOMIZE(TIMER) >

3.) are they using hardware sources for entropy or does the state's choice of COBOL as a programming language play any type of contributing factor?

I whipped up a userForm to play with the RNG in excel a bit. clicking the button initialized a variable to TIMER, printed it in a textbox, printed contents of (NOW()) in a second text box, and finally did another variable as TIMER and printed out the results in a third text box... just to see the amount of time it takes to perform the calculations.

they (microsoft) say that TIMER returns a single precision number that counts the number of seconds elapsed since midnight...

by program output, right now, TIMER = 75538.98 (9:00 PM)

by calculation, 9:00 PM in seconds since midnight = 76000 (guess I pushed GO a bit quick, but it is in the ballpark)

PA begins the RNG festivities at "approximately 1:10 PM" (results not till 1:35PM, and are first fed into an animation program... I don't like the intermediate step there)

1:10 PM = 47400 seconds since midnight, hence TIMER = approx. 47400.00

so I guess the first step is to run a "seed sweep", looking for values for RANDOMIZE that will produce an INT ((10-1+1)*RND+1) = chosen result first digit of the mid-day game (or INT((1000-1+1)*RND+1) for pick 3 at once and INT((10000-1+1)*RND+1) for pick4 at once.)................ and now I have a central number to begin with... 47400  ;-)

now, how far to go to hit "approximately 1:10PM"? 5 minute window? 10 minute window? and at what interval? .01 seconds? .001 seconds?

then, does the list need to be reset with each iteration?

first I will list a few numbers, try to match by seed sweep, which seeds (if any) can correctly pick a few in a row WITHOUT the RND(-1) call at the start. Now, how many draws? back 10? 100? 1,000? all of 'em?

so many questions, and the only answers will be empirical...

Entry #77

Comments

1.
jordi mareyComment by jordi marey - November 26, 2005, 4:01 am
uuuuhhhmmmm...impressive. can you now, write a synops for the uninitiated Layperson.
I read what you did, know what your ultimate intention is (winning some state lottery)

Fascinated,

Jordi
2.
hypersoniqComment by hypersoniq - November 26, 2005, 10:11 am
the 411
-state is using a computer to pick mid-day 3 and 4 digit using a random number generator
-randomness is not really random on a computer (unless expensive outboard hardware is used)
-I have a random number generator built into excel, by understanding it isn't truly random, one can manipulate the results of the RNG, since the "random number" is really a big pre-determined list of numbers between 0 and 1, and the "seed" determines your entry point onto that list.
-I want to see if I can make excel duplicate their results, and while doing so, extract which values of the seed produce those results... then, by studying the list of seeds that work, write a program that can go one draw beyond the history... this, in theory, should equal their next draw before it happens.
-TIMER is just one method used to set a seed for the RNG. by knowing the value of TIMER at around the time they do the draw, I have a starting point in the search for a seed.
3.
jordi mareyComment by jordi marey - November 26, 2005, 1:35 pm
o.k., at least I am now on the same page.

thanks for everything.

You must be a Lottery Post member to post comments to a Blog.

Register for a FREE membership, or if you're already a member please Log In.