Lanchester’s Laws

Overview

Did you ever wanted to calculate the outcome of a battle between two armies without actually testing it? This article will teach you the deep secrets and magic of fighting!

Historical Background

Lanchester’s Law are two mathematical formulas that describe the relative strength of two military forces. It was developed by an English mathematician Frederick William Lanchester during the First World War (1916 to be exact). He developed this formula by analyzing the battles of air forces and today his formula is not only used in military, but also in the area of economics. So let’s see how this applies to AoC!

Formula

If the starting units count of army A is A0, the starting units count of army B is B0, the units count of army A after a fixed amount time is A, the units count of army B after the same fixed amount of time is B and the force ratio is E then these rules apply:

First Law: A0 – A = E (B0 – B)
Second Law: A02 – A2 = E (B02 – B2)

The first law only applies when units fight one by one which will most likely never happen in AoC, and thus it’s not so interesting for us, but the second formula is fairly more interesting.

So let’s try to apply this formula in AoC. “E” the Force Ration in AoC is calculated in the following manner:

If the total amount of damage of army A is a and the total amount of damage of army B is b, then E is b/a.

In easy words: a is the sum of all units’ attack points of army A minus the armor total of army B (b is exactly the other way around). That also makes the formula easier by replacing E. Then it will look like this:

a (A02 – A2) = b (B02 – B2)

So now you know the formula! Or at least confused enough to continue reading. Let’s apply this in the real AoC!

Examples

1. Example: 5 Skirmisher vs 3 Skirmisher

Now let’s calculate how many skirmishers in army A (5 skirmisher side) will survive. a and b in this case is normal attack 2 plus attack bonus against archers 4 minus the piecing armor 3 so a and b will be 3.

a (A02 – A2) = b (B02 – B2)
3 (52 – A2) = 3 (32 – 02)
25 – A2 = 9
A2 = 25 – 9 = 16
A = 4

The surviving units of army A is 4. You can see that the unit ratio is only 5:3, but the actual ratio during the fight is 25:9. If you test this in AoC you will get similar results

Now things will become complicated if two different units types are fighting. Then you have to consider their attack, attack speed and hit points. a and b is calculated in this following manner:

a = (hit point of one unit of army A) * (attack speed) * (attack – armor of army B)
b = (hit point of one unit of army B) * (attack speed) * (attack – armor of army A)

Now we are ready for the next example, shall we?

2. Example 10 Skirmishers vs 10 Archers

In this case it is obvious that army A with 10 skirmishers are going to win. So let’s calculate the surviving units of army A after defeating all units of army B.

a = 30 * 0.33 * 5 = 50
b = 30 * 0.5 * 1 = 15

a (A02 – A2) = b (B02 – B2)
50 (102 – A2) = 15 (102 – 02)
A2 = 70
A = √70 => A ≈ 8.4

In this case it means that if you add up the hit points of the skirmisher it will be equal to 8.4 skirmishers.

3. Example 10 Galleys vs 9 Galleys

The most practical example is when we seek the seas. Here’s an analysis for grush wars.

a (A02 – A2) = b (B02 – B2)
(102 – A2) = (92 – 02)
(100 – 81) = A2
A = √(19) A ≈ 4.4

So just 1 galley (10% of army A) makes such an enormous difference. This brings us to probably the biggest lesson from this article. If your army is bigger & better: fight! Even if you only have 1 unit more, the difference might turn out to be enormous. Especially in water based maps as both players will most likely get caught in a galley war. If you play it well, 1 single galley can make the difference.

Notes

In Lanchester’s Laws units do not attack efficiently. In real AoC players micro their archer army and kill enemy archers one by one which is not considered in Lanchester’s Laws. Therefore by theory 4, 5 archers will win against a knight, but in practical AoC it does not because the knight attacks an archer until he dies and then move to the next unit.

Also range, speed and blast radius are not considered either. These factors depend on the situation (e.g. in a closed gap cataphracts with logistica become stronger than on an open field) so the player must evaluate the result by his experience and knowledge.

Conclusion and Problem

So what have we learned? Well that fighting with bigger armies will gain you the advantage! Well I admit, most of us knew this fact, but I will tell you more. First of all the real relative strength of two armies are the squared units numbers therefore the difference in strength of two armies are often a lot more than you imagine. Also from this knowledge there is a tactic which is often used in practice as well. If you are outnumbered and you can not flee, split up your army. You can damage the enemy army more by fighting one by one unit which is shown in the first formula. However, if you’re caught into an enemy’s town. You might opt for staying in group and kamikaze’ing your army into killing villagers.

Another thing to remember is that this formula only works with one type of unit at the current time (it is not possible to calculate with a mixed army). If someone knows how to apply this formula to mixed armies, please feel free to share.

