Take the 2-minute tour ×
Computer Science Stack Exchange is a question and answer site for students, researchers and practitioners of computer science. It's 100% free, no registration required.

In a bridge game, a deck of 52 cards (13 spades , 13 clubs, 13 diamonds, 13 spades) are dealt to 4 players (13 cards each) then game starts.Game session ends after 13 tricks each having 4 cards.There are 28561 possible non repeated 4 card groups.

What is the best method of generating and storing all possible trick combinations (played according to the bridge rules just for one session) to be further processed by a computer program (i.e., data structures such as game trees, and any open source algorithms written for any computer language if any).

All resources to read to get the theory behind or any references are welcome. Thank you.

share|improve this question
3  
There are too many of them, in fact at least $13! \approx 6 \times 10^9$, which is still somewhat reasonable but probably a substantial underestimate. (I get $13!$ since at each trick, the player who leads can choose any of her remaining cards.) –  Yuval Filmus Dec 27 '12 at 13:08
2  
In the extreme case where one person has all the clubs, another all the hearts, a third all the spades, and the fourth all the diamonds, then the number of trick combinations is $(13!)^4$, even though it's trivial to figure out who wins the hand. –  Peter Shor Dec 28 '12 at 5:39
3  
This is a very vague question. What does "to be further processed" mean (and the 'best' method probably depends on it, don't you think)? In any case, have you consider looking at the papers behind GIB (the double dummy solver by Matt Ginsberg)? –  Aryabhata Dec 29 '12 at 5:09
1  
perhaps you can study bidding in Bridge hands? –  john mangual Sep 2 '13 at 14:05

1 Answer 1

If the data is really a tree graph, then maybe a Prüfer code?

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.