Cake
• There are many card games that allow you to build your own deck and then play it against opponents that did the same. Magic the Gathering might be the most familiar one for many people, but I'd also like to mention Eternal as a digital variant of it (if only because I'm playing it myself).

The rules for these games often put some restrictions on how you are allowed to build a legal deck. In Eternal, for example, decks must consist of at least 75 cards and at least 1/3 of it must be power cards. The rest then will be units, spells and weapons, basically the meat of the matter.

Now, in theory your deck could contain more cards than that. Choose 60 non-power cards, add 30 power cards for a total of 90 cards, and your deck is still legal according to the rules. However, ask people what size a deck should have, and they will tell you that it definitely needs to be exactly 75, and that every card on top of that will make your deck worse because doing so reduces your win probability. Some will consider you insane for even thinking about adding just a single card more than absolutely necessary. When asked for an explanation for this, it will often go something like this:

(a) Assume that all the cards in your deck have some value. Some will be more important to the strategy you are trying to play, while others are less important.

(b) Sort all cards according to this assumed value in descending order. There will be a "least important card" at the end of that list.

(c) Assume that you are playing your (oversized by one card) deck, and that at some point in the game, you draw the card you determined to be the least important one.

(d) Consider what would happen instead if that card had been removed from your deck before playing. You would have drawn a card that you determined to be more valuable instead. This means that it is better to play without that card in the first place.

Now, the general idea is definitely sound - but I still wonder if it isn't a bit too simplistic when it comes to actual gameplay instead of just theory:

First, consider that most games are over before maybe a third of the deck has been drawn. The "least important card" has a good chance of not entering play at all. This isn't a counterargument to the idea itself, but already lessens its impact to a fraction.

Second, consider the fact that the value of a card might depend not only on your own strategy, but also on that of the opponent. Perhaps card A will be valuable to you in one half of all games, and card B in the other half. In combination with a card that says

Choose which card you want to draw next turn.

it might be useful to play a copy of both A and B, and not choose between them. Of course, a counterargument to that could be that, perhaps, neither A nor B is the "least important card" in that case - but I feel this already muddies the waters a bit.

Most importantly, though: the whole idea of card games like these is that its individual cards don't exist in a vacuum, but have synergies with each other. For example, if there's one card that says

Use an enemy unit as your own this turn.

And another card that says

Kill one of your own units to gain a bit of power.

then both of these cards might be mediocre on their own, and not worth playing compared to other cards. However, in combination it means that you can steal an opponent unit, attack with that unit to do some damage - and then, if it survives because the opponent thinks he'll get the unit back after the turn, you can remove it from play to gain some additional benefit.

Depending on what synergies there are in the game, it might be worth playing some more cards to have access to more of these effects.

What I'm looking for - and this is why I also added the "mathematics" topic to this post - is a way to put all of this in proper stochastic terminology without shortcuts like "assume this, assume that", to eventually find out if having some more cards is really that bad. Is anyone interested in discussing this?

• > Is anyone interested in discussing this?

Ooh yes please lets dig in! I haven't played Eternal myself, but I have played MTG as well as Hearthstone and a few other deck building games. It's interesting that Eternal is a 75 minimum card deck, that seems enormous after playing hearthstone (which required exactly 30 cards, no more no less, and no specific composition).

Something that might be helpful first is to classify which types of deck-building card games we are talking about. There are a few main types that come to mind for me:

Mana-Curve Games: This would include MTG, Eternal, and Hearthstone. Games where you have some ascending set of resources that allow you to play more powerful cards or more less powerful cards as the game progresses. You also start with a static set of cards.

Static Resource Games: Tabletop games like Dominion (I can't think of any others ATM). These are games where your resources each turn are defined by something static, like the ability to draw 1 card, and play 1 card (with the potential to gain the ability to play more cards with a given card). I mention these because they are often simpler and may be easier to start analyzing.

Asymmetric Games: Games like Android: Netrunner where there are all kinds of wonky things going on depending on which side you are on. Similar to Warhammer or something like that. We probably don't want to talk about these.

That being said, it sounds like you'd like to discuss Mana-Curve Games. I think there are probably a few terms we might want to consider:

Card Value: This is difficult to define for Mana-Curve games, especially with synergy. Taking synergy out of the equation, you could simplify down to something like card power / mana cost. Adding synergy back in, this may actually be a function of the other cards in the deck.

Deck Size: Number of cards in the deck.

Average Card Value: Just Card Value / Deck Size.

Draw Potential: Based on the cards I have left in the deck, what is the card value I am likely to draw. This would be Average Card Value of the remaining deck.

Draw Depth: What percentage of the deck am I likely to go through over the course of the game. You mentioned that Eternal is often about 30% of a deck. For Hearthstone it is probably upwards of 60%.

Key Cards: These are the cards that the deck is built around. In Hearthstone where the Draw Depth is high, this can often be as few as 2 or 3 cards with everything built up around them.

I think the steps you listed above are explaining how adding an additional card of lower Card Value reduces the Average Card Value of your deck, therefore reducing your Draw Potential over the course of the game.

I need to run now, have more thoughts to give later.

• @Eric Thanks, those are some good initial definitions allowing us to better talk about this. While reading, I had some random thoughts that I'd like to put down here - with more coming later:

Static Resource vs. Mana-Curve Games: As if it wasn't complicated enough already, I think this is a spectrum instead of just two mutually exclusive categories. ;)

In case of Eternal, there's ascending resources (1. Power, which you can typically increase by 1/turn, but you might either miss a card draw allowing you to do so, or draw a card that allows you to increase by more than that; 2. Influence, which you don't spend like Power, but still need to amass to be allowed to play cards of a certain color in the first place).

