1
$\begingroup$

Assume a simplified poker deck (to cut down the # of combinations):

  • 4 suits (h, c, d, s)
  • 5 ranks (A, K, Q, 7, 2)
  • 20 cards

Assume a basic 2-player setup:

  • Hand 1 (2 cards)
  • Hand 2 (2 cards)
  • Flop (3 cards)

There are 16,279,200 combinations of the above setup: choose(20, 2) * choose(18, 2) * choose(16, 3).

Take the following combination:

  • Hand 1 = Ad, As
  • Hand 2 = Kc, Kh
  • Flop = Qd, 7s, 2c

Question: what is the most efficient way to calculate the number of combinations (within the 16,279,200) that are suit-isomorphic with this setup?

For example, the following setup is suit-isomorphic:

  • Hand 1 = As, Ac
  • Hand 2 = Kh, Kd
  • Flop = Qs, 7c, 2h

while this example is not:

  • Hand 1 = Ad, As
  • Hand 2 = Kc, Kh
  • Flop = Qc, 7s, 2d

nor is this example:

  • Hand 1 = Kc, Kh
  • Hand 2 = Ad, As
  • Flop = Qd, 7s, 2c

===Edit ... explaining what I mean by suit isomorphism===

The only isomorphic transformation allowed is one that shifts suits, not ranks. The first example failed example isn't "suit" isomorphic because f(d) isn't a one-to-one map: on the Ace in Hand 1, f(d) = d. On the Queen in the flop, f(d) = c. The second example failed because the ranks within Hand 1 and Hand 2 were swapped.

===Edit ... a more general approach to the question===

The solution shouldn't rely on a specific structure of the problem. For example, in the example I gave, the solution is 24 (i.e. the permutations of the 4 suit symbols). But what happens in the following cases.

  • I might start eliminating cards. For example, I might pull the 2c out of the deck.
  • I might not use all 4 symbols.
  • 0
    I'm not clear about what you mean by "suit isomorphic"...for example, what is the status of: Hand 1 = Ac,As; Hand 2 = Kh,Kd; Flop = Qd, 7s, 2c? And what about Hand 1 = Ac,Kh; Hand 2 =Ad,Ks; Flop = Ah, Kc, Kd?2011-05-05
  • 0
    1) Not isomorphic. Neither of the aces (which should be treated as a set ... order doesn't matter) have the same suit as the Queen. So f(d) = d and f(d) = either s or c. My understanding of isomorphism is that it is a one-to-one map, not a one-to-many.2011-05-05
  • 0
    2) Not isomorphic. The ranks are different. The only transformation allowed is on the suits (h, d, c, s).2011-05-05
  • 0
    got it; I wasn't clear if you were providing an "example" or if your examples were defining the isosmorphism...Yes, an isomorphism requires a one-to-one map, but not all one-to-one maps are isomorphic. i.e. being injective is a necessary condition for an isomorphism, but not at all sufficient.2011-05-05
  • 0
    Is isomorphism even the right term for what I'm describing? Unfortunately I have no formal math training, so the best I can understand is that I've designed some k-partite (maybe k = 4) graph but am only testing for isomorphism across one of the sets of vertices (i.e suits).2011-05-05
  • 0
    Thanks for the elaboration in your question: So, if ranks can't be changed, any combination in which hand1 fails to contain 2 aces, or hand2 fails to have 2 kings, or flop fails to have a Q, 7, and 2 are omitted from consideration/counting? Clearly, the Q's and 7's suits must differ, each one matching a suit in hand 1? Does the order of cards in a given hand/flop matter? (Are they listed in terms of 1st, 2nd (3rd) dealt, or can a hand be shuffled: e.g. hand1: Ah, As flop: Qs, 7h?) And is hand1 strictly the 1st to receive a card, flop last, ...2011-05-05
  • 0
    ...or can any one of (hand1, hand2) be two aces, the other, two kings? All these factors need to be specified, since they will affect the number of set ups matching your criteria. I can continue in an "answer"...this is getting long...but it would really help if you were to make explicit any and all restrictions, and perhaps include a sketch of your graph, indicating that you're only testing for "isomorphism" across sets of vertices (suits). Also, please clarify how you define f(d)2011-05-05
  • 0
    I read you post again, @Mike, and I see that hand1 and hand2 are not interchangable. Is hand1, then, the first hand to be dealt? I also see in your comment that the order of cards in any given hand doesn't matter. It would help, though to define f explicitly; that's the only way I can answer whether the f is an isomporphism.2011-05-05
  • 0
    Q1: Correct. Q2: Correct. Q3: Order does not matter. Qd, 7s, 2c is the same as 7s, Qd, 2c. (Q4: Can be shuffled). Q5: Hand 1 and Hand 2 cannot be swapped. Q6: In the first example (i.e. the true isomorphic one), f(d) = s, f(s) = c, f(c) = h, f(h) = d. All other examples I've put down have some failed 1:1 map. As far as a sketch: is that where I specify the vertex and edge sets? Or do I have to draw it with a program?2011-05-05
  • 0
    Got it. It's a permutation: your function, often expressed in cyclic notion e.g. (d, s, c, h), where each letter maps to the letter on the right, except for the last letter, which maps to the first, hence "cyclic". Also, note that (d,s,c,h) = (s,c,h,d) = (c,h,d,s) = (h,d,s,c). So hand1 can be Ad,As or As,Ac or Ac,Ah or Ah,Ad...a "successful" hand two will be determined entirely by where the permutation starts (leaves off) with a successful hand1...likewise, hand1 determines what will count as a successful flop...2011-05-06
  • 0
    If I understand the question, the answer is simply the number of permutations of the 4 symbols d, s, c, h, and that's 24.2011-05-06
  • 0
    Yes, it is a permutation. It doesn't have to be cyclical.2011-05-06
  • 0
    @Gerry Myerson: Correct, for this example, yes, it's 24. But I'm trying to create a general model for evaluating this in cases where it might not just be all 4 suits. Perhaps examples were the wrong way to do this.2011-05-06
  • 0
    If you have the means to create an image file of your sketch, that can be uploaded to your question (click on the image icon).2011-05-06
  • 0
    @Gerry: if seems that as defined in one of the comments: f(d) = s, f(s)=c, f(c) = h, f(h)=d. If that's the mapping, then it isn't a question of how many ways to permute 4 numbers. Of course there are 24 ways to do THAT. The examples he provides that don't match that mapping are "ruled out". The question also requires that the first hand be dealt Aces, the second, Kings...so there are other limitations, as well. From what I understand, anyway. If any permutation is permitted, just so that the cards dealt result in a permutation, then that should be clarified with additional examples.2011-05-06
  • 0
    @Mike: So Gerry raises a good point: will hand1=Ac,Ad; hand2=Kh,Ks; flop=Qc,7d,2h work? What I meant by cyclic was the notation: (a, b, c, d) denotes, in this usage, a permutation of the letters which maps a to b, b to c, c to d, d back to a. I.e., there are 24 distinct one-to-one and onto permutations/functions such that each is a map from the set of four numbers/letters to itself.2011-05-06
  • 0
    General form: (AwAx)(KyKz)(Qw7x2y), where wxyz are the 24 permtuations of the suits {h, d, c, s}. Yes, Gerry's hand works: wxyz --> cdhs.2011-05-06

