logoalt Hacker News

sfinkyesterday at 10:45 PM1 replyview on HN

The author justifiably attacks the notion that "NP-hard" == "too hard to solve in practice", but then makes the opposite error:

> Everyone knows you can tackle those with heuristics, but you don't have to sacrifice optimality.

Unless you're using some weird definition of optimality, or happen to have a proof of N=NP in your back pocket: yes, yes you do.

You don't have to sacrifice "good enough". You don't have to let it run for an insane amount of time. Just about all interesting problems that I know of have either (1) good heuristics that in practice get close enough to optimal that nobody needs to care about the gap, or (2) constraints or restrictions that are totally fine to apply in practice.

But those are both ways of sacrificing optimality. You have to sacrifice optimality. It just turns out that optimality isn't usually very important, especially when 99% of optimality is achievable.

> We absolutely have tools that can find provably optimal solutions in reasonable time. There's no magic. No quantum computers. Just thinking harder and coming up with better algorithms.

No, we absolutely do not. Again, not unless someone has secretly come up with a constructive proof of P=NP. "Optimality" in the first sentence, "provably optimal" here, those terms are precise -- so I'm confused why the author is claiming that multiple people have achieved the impossible.

The article clears up one serious confusion only to replace it with another?


Replies

ngruhnyesterday at 11:40 PM

Author here. I agree, I should add more hedging:

> Everyone knows you can tackle those with heuristics, but you don't (ALWAYS) have to sacrifice optimality

> We absolutely have tools that can (OFTEN) find provably optimal solutions in reasonable time