eldar
ChiefTank
My current game has me thinking. Let me describe the real-world situation first, it's very basic: I am Egypt, and have War Chariots (2-1-2, 20s). My only current viable opponent is Carthage, who have Numidian Mercenaries (2-3-1, 30s). Just for completeness, it ought to be stated that both Civs have had their Golden Ages due to previous wars with the Ottomans, who are now an OCC and with whom I've just signed a peace treaty.
It's still relatively early in the game, and the Carthaginian cities are mostly sizes 1-6, and are mainly on flat land. The level is Emperor, and I'm anticipating 2 defenders per city outside of the capital, and 4 in the capital. These defenders I expect to be mostly Regulars, with 3hps, and I will be mostly attacking with Veterans, with 4hps.
If I plug these values into the Combat Calculator, it's an almost even split. It says I win about 1/3 of the time, I lose about 1/3 of the time, and I retreat about 1/3 of the time. Okay... so that maybe indicates that I need to take 3 units along per defender? I think intuitively, any experienced player wouldn't need to be told the odds. If you have a 2-attack unit vs. a 3-defense defender, taking 3 units per defender seems about "right" when you don't have artillery support (and I don't).
Can I come up with a different way of calculating that this intuition, and what the Combat Calculator is telling me, is right? That I will typically need to roll up 6 units per city I want to take, and probably a dozen or more for the capital?
Well, I think I've come up with something (and please forgive me if it's already been thought of).
What I'm interested in is not the odds, the percentages, and so on. What I'm concerned with is simply this:
How many rounds of combat will it take to kill the defender?
That will tell me how many hit points are lost, between attacker(s) and defender, during the combat. From this, I can work out how many attackers I am likely to require.
So let's get down to my example: War Chariot vs. Numidian Mercenary.
The attack value is simple: it is 2.
The base defense value is 3. The unit is on flat ground in a Town (size 1-6) (+10%) and is fortified (+25%), for a total defensive modifier of +35%. 3 * 1.35 = 4.05, the modified defensive value.
So the combat odds for each round is:
Attacker: 2 / (2 + 4.05)
Defender: 4.05 / (2 + 4.05)
This can be re-worded as the following:
The attacker wins 2 out of every 6.05 combat rounds.
Or:
After 6.05 combat rounds, the defender will have lost 2hps, and the attacker(s) will have lost 4.05hps.
Well, I want to know how many combat rounds will be required to take 3hps from the defender. Since 3 (the desired number of hps) divided by 2 (the number I already know about) = 1.5, multiplying the total number of combat rounds by 1.5 should give me the result I want. 6.05 * 1.5 = 9.075.
To take 3hps off a given defender will require 9.075 combat rounds. Since I can't actually fight 9.075 rounds, and 9 won't be enough, this figure will have to be rounded up to 10 combat rounds.
So in 10 combat rounds, the defender will be killed (probably).
If the defender loses 3hps, then my attackers, between them, will lose 7hps. They have 4hps each, so, if I'm really lucky, the first attacker will lose, and the second will win with 1hp left.
What if my first attacker retreats? It will have lost 3hps, meaning I still have, in all likelihood, 4hps to lose before the defender dies. My second attacker may die (50% odds of retreating with a Vet unit - if the first has already retreated, law of averages and so on, ahem!)
So all of this backs up the intuitive notion, and the hinted-at notion from the Combat Calculator, that 3 units are what is required to do the job.
What I'm not taking into account of here is the chance of the defender promoting, but other than the random chance of that happening, I'm not expecting an automatic promotion. The defender won't be killing 2 units, so won't get that chance. If, in doing this calculation, it looks like the defender will get a promotion, I'd have to go back and re-calculate, giving the defender an extra hp. If it looks like the defender gets a double promotion, re-calculate with +2hps for the defender.
General Method Outline
Here's an outline of the general method to use. It's not a perfect replacement for an iterative process such as the Combat Calculator, because promotions are random, and so are retreats, not to mention defensive bombardment, the possibility that you may have to take out a low-defense defender (such as an Archer or Longbow) in between main defenders, and so on. However it's a good starting guide to give a notion of how many units you're likely to need per defender, and in fact the more defenders, the more likely it is to be accurate. This method is probably statistically better for Sid than it is for Chieftan!
1. Note down attack strength (A) and number of attacker hit points (Ahp).
2. Work out the modified defensive strength from the base defense and modifiers (mD).
3. Note down how many hit points you need to remove from the defender (Dhp).
4. Now take the single-round combat odds formula:
AWinOdds = A / (A + mD)
And note that this implies that the defender will lose A hit points in (A + mD) combat rounds.
To work out how many combat rounds will, on average, be required for the defender to lose Dhp hit points, multiply (A + mD) by (Dhp / A).
So:
NumCombatRounds = (A + mD) * (Dhp / A)
Or this can be re-written as:
NumCombatRounds = Dhp * (1 + (mD / A))
Round up NumCombatRounds (always) to give the result, FinalCombatRounds.
Now you can work out how many attacker hps (AhpLoss) will be lost with the simple formula:
AhpLoss = FinalCombatRounds - Dhp
From the value of AhpLoss, and knowing the makeup of your available forces, it should be possible to work out the optimum number of attackers per defender.
The above, then, is my "new way" of looking at combat. It's not 100% complete, of course the RNG can come along and wreck things, it usually does, but over time as with all such statistical things, it will even out.
I guess I'll now leave this open to comment so the usual suspects can come along and drill holes right through this analysis!
It's still relatively early in the game, and the Carthaginian cities are mostly sizes 1-6, and are mainly on flat land. The level is Emperor, and I'm anticipating 2 defenders per city outside of the capital, and 4 in the capital. These defenders I expect to be mostly Regulars, with 3hps, and I will be mostly attacking with Veterans, with 4hps.
If I plug these values into the Combat Calculator, it's an almost even split. It says I win about 1/3 of the time, I lose about 1/3 of the time, and I retreat about 1/3 of the time. Okay... so that maybe indicates that I need to take 3 units along per defender? I think intuitively, any experienced player wouldn't need to be told the odds. If you have a 2-attack unit vs. a 3-defense defender, taking 3 units per defender seems about "right" when you don't have artillery support (and I don't).
Can I come up with a different way of calculating that this intuition, and what the Combat Calculator is telling me, is right? That I will typically need to roll up 6 units per city I want to take, and probably a dozen or more for the capital?
Well, I think I've come up with something (and please forgive me if it's already been thought of).
What I'm interested in is not the odds, the percentages, and so on. What I'm concerned with is simply this:
How many rounds of combat will it take to kill the defender?
That will tell me how many hit points are lost, between attacker(s) and defender, during the combat. From this, I can work out how many attackers I am likely to require.
So let's get down to my example: War Chariot vs. Numidian Mercenary.
The attack value is simple: it is 2.
The base defense value is 3. The unit is on flat ground in a Town (size 1-6) (+10%) and is fortified (+25%), for a total defensive modifier of +35%. 3 * 1.35 = 4.05, the modified defensive value.
So the combat odds for each round is:
Attacker: 2 / (2 + 4.05)
Defender: 4.05 / (2 + 4.05)
This can be re-worded as the following:
The attacker wins 2 out of every 6.05 combat rounds.
Or:
After 6.05 combat rounds, the defender will have lost 2hps, and the attacker(s) will have lost 4.05hps.
Well, I want to know how many combat rounds will be required to take 3hps from the defender. Since 3 (the desired number of hps) divided by 2 (the number I already know about) = 1.5, multiplying the total number of combat rounds by 1.5 should give me the result I want. 6.05 * 1.5 = 9.075.
To take 3hps off a given defender will require 9.075 combat rounds. Since I can't actually fight 9.075 rounds, and 9 won't be enough, this figure will have to be rounded up to 10 combat rounds.
So in 10 combat rounds, the defender will be killed (probably).
If the defender loses 3hps, then my attackers, between them, will lose 7hps. They have 4hps each, so, if I'm really lucky, the first attacker will lose, and the second will win with 1hp left.
What if my first attacker retreats? It will have lost 3hps, meaning I still have, in all likelihood, 4hps to lose before the defender dies. My second attacker may die (50% odds of retreating with a Vet unit - if the first has already retreated, law of averages and so on, ahem!)
So all of this backs up the intuitive notion, and the hinted-at notion from the Combat Calculator, that 3 units are what is required to do the job.
What I'm not taking into account of here is the chance of the defender promoting, but other than the random chance of that happening, I'm not expecting an automatic promotion. The defender won't be killing 2 units, so won't get that chance. If, in doing this calculation, it looks like the defender will get a promotion, I'd have to go back and re-calculate, giving the defender an extra hp. If it looks like the defender gets a double promotion, re-calculate with +2hps for the defender.
General Method Outline
Here's an outline of the general method to use. It's not a perfect replacement for an iterative process such as the Combat Calculator, because promotions are random, and so are retreats, not to mention defensive bombardment, the possibility that you may have to take out a low-defense defender (such as an Archer or Longbow) in between main defenders, and so on. However it's a good starting guide to give a notion of how many units you're likely to need per defender, and in fact the more defenders, the more likely it is to be accurate. This method is probably statistically better for Sid than it is for Chieftan!
1. Note down attack strength (A) and number of attacker hit points (Ahp).
2. Work out the modified defensive strength from the base defense and modifiers (mD).
3. Note down how many hit points you need to remove from the defender (Dhp).
4. Now take the single-round combat odds formula:
AWinOdds = A / (A + mD)
And note that this implies that the defender will lose A hit points in (A + mD) combat rounds.
To work out how many combat rounds will, on average, be required for the defender to lose Dhp hit points, multiply (A + mD) by (Dhp / A).
So:
NumCombatRounds = (A + mD) * (Dhp / A)
Or this can be re-written as:
NumCombatRounds = Dhp * (1 + (mD / A))
Round up NumCombatRounds (always) to give the result, FinalCombatRounds.
Now you can work out how many attacker hps (AhpLoss) will be lost with the simple formula:
AhpLoss = FinalCombatRounds - Dhp
From the value of AhpLoss, and knowing the makeup of your available forces, it should be possible to work out the optimum number of attackers per defender.
The above, then, is my "new way" of looking at combat. It's not 100% complete, of course the RNG can come along and wreck things, it usually does, but over time as with all such statistical things, it will even out.
I guess I'll now leave this open to comment so the usual suspects can come along and drill holes right through this analysis!