Wednesday, June 09, 2004

No, It's Not Fixed

I made a comment on someone else's site last night in response to the "Is Party Fixed" question that I thought was fairly clever, so I'll post the general gist of it here.

Like the original poster (PokerPenguin, IIRC), I dismiss(ed) the possibility that PartyPoker deliberately skews its deals toward certain players or certain types of flops. Party has a money factory as long as they have the confidence of their players. Screw with that, and they turn the money spigot off. So, I refuse to believe that Party's deals are deliberately skewed. (Plus, I win; if it's fixed, I shouldn't be able to, should I?)

Penguin then turned to the possibility of a search algorithm of some sort finding patterns in the deal, and this is where I think I came up with a clever answer. Forget the fact that Party and other sites seed their random-number generators from several sources, and it's hard enough to find the pattern in one list of random-number seeds. Consider this:

The number of possible shuffles of a deck of 52 cards is very large. Specifically, it's 52!, 52 factorial, or 52×51×50× ... ×3×2×1. To explain that, imagine a shuffle. There are 52 possibilities for the top card. Then, if the top card is known, there are 51 possibilities for the next card. Now, we know the top two cards, so there are 50 choices for the third card. And so on, until we reach the point where we know what the top 51 cards are, which leaves only one choice for the final card. The fact that we're not looking at the cards doesn't change things; after a top card is chosen it is out of circulation and there are still only 51 possibilities for the second card.

It turns out that 52! is approximately 8.066×1067, or 8066 followed by 64 zeroes. That's a lot: the total number of atoms in the entire universe isn't much higher than that (on a log scale, anyway). PartyPoker has dealt, at this writing, 662 million hands. That's a lot, I'm not saying it isn't, but that means that they've seen 0.000000000000000000000000000000000000000000000000000000000122% of the possible shuffles. I'm not exactly sure how to do this calculation, but it would seem unlikely that they've ever had the same shuffle twice. How would you find the pattern?

There are some things that would make the job slightly easier, I grant. At a 10-handed holdem table, only the top 25 cards (the burn cards are essentially irrelevant here) are actually dealt, which reduces the number of meaningful shuffles to 1.55×1025. They deal off more cards in Stud and Omaha but we'll assume for the sake of argument that all 662 million hands were holdem hands. That still means that we've seen only 0.00000000000000234% of all possible hands. Even in this case, it is highly unlikely that an algorithm would have anywhere close to enough data to be able to find a pattern in the deal.

Feel Better?


Actually it's not hard to reverse engineer a random number generator, and it's been done before with poker websites. The problem was that the random number generator was written poorly and seeded with the time.

There are various qualities of random number generators including a very special kind called cryptographically secure random number generator.

Also consider knowing all the cards isn't the only useful information. If you simply knew there was a greater chance of card X being dealt at a certain point if card Y had been dealt then you gain an advantage. If it resulted in something such as the board pairing more often than it should and you know this you gain a huge advantage over your opponents who believe their flushes are going to hold up. Even if they seem to hold up as they should if you know there's an extra % in there you can take advantage of it.

Having said that I generally think that the larger websites are pretty straight. I could scare you with stories of compilers who build back doors in to software without the programmer having to write the back door in to the source code and which will recompile the compiler to build the back door building software in to the new versions of the compiler without having to be told to so that all the source code for the back door can be destroyed, but, err, I don't want to scare the kids :)

The other thing to consider is this... ...is it any more or less rigged or corrupted than any other game? People cheat all the time at various games and even though Vegas has a pretty good track of catching them they keep catching them which means that people keep cheating others out of their money. I have trouble believing that all the private games out there are 100% clean and honest. There was the guy in vegas who rigged the chips for slot machines such that when the gaming commission tested them they passed but when you did the right thing on the machine it would hand you a payout.

  Post a Comment