The paper claiming efficient markets require P = NP

5 min read 1 source explainer
├── "This formalizes what practitioners already knew: markets never actually reach equilibrium, and the gap is where profit lives"
│  └── @HN commenters (pragmatist camp) (Hacker News) → view

This group treats the result as mathematical confirmation of trading-desk folklore: real markets oscillate around equilibrium rather than settling at it, and the computational hardness explains why. For quants, the P vs NP framing is a rigorous way of saying arbitrage opportunities are structural, not accidental.

├── "The reduction is an artifact of the model's assumptions, not a fact about real markets"
│  └── @HN commenters (skeptic camp) (Hacker News) → view

Skeptics point out that general-equilibrium theory already loads in strong assumptions — convex preferences, no externalities, complete information — that do most of the analytical work. Forcing the equilibrium-finding problem into an NP-hard encoding may reflect the chosen formalism rather than any deep property of markets themselves.

└── "The paper closes a 70-year gap in general equilibrium theory by making market-clearing computationally equivalent to SAT"
  ├── @kscarlet (paper submitter) (Hacker News, 109 pts) → view

The preprint's core contribution — surfaced via the HN submission — is that Arrow-Debreu (1954) proved equilibria exist but said nothing about finding them. The 'if and only if' reduction to P = NP means the computational question isn't just hard, it's exactly as hard as the most famous open problem in CS.

  └── top10.dev editorial (top10.dev) → read below

Frames the result as a search-under-constraints problem: finding a market-clearing price vector is a fixed-point problem, and fixed-point problems are the natural home of NP-hardness. The bidirectional reduction is what makes this more than a curiosity — it ties market efficiency directly to a problem no one expects to be solved.

What happened

An arXiv preprint making the rounds on Hacker News (109 points) argues something that sounds like a category error until you read it: markets are competitive if and only if P = NP. The paper reduces the problem of finding a Walrasian equilibrium — the set of prices that clears every market simultaneously — to a known NP-hard problem, and then shows the reverse reduction too. The 'if and only if' is doing the heavy lifting. It's not saying markets are hard. It's saying the hardness of markets is the same hardness as SAT.

The setup is standard general-equilibrium theory: agents with preferences, endowments, a price vector, and the requirement that supply equals demand in every good at once. The classical Arrow-Debreu result from 1954 proved such an equilibrium exists under mild assumptions. It said nothing about whether anyone — a market, an auctioneer, a distributed set of traders — could actually find it. The preprint's contribution is to close that gap by making the computational question equivalent to the biggest open problem in computer science.

HN commenters immediately split into two camps. One camp treats this as a formalization of what quants have known for decades: real markets never hit equilibrium, they oscillate around it, and the oscillation is where the money is. The other camp is skeptical of the reduction itself — general equilibrium models make assumptions (convex preferences, no externalities, complete information) that already do most of the work, and forcing the problem into NP-hard form may be an artifact of the encoding rather than a fact about markets.

Why it matters

Strip the economics away and this is a result about search under constraints. Finding a price vector that clears a market is a fixed-point problem: you're looking for prices such that, given those prices, every agent's optimal choice is consistent with every other agent's optimal choice. Fixed-point problems are the natural habitat of PPAD, the complexity class where Nash equilibria live. Nash was already known to be PPAD-complete (Daskalakis, Goldberg, Papadimitriou, 2006), which is widely believed to be intractable but not proven NP-hard. Pushing competitive equilibrium all the way up to NP-complete — if the paper is right — is a strictly stronger claim than the Nash result, and it collapses a lot of adjacent conjectures.

This matters to practitioners for a reason that isn't obvious from the title. Every algorithmic trading system, every options pricing model, every DEX aggregator that routes orders across pools is implicitly betting that price discovery is tractable enough — that the market's collective computation converges fast enough to trade against. If competitive equilibrium is NP-hard, then the fast convergence you observe in liquid markets isn't the market solving the hard problem. It's the market solving an easier problem — a local, myopic, approximation problem — and the residual gap between that approximation and true equilibrium is the arbitrage surface.

The Efficient Market Hypothesis has always had a dodgy relationship with computation. Fama's original formulation is about information, not compute: prices reflect all available information. But 'reflect' is doing enormous work. If the mapping from information to prices requires solving an NP-hard problem, then EMH in its strong form is asking traders to routinely do something no algorithm on Earth can do in polynomial time. Weak-form EMH survives — you can still argue past prices don't predict future prices without needing P = NP — but strong-form EMH becomes a statement about complexity theory that most of its defenders would probably not want to sign.

The HN thread also surfaced the standard critique: real markets don't solve for global equilibrium, they use tâtonnement — iterative price adjustment, driven by local excess demand signals. This is basically gradient descent on the aggregate excess demand function. It converges in some cases (gross substitutes), diverges in others (Scarf's counterexample from 1960 already showed this), and in the general case there's no reason to expect it to find a global optimum. The preprint doesn't invalidate tâtonnement; it explains why tâtonnement is what markets actually do. You can't solve NP-hard problems by gradient descent, but you can find local approximations that are 'good enough' for the participants to keep trading.

What this means for your stack

If you're building anything that assumes markets are efficient — pricing oracles, algorithmic market makers, portfolio optimizers, MEV bots — this reframing is useful even if the proof turns out to have holes. The practical implication is that your system's edge is your computational budget relative to the market's average participant, not your access to information. HFT firms have understood this for two decades; the paper is a formal statement of the folk theorem.

For DeFi specifically, this cuts against the design of constant-function market makers. Uniswap-style AMMs deliberately trade off equilibrium-finding for a simple, closed-form pricing rule. That's a feature, not a bug: they've substituted a tractable local rule for the intractable global problem, and they let arbitrageurs close the gap for a fee. If competitive equilibrium is NP-hard, then Uniswap's design isn't a compromise — it's the correct architectural response to the underlying complexity. The alternative would be an auction that tries to clear all pairs simultaneously, and that alternative is provably slow.

For anyone working on prediction markets, matching engines, or ad auctions, the takeaway is more subtle: any claim that your mechanism 'finds the true price' is a claim about a specific problem instance, not the general problem. Vickrey-Clarke-Groves is polynomial for single-item auctions but NP-hard for combinatorial ones. Yao's principle and the price of anarchy already tell you the gap between what your mechanism achieves and what a computationally-unbounded planner could achieve. This paper reframes that gap as fundamental rather than incidental.

Looking ahead

The preprint will get picked apart — arXiv economics papers with 'P = NP' in the abstract always do — and the reduction may not survive contact with a careful referee. But even if it doesn't, the framing is durable. Every efficient-markets claim is implicitly a complexity claim, and every algorithmic-trading strategy is implicitly a bet that the specific instance you're trading is easier than the worst case. That was true before this paper and it will be true after. What the paper offers is a clean, formal statement of a truth that finance has been operating on for a long time without saying out loud: the market doesn't find the price. It gropes toward it, and the groping is where the returns live.

Hacker News 189 pts 127 comments

Markets are competitive if and only if P = NP

→ read on Hacker News

// share this

// get daily digest

Top 10 dev stories every morning at 8am UTC. AI-curated. Retro terminal HTML email.