On the other hand, there's also a more static aspect of generally one card drawn at the start of a turn (of course, this also can be increased by cards - but which, like everything else, might come with a downside in other regards).

So it's more of a Mana-Curve than a Static Resource game, but not in an absolute way.

Draw Depth: I will admit that this 30% value is just my intuition, not something I've really researched. Players will start by drawing a hand of seven cards, then typically draw an additional card per turn (unless they play a card allowing them to draw more). Games often end before either player has reached 10 power - so 7 + 10 + some wiggle room might just amount to 25 cards, or a third of the deck.

Of course, there are game strategies to explicitly gain access to more cards in less turns - for example cards that allow you to draw +1 card next turn (or every turn until the opponent attacked you for X damage), or draw 2 right now but immediately discard one, or check the topmost card of the draw pile and choose whether to keep it there or move it to the bottom of the pile.

This strategy of course comes at a cost as well: Spending power on drawing cards means that you have less power to spend on playing them at the same time. This is related to the categorization of a deck as aggro (plays many cards with small value, fast), control (plays slow to eventually get a few cards with huge value) or mid-range (something between these extremes).

Last but not least, Card Value: This really is the core of the problem, I think. Trying to understand each card on its own is basically asking

What would this card do if I put it in a deck of completely random cards?

If we're doing that, then there seems to be a good correlation between this Card Value (random) and the power/influence requirements of a card.

What combination of 75+ cards maximizes the average card value, considering that each individual card value is a function that depends on all other cards in the deck?

Expressed as a sort of pseudo-code, we have

`deck_value(deck:Card[]) { return sum of card_value(deck[i],deck) over all i }`
`card_value(card:Card,deck:Card[]) { return the adjusted value of card if played in deck }`

and (getting back to the original question) we would need to show that if we have a deck_big (a deck bigger than necessary), there's guaranteed to be a deck_small with a better deck_value constructed by removing one or more cards from deck_big.

• One thing I need to add is that these game (Eternal, Magic as well I think) allow you to have up to four copies of the same card in your deck.

If a card is a Key Card, you will try to have it four times to make it more likely to draw. If it is not, it might work better with just three or even two copies in the deck.

• Thinking about this more, I think I may have attempted to simplify Card Value (CV)a bit too much, and that is really the crux of the issue. I think I need to define a few more terms

Hand: H, what is currently in my hand. This will drastically affect the value of other cards remaining in the deck. For example if I already have some key cards, it may be less important to draw more.

Intrinsic Card Value: IV, the value that the card has on its own without any synergy. This would typically be high for most cards in a "rush" style deck, or a "beater" deck where you just rely on pumping out big monsters. It might be lower for a deck where you are relying a lot on synergy.

Key Card Importance: KCI, whether this card is extremely important for this deck. In some decks, there may be a really special card where the whole deck is built around it. In which case this would be high, and a key card would be considered especially valuable. I think this is also a function of what is currently in my hand, so KCI(H).

This ends up leaving us with something that looks like:

`Card Value = CV(H, KCI(H), IV)`

Intuition tells me that for decks with lower synergy, KCI will typically be lower, and IV will typically be higher, and the reverse for decks with high synergy and focus.

If we were to chart Card Value, from highest to lowest (for a given hand), I suspect we would something in between two extreme curves. A deck with extremely high focus on just a few key cards would have very high value cards clustered towards the beginning, and lower value cards clustered toward the end. A deck with lower focus with higher average Intrinsic Value would have a much flatter curve.

