Before Donald Trump took office, he promised he was going to stick it to China on trade. When he assumed power, he indeed did so — threatening and then levying tariffs on hundreds of billions of dollars worth of Chinese imports. China responded in kind, before agreeing to a largely symbolic trade agreement in January only to have it disrupted by the coronavirus pandemic.

The problem the Trump administration was ostensibly trying to solve was America's enormous trade deficit, which Trump has portrayed as the U.S. being ripped off by foreign countries. This was also the motivation behind the renegotiation of the North American Free Trade Agreement, and a threatened trade war on Europe that is also now on hold.

Yet all these actions did not shrink the trade deficit. On the contrary, the deficit widened for the first few years of Trump's presidency, shrank back to about what it was before he took office in late 2019, and now has widened once again. What gives?

The answer can be found in a brilliant new book by journalist Matthew Klein and economist Michael Pettis, Trade Wars Are Class Wars: How Rising Inequality Distorts the Global Economy and Threatens International Peace. Trump's trade war failed because he did not understand what is actually driving the problems with the world trade system. The United States has a massive and destructive trade deficit because it has become the world's consumer of last resort, which in turn is the product of inequality in foreign countries and the dollar's role in the international financial system. In effect, America has become the victim of its own centrality in the global economy. However, it is a great mistake to think of this as the fault of foreign countries. As the book's title indicates, the real competition is between rich elites and working-class people of all countries. So far elites have been winning, and the result is a dysfunctional trade system that has wreaked social carnage across the world.

Klein and Pettis have a complex and penetrating analysis of world trade, but their basic argument is quite easy to understand. It is an observed fact that rich people save more of their income than working-class or poor ones. Therefore, the more unequal a country is, the more it will struggle to actually consume all that its economy is capable of producing. A severely unequal country is liable to fall into a permanent mild depression, with high unemployment and idle economic capacity, because its workers do not have enough income to consume what they produce.

However, trade provides a way to escape this trap. If unequal countries can find export markets and develop a trade surplus, they can keep their economies running at full capacity — at the potential cost of victimizing the countries that are necessarily forced into deficit. Under certain conditions, like when a richer country sends actually productive capital investment to poorer countries to kick-start their growth, which happened between the U.K. and the U.S. in the 19th century, this can be a mutually useful arrangement. But it can also cause terrific economic carnage, as when cheap U.K. textile exports obliterated the industrial base of India, and badly worsened several murderous famines.

Incidentally, this is close to what Lenin famously argued was the root cause of World War I: Capitalist European powers had to scoop up colonies to vent their surplus production, and once the entire world had been gobbled up, they were sure to come to blows sooner or later. However, Klein and Pettis side more with English economist John A. Hobson, whose analysis Lenin's was based on. Hobson argued that this could have been rectified by making the European income distribution more equal, and that most colonial export markets were at the end of the day not that profitable.

At any rate, it follows that countries develop a big export surplus not because they are good at manufacturing, but because their workers are underpaid and can't afford to buy what they make. Sure enough, the biggest exporters today, Germany and China, are extremely unequal. German wages have been basically flat for 20 years thanks to a suite of neoliberal reforms in the 1990s and 2000s, while in China, "workers at nonfinancial corporations in China are paid only 40 percent of the value of what they produce," Klein and Pettis write.

The difference today is that it is mainly not poor countries who are roped into choking down the global surplus, if only because they do not have nearly enough income to do so. Instead the U.S. has become the world's surplus dumping ground.

Now, one might think that by the above argument the U.S. should also be a surplus country, because it is so unequal. But the dollar's status as the world's reserve currency means the U.S. basically cannot help but run a trade deficit. That's because two main groups create a tremendous demand for dollars.

