dds-bridge/dds

Small cards pruning

Closed this issue · 3 comments

Hello, and thanks you so much for the great amount of work u've done.
The small algorithmic questing arised after I dived into the code.
That is about one small move per subtree. Is there any formal proof of correctness for this operation (i mean collecting subtree win-ranks and throwing all-except-one small cards away)?

Sorry I only saw this now.

With

    AJ
K        Q
    T

you can take 2 quick tricks and you only have to rely on having the A. So this can be considered to be

    Ax
x        x
    x

Any split that matches this pattern is proven to yield >= 1 trick. The lower limit is 1.

If some of the x'es are better for declarer and you have

    AQ
J        T
    K

you can take 2 tricks using only the rank of the A. This is >= 1 so there is no contradiction. (In this case you could choose to win the first trick with the K, which is an extra option, and to block the suit, but you don't have to.)

So it's clear that it can never get any worse for declarer if some of the x'es are good cards for declarer. Sometimes it gets better, but it never gets worse. For example

    Axx
KQ       -
    x

yields 1 trick. The lower limit for

    Axx
xx       -
    x

is 1 trick.

    AKQ
JT       -
    9

of course yields 3 tricks which is >= 1 trick, so the limit still holds.

The purpose of the winrank is to create a generic pattern that can be matched by more than one specific split of cards in that suit (for a given number of cards with each player). When another hand is later looked up in the transposition table, this increases the chance of a hit.

It could be that this other hand has a more demanding limit, and so the hit does not deliver a proof that the new limit can be achieved. For example, the goal for the whole hand (all four suits) is 9 tricks, but so far we have only proven that we can get >= 8 quick tricks. This does not mean that it is impossible to get 9 tricks. It just means that we have to keep looking for other hits in the transposition table with more specific holdings (perhaps better x'es for declarer). If we don't find a proof, then we have to continue the AB recursion.

Hope this helps a bit. Let me know.

I have recently seen a deal with some sort of entry squeeze, where one subtree totally ignored a spade suit minor cards, and the other tree considered 3 of spades as an additional entry.
And yes, the idea about pattern-match for suit splitting is much more clear. So is that used only as bound-constructor for quick-tricks count? Or is it correct to eliminate all-except-one small card moves at move generator?

It's only used for bounds. It's not generally correct to eliminate small cards for move generation.