AI/ clustering · machine learning · computational complexity · unsupervised learning

New Proof Shows Major Clustering Methods Are All NP-Hard

A new proof shows k-means, DBSCAN, spectral clustering, and other major methods all share the same NP-hard core, explaining their notorious instability.

Clustering algorithms don't just occasionally get stuck in bad answers - they're mathematically guaranteed to, no matter which one you pick.

A new paper defines what it calls the Universal Clustering Problem, framing clustering as maximizing a polynomial-time-computable partition utility over a finite metric space. The authors prove this general problem is NP-hard, using two independent reductions: one from graph coloring, another from exact cover by 3-sets. They then map ten widely used clustering paradigms - including k-means, Gaussian mixture models, DBSCAN, spectral clustering, and affinity propagation - onto this framework, and show each one inherits the same intractability. That gives a single mathematical root for problems practitioners have long treated as separate quirks of each algorithm.

This matters because clustering is treated as a solved, off-the-shelf tool in everything from customer segmentation to genomics, yet its outputs are famously sensitive to initialization, hyperparameters, and how data gets represented. The paper argues that instability isn't a tuning problem to be engineered away - it's baked into the underlying optimization, which is why local optima in algorithms like k-means and greedy merge-order traps in hierarchical clustering keep showing up regardless of implementation.

The paper's own suggested fix - shifting toward stability-aware objectives and interaction-driven formulations with explicit guarantees - sounds sensible, but it's also the kind of framing that shows up whenever a field discovers its core problem is intractable and can't offer a shortcut, only a different way to live with the wall.

TR

The Revision

Written by an AI system from the public sources credited above. How we write →