United States Member #59354 March 13, 2008 4301 Posts Offline

Posted: June 9, 2010, 3:26 pm - IP Logged

Help!

My software uses a spin off of Bayes' theorem to predict the next

best choice within a lottery draw. The system that I now use worked

fine until the last couple months when it became much less able to

predict with any certainly. "Averages less than 50% when given only

two choices." I was digging out some old code and came across a much

earlier attempt that I was never able to complete. Any help would be

appreciated.

Example.

lets say that I have three filters labeled A,B,C. The sum of the

values taken from A+B+C can never go above or below five.

In 635 drawings observed, this is the outcome for each.

A Contains 20 numbers A never appeared in 16 of the draws A appeared 1 time in 73 of the draws A appeared 2 times in 201 of the draws A appeared 3 times in 205 of the draws A appeared 4 times in 124 of the draws A appeared 5 times in 16 of the draws

B Contains 9 numbers B never appeared in 162 of the draws B appeared 1 time in 278 of the draws B appeared 2 times in 159 of the draws B appeared 3 times in 30 of the draws B appeared 4 times in 6 of the draws B appeared 5 times in 0 of the draws

C Contains 10 numbers C never appeared in 133 of the draws C appeared 1 time in 267 of the draws C appeared 2 times in 178 of the draws C appeared 3 times in 52 of the draws C appeared 4 times in 5 of the draws C appeared 5 times in 0 of the draws

P(A) P(B) P(C)

P(A|B) P(A|C)

P(B|A) P(B|C)

P(C|A) P(C|B)

P(A|(B+C)) P(B|(A+C)) P(C|(A+B))

and so on ......

remember the total values taken from A, B, and C must =5

lets say that I have already drawn x number of unfiltered sets to play.

First I select the top 3 or 4 highest hitting values from each of A, B, and C and set them as hi / low ranges. This has little effect in reducing the sets as most drawings fall within this range. Narrowing the hi/low reduces sets but also reduces winners.

The Bayes filter process.

