![MontePRNG](https://potontheriver.wordpress.com/wp-content/uploads/2013/07/monteprng.png?w=869)
PRNG = Program Random Number Generated or Pseudo Random (Machine Generated).
Creating the Deck Creator basically requires using the random function in Excel while making sure that no numbers repeat in a deck. The numbers (1 to 52) are then given Card Names and these are then written out to the Excel Sheet as a string in a one cell.
To ensure that the same deck is not used more than once during the BI phase, each deck is assigned its own GUID. Duplicate Decks, if any, can then be removed at a later stage. I will add a Check For Duplicates function later. I add this only as a precaution against duplicate information.
Note that, although the deal is random, it is still possible to have duplicate decks. This is scarce, 8.0658X10^67 scarce or 1 in 8 undecillion vigontillion scarce, but normal. Why scarce? There are 80,658,175,170,943,878,571,660,636,856,403,766,975,289,505,440,883,277,824,000,000,000,000 Shuffling Combinations for a 52 Card Deck (52!, factorial notation). It is highly unlikely to pick a random deck more than once with that amount of combinations. Sometimes you feel that the same deck have been dealt again while playing online poker. It may just seem similar since only the first 26 cards of the deck is used in 9 handed play.
On my Intel i7, 8GB, 64bit, 2.2 GHz Laptop it took:
Note on TRNG: If you think 1 ½ Hours is long you’d be surprised to know that it took me more than 5 full days previously getting it online from http://qrng.anu.edu.au/API/jsonI.php?length=1024&type=hex16&size=1. You can read more about that in the next post Deck Creator (TRNG).
21 July 2013
None of us knows everything there is to know about any one subject. There is always people who can help with improving the way we do things. My code was very cumbersome in creating decks. Stephen Dunn from Michael Marin’s Blog – The Ultimate Poker Challenge pointed that out to me. Using VBA’s Collection capability I managed to save nearly an hour on TRNG and 6 minutes on creating 1 Million PRNG Decks. Thanks Stephen.
This image below is a representation of what the Deck Creator looks like. As we progress, the filename will change to something more appropriate. The Ribbon in the Excel Workbook currently shows buttons for the Deck Creator in the Rabbit Hunting TAB. More Buttons/Groups/TABs will be added to the Ribbon Bar as more functionality is developed; Hand Analysis, Statistics (BI), Practice Play, Real Play (PokerStars), Replay Hand History, etc.
The code for the Deck Creator does not include the Custom Tab in the Ribbon. Should you require the Excel Workbook for the Deck Creator you will need to request it via email.
![DeckCreator](https://potontheriver.wordpress.com/wp-content/uploads/2013/07/deckcreator1.png?w=300&h=219)
Click on image for a bigger picture
The content of this blog is free for personal use ONLY. It cannot be used, adapted, copied, or published or used commercially or otherwise without my permission.