Of course I think this model is still a simplification, since there is probably another variable that would affect some of these knobs, Inaccessible Cards, which could make a lot of cards in your deck lose value if there are too many important cards in there (i.e. graveyard, discard, banished cards. So if all my key cards are in the discard pile, the rest of my cards will lose a lot of value. I think this is an OK simplification to make since the importance of this parameter will only be much later in the game.

• Oh yea I forgot about that. In comparison, Hearthstone will let you pick up to 2 of each card except for legendaries of which you can only have 1.

• One thing I need to add is that these game (Eternal, Magic as well I think) allow you to have up to four copies of the same card in your deck.

I know nothing about Magic or similar card games, but I saw that mathematics was one of the topics assigned and I was intrigued by the question

When does it make sense to have more than 75 cards?

It sometimes helps to mess around with a smaller or simpler problem and then apply the rule(s) discovered to the actual problem.

Letβs say you have three cards labeled π¦, π, π

I could label them 1,2,3 or a,b,c but I like using emojis.

If the synergy comes from dealing the π¦ card first followed by the π card, then there is 1 out of 6 possibilities that you will get dealt that sequence:

π¦π

π¦π

ππ¦

ππ

ππ¦

ππ

So 1:6

Another way to look at it is that you had 3 possibilities for the first card you drew and two possibilities for the second card you drew.

And 3 times 2 equals 6 combinations. If you had 4 cards, youβd have 4 possibilities for the first card times 3 possibilities for the second card, which would equal 12 combinations.

So 76 cards would equal 76*75=5,700 possible combinations.

Back to the 3 cards. What if the sequence dealt didnβt matter for synergy, that is

π¦π has the same value as

ππ¦

Then in a 3 card deck there are 2 successful draws out of 6 possible combinations. So 2:6 or 1:3.

Your chances are doubled if the order doesnβt matter.

What if your 3 card deck had two of the same card? That is your 3 cards are π¦ππ.

π¦π

π¦π

ππ¦

ππ

ππ¦

ππ

If order doesnβt matter, you have 4 successful chances out of 6 or 2:3.

If there are π cards that can be combined with a number of different cards

π¦π

ππ¦

ππ

to create synergies, then the value of adding the π card goes up even more.

Hope that was both understandable and somewhat helpful.

• @apm I think yours is a good example to show the general problem we're talking about, if expanded slightly.

In that example
> our minimum deck size is three
> we're drawing a hand of two cards
> drawing {duck, pizza} is a good event, drawing {X, cake} in our initial hand is bad, but we still want to draw cake at some point.

If our deck consists of just {duck, pizza, cake}, then as you point out we have a probability of 1/3 to get the good event. We have a 2/3 probability of immediately drawing {X, cake} - but we only want cake later.

Replacing cake with another pizza (deck is {duck, pizza, pizza}), we increase the "good draw" probability to 2/3, but at the same time we decrease our probability of drawing cake to 0 - and we want to eventually draw cake.

So, if instead of replacing cake with pizza, we add another pizza on top of that - making our deck {duck, pizza, pizza, cake} - we will still have a 1/3 probability of drawing {duck, pizza}, while our probability of drawing cake early is reduced to 1/2 while still being available at some point.

Adding another duck for {duck, duck, pizza, pizza, cake} increases our "good draw" probability to 2/5, while decreasing the probability for an early cake draw to also 2/5. On the other hand, the fact that we've added another card also means that there's a 1/5 probability of cake being the fifth card in our deck. If we're only ever drawing four cards, this can mean that we're not drawing cake at all

So, in this toy example, depending on what value we want to give to the events "initial good draw", "eventual cake draw" and "no cake draw at all", it might be sensible (or not) to play with a deck consisting of four or five cards instead of just three.

At the same time though, we're making pretty big assumptions again and stay very vague in some regards, so I'm not convinced that this outcome can just be generalized to any deck size and any value for synergistic effects between cards.

• @Eric Looking at this and squinting hard, it looks as if the mathematically proper way to deal with this would be to do a discrete sum over all possible deck permutations and positions ("position" meaning number of cards drawn over time) using the value you suggest, then dividing by some factor that depends on deck size, to get a closed formula for something like an Average Deck Value (ADV).

Then, manipulating the inequality ADV(deck_small) < ADV(deck_large) (basically stating that we're looking for a situation where the larger deck is better than the smaller deck) to remove constant factors etc. might lead to some more clues under which circumstances this can be true, if at all.

• @Factotum I was thinking about trying to have a small card set example. Suppose there is no synergy and you have 6 cards with their card value equal to their number, 1, 2, ... 6. You could create a deck with 5 cards D1, and you could create a deck with 6 cards D2. So the logical way to build D1 is to put cards 2 through 6 in the deck, and leave out card 1 which has the lowest value.

In this hypothetical situation we start with 0 cards in our hand. Then the draw potential for each deck would be:

```D1 draw potential = (2 + 3 + 4 + 5 + 6) / 5 = 4
D2 draw potential = (1 + 2 + 3 + 4 + 5 + 6) / 6 = 3.5```

If you could generalize this to where you are comparing a deck of size n vs n+1, where the deck of n+1 has all of the exact same cards, plus one more which is guaranteed to be smaller, we want to prove something like:

sum(n): the sum of value in deck 1 (avg value * n)
c: an n + 1 card that is lower value than the lowest value in the deck
of n cards.
prove: draw potential for the larger deck is worse than the smaller deck.

```1: sum(n) / n > (sum(n) + c) / (n + 1)
2: (n + 1) * sum(n) > (sum(n) + c) * n
3: n * sum (n) + sum(n) > n * sum(n) + c * n
4: sum(n) > c * n
5: sum(n) / n > c```

Seen in this form, we can see that as long as the card c has a value less than the average value of the smaller deck, then it reduces the average value of the larger deck. Meaning lower draw potential.

I think this can be generalized to include synergy as well, it just makes things more complicated.

Edit: Math

• @Eric Thanks. I think this is similar to the original reasoning of just cutting the "worst" card from your oversized deck. This is definitely correct for card games without synergy.

In the meantime, I've thought about your last post and my response to it. One thing led to another, and now I have this crazy formula for the "Average Deck Value"... I think I've got some explaining to do! :D