February 18th, 2011 at 6:13:06 AM
permalink
How does the wizard calculate the resulting combinations/permutations?
for example: https://wizardofodds.com/caribbeanstud
For any 10 card combination (5 for player, 5 for dealer):
there is 52*51*50*49*48 * 47*46*45*44*43*42 permutations. That's like 1 followed by 15 zeros?
surely a computer cannot generate that many, and work out what happens? That would take years?
for example: https://wizardofodds.com/caribbeanstud
For any 10 card combination (5 for player, 5 for dealer):
there is 52*51*50*49*48 * 47*46*45*44*43*42 permutations. That's like 1 followed by 15 zeros?
surely a computer cannot generate that many, and work out what happens? That would take years?
February 18th, 2011 at 6:39:21 AM
permalink
Brute force gives combin(52,5)*combin(47,6) = 27906522724080
However, one could start with the 134460 distinct starting hands for the player (using equivalence classes obtained by permuting the suits), in which case there are:
134460*combin(47,6) = 1443774065580.
This is highly doable.
--Ms. D.
However, one could start with the 134460 distinct starting hands for the player (using equivalence classes obtained by permuting the suits), in which case there are:
134460*combin(47,6) = 1443774065580.
This is highly doable.
--Ms. D.
"Who would have thought a good little girl like you could destroy my beautiful wickedness!"
February 18th, 2011 at 7:58:19 AM
permalink
hmm 1,443,774,065,580
0.5m rounds takes 1 second on my machine. So 33 days. Suppose the wizard's computer from 10 years ago, is 10x faster than my machine today... that is still 3 days?
0.5m rounds takes 1 second on my machine. So 33 days. Suppose the wizard's computer from 10 years ago, is 10x faster than my machine today... that is still 3 days?
February 18th, 2011 at 8:01:07 AM
permalink
Quote: newbie49How does the wizard calculate the resulting combinations/permutations?
for example: https://wizardofodds.com/caribbeanstud
For any 10 card combination (5 for player, 5 for dealer):
there is 52*51*50*49*48 * 47*46*45*44*43*42 permutations. That's like 1 followed by 15 zeros?
surely a computer cannot generate that many, and work out what happens? That would take years?
Nah, not nearly that long. First, you have 11 terms, and second, you didn't take the combinations into account. I have a blackjack sim running on my notebook (not at all a high-end machine) that gets through 1M random hands per second. At that rate, you're only looking at a month and a half, but it won't take that long. There are algorithmic ways to speed things up, and you're not doing a random sim (random selection is *really* expensive compared to sequential selection / iteration). Even if you do all 52c5 * 47c5 by brute force, that's 4T combinations or so, and a good algorithm on a good computer could get through those in a few days, maybe a week or two. Not years.
"In my own case, when it seemed to me after a long illness that death was close at hand, I found no little solace in playing constantly at dice."
-- Girolamo Cardano, 1563
February 18th, 2011 at 8:04:35 AM
permalink
[edit. sorry, just reread your post]Quote: newbie49hmm 1,443,774,065,580
0.5m rounds takes 1 second on my machine. So 33 days. Suppose the wizard's computer from 10 years ago, is 10x faster than my machine today... that is still 3 days?
Look up "Catus Kev". Those libraries are easy to implement for problems like this. Mr. W. has similar.
Here is a benchmark I just ran for evaluating 5 card poker hands:
Hands evaluated: 1000000000
Total microseconds: 12957484
One billion hands in 12.96 seconds ...
77.16M hands per second ...
--Ms. D.
"Who would have thought a good little girl like you could destroy my beautiful wickedness!"
February 18th, 2011 at 8:59:02 AM
permalink
Good algorithm?Quote: MathExtremistEven if you do all 52c5 * 47c5 by brute force, that's 4T combinations or so, and a good algorithm on a good computer could get through those in a few days, maybe a week or two. Not years.
As I showed in my last post, I can do 77.16M per second (and my computer is 18 months old ...). So that gives about 100.5 hours for the full combin(52,5)*combin(47,6). I guess that's a few days ... ok.
Using the equivalence classes I pointed out in my previous post, it's about 5.2 hours to run a full cycle on Caribbean Stud.
--Ms. D.
"Who would have thought a good little girl like you could destroy my beautiful wickedness!"
February 21st, 2011 at 8:47:08 AM
permalink
ding! ding! ding! ding! ding! ...
The difference between zero and the smallest possible number? It doesn't matter; once you cross that edge, it might as well be the difference between zero and 1.
The difference between infinity and reality? They are mutually exclusive.
February 21st, 2011 at 9:50:01 AM
permalink
I think the number of combinations is a little off. The raw number of combinations is combin(52,5) * combin(47,1) * combin(46,4) = 19,933,230,517,200 (because the dealer exposes one of his cards before revealing his last 4 cards).
As mentioned, there are only 134,459 unique player hands, bringing the total number of unique combinations down to 1,031,259,520,005. It would even be possible to further simplify the number of dealer upcards, and combinations of 4 remaining cards, but the effort involved in figuring that out would significantly outweigh the benefit.
My Caribbean Stud analyzer takes less than 1 second to analyze a paytable completely and accurately. It relies on a 31MB binary data file (which took about 6 hours to populate, but only needed to be done once). If anyone is interested, I would be happy to share the technical details.
As mentioned, there are only 134,459 unique player hands, bringing the total number of unique combinations down to 1,031,259,520,005. It would even be possible to further simplify the number of dealer upcards, and combinations of 4 remaining cards, but the effort involved in figuring that out would significantly outweigh the benefit.
My Caribbean Stud analyzer takes less than 1 second to analyze a paytable completely and accurately. It relies on a 31MB binary data file (which took about 6 hours to populate, but only needed to be done once). If anyone is interested, I would be happy to share the technical details.
February 21st, 2011 at 10:06:50 AM
permalink
DJteddy should take note of this to help him analyse his Poker-For-Roulette side bet. This is pre-blaster approach discussed in his tread.
The difference between zero and the smallest possible number? It doesn't matter; once you cross that edge, it might as well be the difference between zero and 1.
The difference between infinity and reality? They are mutually exclusive.