Lanchester (1868 ~ 1946) is a British engineer, fluid mechanic and logistics scientist, and also a pioneer of British automobile and aviation engineering. He made the first car in England in 1896. 19 15 years, in the article "Aircraft in Battle", he first proposed to describe the process of destroying opposing forces with ordinary differential equations, and qualitatively explained the principle of concentrated forces. This principle is Lanchester equation ("Lanchester" is often translated as "Lanchester"). Lanchester equation puts forward two ideal mathematical models: Lanchester's linear law and Lanchester's square law.
1- 1: Lanchester's linear law
Lanchester's linear law is divided into the first linear law and the second linear law.
1- 1- 1: Lanchester's first linear law
Wikipedia's core expression of the first linear law is that "a soldier can only fight another enemy at a time." You can only kill one enemy at a time or be killed by one enemy. Under the condition of the same weapons on both sides of the battle, the number of troops left at the end of the battle is simply the difference between the two sides-the number of redundant parties. "
It can only be one-on-one combat, in other words, at the same time, both sides can only have the same number of troops to participate in the battle. In this case, the battle damage rate (the changing speed of the number of troops lost in the battle) has nothing to do with the number of troops on both sides.
In the realistic scene that conforms to the first linear law, "meeting in a narrow road" is the most common one: two troops meet hand-to-hand at a limited width intersection. Among them, the simplest scenario is that this intersection can only be one-on-one, both sides are melee, and no other units can participate in the war except the two units that are fighting. For two opposing troops A and B, we use X to represent the number of troops A changes with time, and Y to represent the number of troops B changes with time; A represents the unit instantaneous damage rate of A (the efficiency of causing damage to the enemy), and B represents the unit instantaneous damage rate of B.. Then, the combat loss rate of A and the combat loss rate of B satisfy the following differential equations: Equation group A.
= -b
= -a
This set of equations can be integrated to obtain the "state equation" of linear rate.
A(-x)=b(-y) linear rate equilibrium equation
Wherein, it represents the initial number of A and the initial number of B. ..
If we say that the intensity of A and B are equal, that is, when the intensity of A is zero, the intensity of B is zero, and x=y=0, then: A = B;;
This is an equation that has nothing to do with time t, so it holds not only under the initial force, but also at any moment, as long as Lanchester's linear law of ax=by is satisfied, we can say that the forces of A and B are equal. That is, under the condition of satisfying the linear law, the strength of troops is directly proportional to the number of their own troops.
In fact, except for "one-on-one" combat, if the combat force is n, and n is neither greater than the total force X of A nor greater than the total force Y of B, then the equation describing combat damage is: equation group b(n≤x, n≤y).
= -bn
=-Ann
This system of equations can still get the linear rate ax=by.
As can be seen from the equation, the battle loss rate described by the first linear law is only related to the enemy's damage per second, but not to its own damage per second. Therefore, a more accurate description of the first linear rate is that if both sides of the war always bear the losses caused by the same number of enemy troops, then the strength of the troops is directly proportional to the number of their own troops.
Wikipedia's description of "between dense formations composed of spearmen in ancient battles" is the first linear velocity chart in the case of limited width intersection or limited "contact surface". In this case, only the soldiers in the "first row" participated in the battle, and the soldiers in the back row could not output damage until the soldiers in the front row were killed and replaced by the soldiers in the first row.
Another situation that conforms to the first linear rate is that the two sides are caught in a melee and the forces are scattered enough to support each other: the battle takes place between two units that "catch and kill". This situation may be short-lived, but under actual conditions, each unit's moving speed is not fast enough and its range is not far enough-we say this is true in many battlefield situations with limited "cooperation".
1- 1-2: Lanchester's second linear law
Lanchester's second linear rate describes a scene model completely different from the first linear rate: two armies shoot at random positions in the general direction of the other side when they can't aim accurately, and under the condition of the same queue density and weapons of both sides, "the probability that the party with more people is hit is balanced with the number of times that the party with fewer people is hit". In other words, although the party with a large number of people hurts more per second per unit time, the probability of being hit is greater because of the larger area of injury.
Equations of the second linear rate: Equation C.
= -byx
= -axy
Lanchester linearity of Ax=by can still be deduced. (Unless otherwise specified, the content discussed in this article generally refers to "Lanchester first linearity". )
1-2: Lanchester square law
Wikipedia's core description of the square law condition is: "troops can attack multiple targets and get hurt from all sides." Equation set describing the loss of square law war: Equation set D.
=-By
= -ax
If we look at the equation, the more accurate description of the square law condition should be: both sides of the war always bear all the losses caused by the enemy.
Integral to find the square law equilibrium equation;
a( - ) = b( -)? Square rate equilibrium equation
Like the linear rate, it can finally be deduced that when the two sides have equal combat power, there should be:
= Lanchester's square law, that is, under the condition of satisfying the square law, the strength is directly proportional to the square of one's own strength.
The classic scene that conforms to the square law is that two forces enter the effective range of each other, and all forces of both sides can attack each other.
1-3: Lanchester index.
In actual combat, because each unit will occupy a certain space, their speed is not fast enough and their range is not far enough. Many times, a unit can not only attack another unit, but also be attacked by another unit; You can't attack any enemy unit at the same time, nor can you be attacked by any enemy unit at the same time. In this case, the combat effectiveness of these troops is between the linear rate and the average rate. Wikipedia wrote, "In modern wars, it is often necessary to consider that linear law and square law work at the same time to some extent, and the index of 1.5 is usually used." This index is called Lanchester index in this paper.
The second part: attack sequence and critical value of life
The premise of Lanchester equation is: continue to export injuries and continue to bear injuries. In actual combat, if a unit is killed because of injury, then this unit can no longer provide damage per second. If a unit will be killed after the next attack and cannot fight back, we say that the unit is in a critical state.
We consider the simplest scenario in linear law: one-on-one hit.
Use A 1 for the first unit of Team A, A2 for the second unit of Team A, and so on; A 1( 1) means that a 1 can withstand1attacks, A 1(2) means that A 1 can withstand two such attacks, and so on; Use a 1 (1): b1(1) to represent units that can withstand1attacks. A 1 is for units that can withstand 1 attacks.
In the simplest case, a 1 (1): b 1 (1), a1and b1have a 50% chance of killing each other, and there is also a 50% chance of being killed by the other side-see who. And because they can only bear the attack of 1, they can't fight back after being attacked. So the result is either A1(1): B2 (1) (A1leads, B 1 is on top of B2 after being killed) or A2 (1): B/kloc-0.
If each unit of A can withstand 2 attacks, then the situation of A1(2): B1(1) needs to be analyzed step by step. It can be seen that if the linear law results are completely satisfied, the probability that two B units have the same combat power as 1 A unit is only 25%. There is even a very small probability that 1 A unit can fight against many B units (for example, the probability that 1 A unit fights against 6 B units is 3. 125%).
Similarly, by analyzing the case of A 1(4):B 1(2) in Figure 06 (the unit mass of A is twice that of B), the probability of satisfying the linear law is only 25% (that is;
Analyzing the case of A 1(3): B 1( 1), Figure 07 (the unit mass of A is three times that of B), the probability of satisfying the linear law is only 12.5% (that is).
The reason for this phenomenon is that under the same number of attacks, the higher the unit mass, the smaller the proportion of reaching critical health. We call this phenomenon amplification of quality advantage. If the amplification effect of quality advantage is considered, then in some extreme cases, the index will be lower than the linear law, that is, the index may be between 0- 1. We call the Lanchester index below the linear law 1 (and above 0) as sublinear index.
Part III: First Mover probability
On the basis of considering the attack sequence and the critical value of life, let's analyze a scene under the square law: Team A has four units, each of which can bear 1 damage; Team B has a unit that can take 4 injuries. Tu Tu 08 analysis is as follows:
It can be seen that the party with a large number of troops will have a great probability (80% probability in the figure) to destroy the enemy without casualties. This is because considering the attack sequence and the fact that the killed unit can't fight back, only the unit that attacks first can cause damage; The larger the number, the more units will attack first.
In other words, the square law itself is the amplification of quantitative advantage. If the first-hand probability is considered, the quantitative advantage will be amplified even more, and in extreme cases it will even be higher than 2 of the square law. We call the Lanchester exponent higher than the square law 2 the super-square exponent.
Part IV: Toughness and cooperation.
We call a unit's ability to bear damage toughness, and a unit's ability to participate in the output of damage in time coordination toughness. Through our previous analysis, we can draw the conclusion that the Lanchester index is between sublinear index and hypersquare index, and there are two conclusions:
4- 1: both toughness and cooperation will amplify the strength advantage.
Toughness will amplify the quality advantage of the troops, and cooperation will amplify the quantity advantage of the troops. These two amplification effects will be superimposed to form an amplification of the strength advantages of the troops.
4-2: Collaboration can improve the Lanchester index.
Cooperation was originally only to let more units participate in the battle in time, that is to say, more units on the battlefield meet the conditions of square law. However, because of the existence of super-square index, the amplification effect of cooperation on the number advantage of troops will be more obvious. This conclusion will lead to an interesting and counterintuitive phenomenon in the battle scene: even if the two forces are close in strength, even if one of them is reduced first due to random factors, this side will be completely defeated. The stronger the cooperation, the greater the probability of such an event.
The fifth part: Lanchester equation in strategic game.
When two troops with close forces fight, the random one destroys the other with little loss-this "interesting and counterintuitive phenomenon" is one of the most unwilling situations in the game. Even if it is not such an extreme situation, there is a slight gap between the forces of the two sides, which will be amplified by the Lanchester index. As a result, after ten minutes of hard work and development, we fought a decisive battle as soon as we met. Enlarging the strength advantage will make the victorious side lose little, while the defeated side will be almost wiped out. This situation is dubbed "a wave of hegemony" by players.
5- 1: war games and turn-based systems
Say "counterintuitive" because strategy games are not like this from the beginning. In the initial strategic games, the amplification effect of military superiority is not obvious, and the Lanchester index of these games is small and partial linear.
People have had a demand for strategic games since ancient times, on the one hand, it is a demand for entertainment, but more importantly, strategic games simulate real wars in many elements-strategic games meet people's demand for accumulating war game experience to a certain extent at a small cost (time cost) (no real war cost). When there is no computer and internet, board games are the most primitive strategy games. For example, in chess, we can understand a round as an instant "simultaneity": in this round, we may or may not eat one of our opponent's pieces. If in N rounds, A eats I times and B eats J times, then A's combat effectiveness is equivalent to multiplication on the basis of linear rate and B's multiplication, while Lanchester index is still 1.
In the turn-based chess game on the computer, one round is a cycle in which all units of both sides act once. In a round, if all units of a certain party can output damage, then in this round, the combat power of this party satisfies the square law. In fact, in a round, not all units can participate in the output; The number of output units participated by one party is not necessarily equal to the number of output units participated by the other party. Therefore, the Lanchester exponents of both sides are higher than 1 of the linear law, and they are not necessarily equal.
It can be seen that in fact, the amplification of military superiority has been reflected in the turn-based chess game, but due to the limitation of turn-based, the amplification effect of military superiority is not completed in a short time, but needs to go through many rounds. For example, A 1 and B 1, A2 and B2 are fighting each other. A 1 killed B 1 in the first round, so under the turn-based rules, A 1 needs at least the second round to help A2 participate in the attack on B2.
5-2: First Generation Real-time Strategy Games
In the real-time strategy game, if A 1 kills B 1, A 1 can "immediately" participate in the assistance to A2, with sufficient speed and range. In other words, A 1 killed B 1, which led to the downsizing of Team B. Under the turn-based system, A 1 and B 1 could not participate in the output before the next few rounds (A 1 can help A2 get the required number of rounds), that is, Team A and Team B. However, under the real-time system, A 1 can immediately assist A2, and the Lanchester index of Team B is reduced due to downsizing, while Team A does not. Therefore, compared with turn-based system, the strength advantage of instant system is more obvious.
The action of each unit in each round in the war chess game is operated and controlled by the player; In the real-time strategy game, under the pressure of time, it would be very strange if each unit had to wait for the specific operation of the player to respond. Therefore, in real-time strategy games, each unit usually has an attribute called "alert range". If an enemy enters this range, the unit will automatically attack even if the player does not give instructions. In addition, in a battle, how to adjust the formation and choose the most effective attack target, in addition to the player's operation, more needs AI calculation to cooperate with the instructions issued by the player to complete.
Let's take a look at the Dragon Knight Pathfinding AI, which was dubbed as a bug by players in StarCraft 1, and even reserved in the remastered version in order to maintain the "original flavor". When two teams meet at a narrow intersection, the Dragon Knight, as a range unit, will stop moving and start shooting when the enemy just enters the range. But at this time the enemy did not enter the range of the dragon knight in the back row. The ideal state is that the unit micro-operation in the front row of the player moves a little farther, but in most cases, the average player's hand speed is limited and may not be able to take care of it. So, the dragon knights in the back row made a strange move: they started to go back and tried to "detour" to the front-even though there might be no road to bypass on the map.
In the early real-time strategy game, due to the limitation of computer performance and AI algorithm, the behavior of each unit is very unwise without the player directly participating in micro-operation. This kind of "stupidity" may be manifested in detours, or in a daze, or it may be a broken line to find a way, a siege and so on. In short, the cooperation that each unit should have cannot be fully demonstrated. Therefore, this kind of pre-strategy game (we also call it the first generation real-time strategy game) has a higher Lanchester index than the war chess game, but it is difficult to reach the square law or even the super-square law because of the limitation of hand speed and AI. This kind of game consumes troops slowly and steadily in wartime, so it is easier for players to stop losses in time and avoid the situation of "a wave of hegemony".
5-3: Second Generation Real-time Strategy Games
With the progress of technology and algorithm, and with the accumulation of game design experience, AI in real-time strategy games is getting smarter and smarter. In the second-generation real-time strategy game represented by StarCraft II, AI is becoming more and more intelligent and reasonable. Take the dragon knight just now. Although moving the units in the front row forward belongs to the category of micro-operation, AI should not take over, but it is AI's job to keep the units in the back row from running around until the units in the front row are killed. For another example, if a unit moves from one side of a dense army formation to the other, the first generation of real-time strategy games will make the unit detour, or only manual micro-operation can make the friendly troops on the way move away. In the second-generation real-time strategy game, even if there is no micro-operation, friendly forces will automatically give way to their own units.
Because of the progress of AI, the cooperation of all units in the game can be brought into full play, and the Lanchester index in the second-generation real-time strategy game is greatly improved, which can approach the square law or even the super-square law. Let's review the conditions of the square law. From the perspective of unilateral combat power, it can be expressed as: damage per second, in which all its units can participate in the battle. In the case of limited unit moving speed and range, the ideal state is that all units gather at one point; If a unit needs to occupy a certain volume (battlefield area), then the plan to maximize its own combat power is to form as close as possible, which is what we often call the reunion mechanism.
The reunion mechanism is a double-edged sword: on the one hand, it maximizes its own combat power, on the other hand, it also makes the AOE (action area) of the enemy extremely powerful. Of course, it is also ignorant to completely ban AOE damage. Without the balance of AOE damage, a high Lanchester index will completely destroy all battles by winners who have no suspense. Therefore, in addition to weakening AOE damage, the second-generation real-time strategy game needs more mechanisms to balance the influence of military superiority amplification brought by high Lanchester index.
5-4: Strategic Game Demand
A close game is a wonderful game. If the game can be decided soon after it starts, or there is a one-sided situation during the game, it will not only make the spectators have no suspense, but also make the inferior side play negatively with hopeless frustration, and even make the superior side lack fun and sense of accomplishment.
Traditional strategy games often simulate a development process: players' strength is from scratch, from less to more. After ten minutes or even dozens of minutes of development (general competitive games will control the total time of a game, while single-player PvE games may need a longer development cycle), players finally organized a strong enough force. As a result, the two armies met, and it took a few minutes or even dozens of seconds to decide the outcome. Moreover, under the influence of the enlarged strength advantage of Lanchester index, the winner often wins by a big advantage. In this way, the losing side of a battle has almost no possibility of turning over. This is not what players want to see, nor is it what game designers want to see.
We hope that in the strategic game, the advantages and disadvantages of the opposing sides will gradually accumulate, because the advantages can be lost and the disadvantages can be recovered because of decision-making or operation. We hope that every battle is evenly matched, and we hope that there will be more battles-after all, for most players, fierce confrontation is more interesting than development. Therefore, in the frontal battlefield, there are mutual resistance, AOE and other designs to balance the amplification of Lanchester's exponential strength advantage. Increased the defensive advantages such as narrow terrain (reducing Lanchester index), slope (field of vision and hit rate) and battery (more cost-effective than arms). In the development strategy, a targeted mathematical model is formulated to balance resources and economy.
For example, in StarCraft 1, due to the low Lanchester index, each race can make different economic development models according to its own characteristics; In StarCraft II, because of the increase of Lanchester index, the economic models of the three races are very close-when the population is full, they are all farmers around 70, and the ratio of resource income is similar. Because even a fairly powerful force is full of great uncertainty, the economic model of StarCraft II can make up for the loss of a battle as soon as possible-as long as the economy is good enough. However, in warcraft 3, the restrictions on the total population and maintenance fees make the population occupation of even five farmers seem to be stretched. Warcraft 3's economic model tries to control the population of both sides of the war at the level close to the combat power, and the economy at the level of almost income, so that players can put more energy and operation on the frontal battlefield.
In a word, the amplification of Lanchester's index strength advantage is a basic principle to be considered in the strategic game. Strategic games with low Lanchester index have their own fun and charm, just like chess and chess still attract many fans. However, with the development of technology and algorithm, real-time strategy games with high Lanchester index are more in line with people's expectations for real combat simulation, especially the local frontal battlefield that real-time strategy games mainly show. When we complain that in a game like StarCraft II, both sides often swim in groups, and no one dares to act rashly. Once the exchange of fire seems useless, even if the effect of "hands off the keyboard" is no matter how good, only by thinking more and analyzing the principle behind it in depth can we find a reasonable and scientific design scheme to adapt to technological progress.