First, foreign central banks, especially in middle- and lower-income countries, have built up giant dollar hoards to protect themselves. This is so they can defend their currency values from attack from financial speculators, who can and often do manipulate exchange rates to make a quick buck (for instance, by taking out a loan in one currency, swapping it for a second, then causing a sharp devaluation in the first one so the loan repayment is cheaper). They also want to avoid political interference from the International Monetary Fund, which is supposed to help countries in currency troubles, but instead has typically forced them to undertake disastrous neoliberal "structural adjustment" policies that often made the problems worse — most notoriously in Southeast Asia in the late 1990s.

Second, rich foreign savers, especially in Europe, view dollar assets as the best way to store their income. The U.S. dollar is the most widely-accepted and trusted currency, U.S. government debt is considered the safest asset in the world, the U.S. economy is large and diversified, and the American financial sector is wide open to foreign investors (and central banks). There simply isn't anywhere better for the global glut of savings to land.

So if the rest of the world is to get their hands on dollar stockpiles, then America must somehow borrow to create them. China and Germany have suppressed their spending below their earning to produce savings, and for those savings to become dollars, as a matter of financial arithmetic, that means Americans must spend more than they earn — creating a trade deficit.

In theory, the U.S. government could just issue trillions in debt instead, but thanks to the neurotic fixation on the national debt among the American elite, it has not done so. Indeed, even President Bush's epic borrowing spree in the mid-2000s did not come close to satisfying demand. So in practice, demand for dollars has pushed up the value of the currency, making American exports more expensive and foreign imports cheaper, sapping American output and sending its demand abroad, until the requisite imbalance between domestic production and consumption — again, a trade deficit — is obtained. That is why Trump's various tariffs have not closed the trade deficit. Dollar demand leaks out around them through other countries, and insofar as they do cut foreign imports, the end result is just a further appreciation of the dollar that cuts domestic output even more to compensate.

This has done tremendous damage to the American economy. A big chunk of its industrial base has rotted away not only thanks to slanted "free trade" deals, but also because U.S. manufacturers were placed in a systematically bad price position and had weaker export markets thanks to inequality-induced weak foreign demand. What's more, foreign dollar purchases were also a major factor fueling the mid-2000s housing bubble, as Wall Street swindlers hit on the idea of selling mortgage-backed securities to foreign investors and, when demand proved to be bottomless, radically lowered lending standards to create supply.

As Klein and Pettis write, thanks to the dollar's unique position America suffered a "housing debt bubble and a displaced manufacturing base. Rather than an exorbitant privilege, the dollar’s international status imposed an exorbitant burden."

How did the U.S. end up in this position? The story is long and complicated, but there are two key events. First, the international conference in 1944 at the Bretton Woods resort in New Hampshire, where the Allies ironed out a new system of international trade. Britain's John Maynard Keynes proposed an "International Clearing Union" system that would enable balanced trade — punishing both deficit and surplus, and thus preventing surplus dumping — but the U.S. delegation vetoed this idea. Instead they proposed a system of fixed exchange rates centered on the dollar that would not punish surplus countries, because at the time the U.S. was the biggest exporter in the world by far, and because they wanted foreign countries to hold U.S. assets to keep down borrowing costs.

This was a pretty good arrangement for a few decades, but the system cracked apart in the early 1970s, under pressure from American inflation and financial speculators. The dollar was allowed to float in value against other currencies — but it remained the world's reserve currency. As inequality grew in Europe, China embarked on an investment-led growth project (requiring it to suppress domestic consumption), and it and other developing countries accumulated protective dollar hoards, U.S. trade deficits grew and grew.

American influence was also behind the IMF bungling in the 1990s that horrified developing countries and made them resolve to build up fortress dollar reserves. The United States would be much better off today if it had gotten behind Keynes' more fair and neutral system, and hadn't been such a colossal jerk to the Global South.

So what is to be done? In the short run, Klein and Pettis suggest that the U.S. needs to be more responsible about its government debt — namely, by issuing a great deal more of it. The attempts to balance the budget under Presidents Clinton and Obama were catastrophic policy errors that grossly harmed the American people. The world must have dollars to lubricate international trade flows, and the U.S. government is best situated to provide them. It would be better still if the borrowed money funded badly-needed investment into decarbonization projects, like green power or a national high-speed rail network.