I pull the first set of numbers from my list of unfiltered sets. from this I select the first number and find that it comes from (C) which contains only 10 numbers. Next the (P's) are recalculated removing the number from (C). I repeat the process for the second number. I then begin a simple second process to determine if the numbers within the set are following my data. In the 3rd and 4th number processed the decision is made if the set should be rejected, Then the 5th number is processed and the set is given a second chance

To put simply, this process updates with each number and relies on past observations for the most probable A,B or C selection, if it fails to follow this path past the 3rd and 4th number it is rejected.

The above P(A|B) is quite simple but with all the recalculating in the many steps it becomes very complicated as each new data is used with the old.

Is this worth the effort to try again or is it a pipedream. Someone must have tried this or something similar before.

United States Member #59354 March 13, 2008 4301 Posts Offline

Posted: June 10, 2010, 2:46 pm - IP Logged

Quote: Originally posted by RL-RANDOMLOGIC on June 9, 2010

Help!

My software uses a spin off of Bayes' theorem to predict the next

best choice within a lottery draw. The system that I now use worked

fine until the last couple months when it became much less able to

predict with any certainly. "Averages less than 50% when given only

two choices." I was digging out some old code and came across a much

earlier attempt that I was never able to complete. Any help would be

appreciated.

Example.

lets say that I have three filters labeled A,B,C. The sum of the

values taken from A+B+C can never go above or below five.

In 635 drawings observed, this is the outcome for each.

A Contains 20 numbers A never appeared in 16 of the draws A appeared 1 time in 73 of the draws A appeared 2 times in 201 of the draws A appeared 3 times in 205 of the draws A appeared 4 times in 124 of the draws A appeared 5 times in 16 of the draws

B Contains 9 numbers B never appeared in 162 of the draws B appeared 1 time in 278 of the draws B appeared 2 times in 159 of the draws B appeared 3 times in 30 of the draws B appeared 4 times in 6 of the draws B appeared 5 times in 0 of the draws

C Contains 10 numbers C never appeared in 133 of the draws C appeared 1 time in 267 of the draws C appeared 2 times in 178 of the draws C appeared 3 times in 52 of the draws C appeared 4 times in 5 of the draws C appeared 5 times in 0 of the draws

P(A) P(B) P(C)

P(A|B) P(A|C)

P(B|A) P(B|C)

P(C|A) P(C|B)

P(A|(B+C)) P(B|(A+C)) P(C|(A+B))

and so on ......

remember the total values taken from A, B, and C must =5

lets say that I have already drawn x number of unfiltered sets to play.

First I select the top 3 or 4 highest hitting values from each of A, B, and C and set them as hi / low ranges. This has little effect in reducing the sets as most drawings fall within this range. Narrowing the hi/low reduces sets but also reduces winners.

The Bayes filter process.

I pull the first set of numbers from my list of unfiltered sets. from this I select the first number and find that it comes from (C) which contains only 10 numbers. Next the (P's) are recalculated removing the number from (C). I repeat the process for the second number. I then begin a simple second process to determine if the numbers within the set are following my data. In the 3rd and 4th number processed the decision is made if the set should be rejected, Then the 5th number is processed and the set is given a second chance

To put simply, this process updates with each number and relies on past observations for the most probable A,B or C selection, if it fails to follow this path past the 3rd and 4th number it is rejected.

The above P(A|B) is quite simple but with all the recalculating in the many steps it becomes very complicated as each new data is used with the old.

Is this worth the effort to try again or is it a pipedream. Someone must have tried this or something similar before.

Thanks RL

Another attemp to explain

5-39 lottery

5 balls are drawn of 39 possible

first the probability for each of the 5 draw numbers is calculated "no history"

5 in 39 1st number drawn

4 in 38

3 in 37

2 in 36

1 in 35 5th number drawn

next using past draw history the probability for each of the 39 balls to hit in the next draw is calculated

next the balls are sorted into 3 strings of numbers

string A=20 "all mixed digit numbers like "09-18-23....." numbers formed of one odd and one even digit

string C=9 "all double even digit numbers "02-04-22....." numbers formed of two even digits

string C=10 "all double odd digit numbers 11-19-35....." numbers formed of two odd digits

A never appeared in 16 of the draws A appeared 1 time in 73 of the draws A appeared 2 times in 201 of the draws A appeared 3 times in 205 of the draws A appeared 4 times in 124 of the draws A appeared 5 times in 16 of the draws

B Contains 9 numbers B never appeared in 133 of the draws B appeared 1 time in 267 of the draws B appeared 2 times in 178 of the draws B appeared 3 times in 52 of the draws B appeared 4 times in 5 of the draws B appeared 5 times in 0 of the draws

C Contains 10 numbers C never appeared in 162 of the draws C appeared 1 time in 278 of the draws C appeared 2 times in 159 of the draws C appeared 3 times in 30 of the draws C appeared 4 times in 6 of the draws C appeared 5 times in 0 of the draws

next the probabilities that the 1st number would come from A or B or C

next the probabilities that the 2nd number would come from A or B or C given 1st

next the probabilities that the 3rd number would come from A or B or C given 1st and 2nd

next the probabilities that the 4th number would come from A or B or C given 1st, 2nd and 3rd

next the probabilities that the 5th number would come from A or B or C given 1st, 2nd, 3rd and 4th

The Filter

I select the first set of 5 numbers from my playlist

I take the 1st number from the set and using the information from above, predict which string

the 2nd number will most probable come from,

I take the 2nd number from the set and using the information from above, predict which string

the 3rd number will most probable come from.

I take the 3nd number from the set and using the information from above, predict which string

the 4th number will most probable come from.

I take the 4th number from the set and using the information from above, predict which string

the 5th number will most probable come from.

I take the 5th number from the set and using all information, accept or reject the set

If you think about this you will find it "spider-webs" and begins to look a little like a nerual network

as many of the (P)'s change with every step. I did not include any of the feedback steps as this would

really make it hard to understand. I avoided using bayesian terminology in this post. reply