Written by _MariaN_

  • Pikeman93

    Nice formula.

    One question though – does this only work for ranged units? What about melee units?

    • BlanketPI

      It is a rough approximation for both. It isn’t perfect, though. With equally ranged units, you get closer results than with melee units, though. Also, if units do more (damage done by attacker)/(maximum HP of target), you get a smaller surviving group than for smaller such numbers. Try Siege Onagers versus Siege Onagers, for example, and you just subtract equal numbers on each side until the loosing side has 0.

      Some units, like Scorpions, just plain don’t work for this, however. If one unit outranges another, then you have some other things to calculate. With a minimum ranged unit, like the Skirmisher, versus a melee unit, you get even more headaches.

  • king

    wrong.

    • _MariaN_

      What is wrong^^?

  • Alexius

    Yeah, a formula allowing the smartasses look smarter before their patrons/audience, nothing to do with soldiers’ real life…
    Next absurdity – please try to reenact AoC on a chessboard!

    • _MariaN_

      Well that with chessboard, could be arranged…

      Anyways, this is just for fun don’t take it too serious e.g. take it like your are the scientist who determine the weather… you look the data what the computer says, but then still look at the sky and use your own brain before publishing what the weather will be tomorrow.

  • BlanketPI

    It’s actually for a continuous stream of damage than the chunks of damage that end up in Age of Empires. You get fewer units to survive because of that. I believe it also presumes that you target smartly and presumes that your units have access to all other units. You get higher numbers for victory, otherwise. Let me demonstrate by using 10 Trebutches versus 9, with 100% accuracy and then the same, only with Skirmishers, instead. (I’ll count by shots left to be taken, not HP)

    Volley 1: 7 vs. 6 (1 at 2)
    Volley 2: 5 vs. 4 (1 at 1)
    Volley 3: 4 (1 at 2) vs. 2 (1 at 2).
    Volley 4: 2 vs. 1 (at 1)
    Volley 5: 1 2/3 victorious!

    Skirmishers:
    1: 10 (6) vs. 9 (5)
    2: 9 (12) vs. 8 (10)
    3: 9 (4) vs. 8 (1)
    4: 8 (11) vs. 7 (7)
    5: 8 (4) vs. 6 (14)
    6: 7 (13) vs. 6 (6)
    7: 7 (7) vs. 5 (14)
    8: 7 (2) vs. 5 (7)
    9: 6 (12) vs. 4 (15)
    10: 6 (8) vs. 4 (9)
    11: 6 (4) vs. 4 (3)
    12: 5 (15) vs. 3 (12)
    13: 5 (12) vs. 3 (7)
    14: 5 (9) vs. 3 (2)
    15: 5 (6) vs. 2 (12)
    16: 5 (3) vs. 2 (7)
    17: 4 (15) vs. 2 (2)
    18: 4 (13) vs. 1 (13)
    19: 4 (12) vs. 1 (9)
    20: 4 (11) vs. 1 (5)
    21: 4 (10) vs. 1 (1)
    22: 4 9/15 = 4 3/5 = 4.6 victorious!

    • BlanketPI

      I don’t know what possessed me to think you get higher numbers with averaged (instead of optimal) targeting, but you don’t. You get lower numbers. I’d give an example, but I think the example above makes this long enough as is. Sorry, Cysion, for saying you were wrong when you weren’t.

      As for range, presumably there is compensation for distance traveled while under fire and the “hit-and-run” must be compensated for in the force ratios. Exactly how much, I don’t know. (You have to take into account both the time that the out-ranged units stall to attack and the distance run by the higher-ranged ones, if that helps.)

      For mixed armies, you get a messy set of partial differential equations. I am not equipped to solve even single ordinary differential equations and you need to find the partial differential equations to satisfy attacking evenly (since attacking the most vulnerable targets seems to be something you would have to brute force, though I could easily be wrong) all while messing with forces being depleted at a combination of two rates…. It would be messy. I can’t help there at all, unfortunately.

  • srianth1113

    awesome! i have with me a complete database abt 1v1 unit statistics that i made by using the standard formula for net attack per second. i knew all along the importance of population factor (especially for ranged units), but found the calculations for multipele units to be too tedious.

    i feel that although this formula does not tell how many people will live, the amount of hp left is fairly sufficient, since this no. will give us the min. no. of units left alive, and also since we are assuming a specific case here

    srinath wont return

  • barbarossa89

    This is quite fascinating. I had read of Lanchester’s laws, but never thought of applying them to AoC. I love algebra, so this makes perfect sense once you memorize the formulas. Of course, it is obvious that a slightly larger mass wins. Of course, in practice, this means the person with the smaller mass flees, until he meets up with another mass so they can combine to be a larger mass. This unfortunately leads to grushes where the whole battlefield migrates back and forth between two islands, with little actual fighting and lots of running away for the sake of getting a larger army. If only galleys hadn’t been allowed to turn on a dime…….

    Is this the first serious article on strategy not to have a recorded game associated with it?

    • _MariaN_

      Cysion wanted to attach a good grush war rec, but seems he didn’t find any :p . Thank you barbarossa.

  • Andy01

    You could consider how the units will go in a 1 on 1 then see that with a lot more.

  • _MariaN_

    oh com on 1 comment, that makes me sad :S

    • AlexSupertramp

      your comment is sooooo clever…. ¬¬