1 Answers 1

3

You are asking for an orbit of a group action, where the group is the group of all permutations of the suits, and the action is the action on the setups where a permutation acts on each card individually. The orbit can just be constructed by taking the 24 possibilities and seeing which ones are "allowed" and which are different. 24 is a tiny number.

Sometimes though permuting the suits may not actually change the setup. Consider the example:

  • Hand 1: 3♣, 3♠
  • Hand 2: 3♢, 3♡
  • Flop: 2♡, 4♡, 5♡

Then the permutation that switches ♣ and ♠ but leaves ♢ and ♡ alone actually ends up leaving the setup alone: hand 1 switches the order of the two cards, but that doesn't change the hand; hand 2 and the flop stay exactly the same.

Assuming you don't throw any cards out, the number of isomorphic setups is always a divisor of 24, namely the index of the "stabilizer" of the setup (see the "orbit-stabilizer theorem").

If you start throwing out cards, then basically your problem has no structure. This is not a big problem, because 24 is a tiny number. Just try all 24 and see which are "allowed".

  • 0
    Very interesting, never even came across orbits. Quick question: by throwing out cards, do you mean (in your example) if I were to throw the 5d out, for example?2011-05-06
  • 0
    Exactly. Then if there was a 5h in the setup, you'd have to disallow a heart/diamond switch. The set of allowed permutations of the suits might no longer be a group, and then it really is honestly just checking all 24 ways, AFAIK.2011-05-06