E CONOMISTS OFTEN argue that trade wars cannot be won. Yet they will be among the few beneficiaries from America’s barrage of tariffs. For decades, rich countries’ sound trade policies denied academics cases of tit-for-tat protectionism to study. But new American taxes on many goods from China and metals from everywhere have produced the data set of their dreams.

America’s government seems unfazed by the damage its tariffs do to the economy. One study by scholars at the Federal Reserve and Princeton and Columbia Universities found that the new levies have raised costs for consumers by $1.4bn per month.

However, Donald Trump is devoted to his voters. And his trading rivals have retaliated where it hurts. A paper by Joseph Parilla and Max Bouchet of the Brookings Institution, a think-tank, estimated that 61% of jobs affected by retaliatory tariffs are in counties that voted for Mr Trump.

Is this a coincidence? If a country’s imports from America already come from mostly Republican areas, those regions will bear the brunt of a trade war. However, a new paper by Thiemo Fetzer and Carlo Schwarz of the University of Warwick finds that America’s rivals probably did consider politics when crafting their policies.

To test if recent tariffs were politically motivated, the authors needed to compare them with alternatives that were not. They devised this benchmark by creating at random 1,000 hypothetical bundles of targeted goods for each trading partner, all worth the same as the actual trade facing tariffs.

The authors then compared real-world policies with these alternatives. First, they assessed the political impact of each plan, by measuring how closely its targeted areas matched Republican gains when Mr Trump was elected. Next, they estimated how much each policy would harm a retaliating bloc’s own economy, by counting the share of its imports of the chosen goods that come from America. The more a country relies on one supplier, the more switching to a less efficient source is likely to hurt.

The study found that the EU prioritised minimising such damage. Its tariffs deftly protected domestic consumers, causing less disruption than 99% of alternatives. The bloc targeted Trump voters as well—its tariffs matched the election of 2016 more closely than in 87% of simulations—but not at the cost of upsetting its own citizens.

In contrast, China focused on punishing Trump voters. Its tariffs tracked the election better than 99% of alternatives. They also disrupted China’s own economy more than in 99% of simulations. Even among plans including soyabeans—one of China’s main imports, grown mostly in Republican areas—China’s policy was just slightly more politically targeted than similar options, but far worse for its economy.

China’s choice of tariffs seems designed to deter escalation at any cost. Only regimes with no voters to satisfy can run that risk. The lesson is clear: if you start a trade war, fight a democracy, not an autocracy.