Secondly, the Federal Reserve could calm foreign central banks by institutionalizing its "swap line" facilities. These were set up in a panic during the 2008 crisis, and allowed certain countries (mostly rich ones) suffering a currency crunch to exchange their domestic money for dollars. That saved several countries' banking systems at the time, and the swap lines are once again in use thanks to the coronavirus pandemic. But if these were systematized and available to any country in distress, it would reduce demand for dollar assets, and cut the trade deficit.

Thirdly, the U.S. (and other countries in a similar position) can bring back capital controls. Issuing more debt to make allowances for trade needs is one thing, but there is no reason to grant the world's ultra-rich a limitless safe harbor for their excess savings. These can include government rules like banning foreign nationals or companies from buying U.S. assets (particularly houses), or taxes on international stock purchases or currency exchanges, and so on. That would put pressure on foreign countries to increase their domestic spending, boosting their imports and cutting the U.S. trade deficit, and also help protect nations from financial predators. Capital controls were a central part of the Bretton Woods system — a big part of why it survived as long as it did despite its rather goofy design.

But in the longer run, the whole world is going to have to confront the problem of inequality. As Klein and Pettis argue over and over, the American working class is not being victimized by China or Germany as such. Rather, the working classes in all three countries are being victimized by the international wealthy elite. Big business owners in Germany are making out like bandits thanks to the huge German surplus, but German workers are getting by on relative scraps. Moreover, German growth has been rather weak since 2008, and thanks to German conservatives' monomaniacal fixation on keeping down the budget deficit, the country is so starved of investment that its physical infrastructure is falling apart. And since German austerian thinking has come to dominate the eurozone, the rest of the currency union is doing even worse — it has both a toxic trade surplus and crumbling infrastructure and a continual economic depression. On its current track, the eurozone threatens to become a "permanent menace for the rest of the world," they write.

Chinese business elites are similarly swimming in export profits, but Chinese workers are probably the worst-paid relative to their productivity in the world. Indeed, the Chinese Communist Party has openly admitted for years that its investment-led growth model is running aground, and to keep growing over the medium term the country will have to rebalance its output more towards wages and start developing a much bigger domestic market. Half the reason it is struggling to find profitable domestic investment is that its working class does not have the income that would justify new or expanded businesses. But thus far there has been limited progress, because the entrenched interests who benefit from the status quo don't want to lose out.

Finally, America is the biggest trade loser on net, but its elite still reaps considerable benefits from the status quo. Surviving domestic companies can juice their profits by outsourcing production and cutting wages. The financial sector rakes in gigantic sums trading the vast quantities of dollar assets. And the American imperial apparatus holds enormous power to inflict pain on other countries (like Iran and Russia) through its influence over the world's financial plumbing. Rust Belt cities must dry up and blow away so Donald Trump can starve the Iranian citizenry.

Changing this unholy mess is going to take politics. One quibble I have with the book is that the authors repeatedly discuss all the problems with trade as "distortions" — implying some divergence from a natural state. But there are no natural outcomes in economics; everything is the product of human agency and state policy. And it's not just Trump and Xi Jinping. For decades dominant center-left and center-right parties in America and Europe have dogmatically held that globalization, austerity, and financial deregulation are good by definition. This simply is not the case, and it will take a great international struggle to construct a trade system that works for all instead of a few.

American action can help pressure countries into restructuring their economies, but workers around the world will also have to mobilize domestically to demand a fair share of what they produce. One sensible additional demand would be for Keynes' International Clearing Union to be resurrected, so the dollar would no longer be needed as a reserve currency.

But should countries around the world take the necessary steps, there is a real prospect of a win-win bargain. We could have fair trade, better wages, higher growth — and should the proceeds be plowed into green investments, which is by far the most logical option — attack climate change, all at the same time. In short, working classes of all countries have a world to win.

Want more essential commentary and analysis like this delivered straight to your inbox? Sign up for The Week's "Today's best articles" newsletter here.