Hacker News new | past | comments | ask | show | jobs | submit login
What if P = NP? (acm.org)
124 points by caustic on April 1, 2011 | hide | past | favorite | 74 comments



A nice wee Charlie Stross story that begins with news of someone finding a proof of P=NP (Readability recommended):

http://www.antipope.org/charlie/blog-static/fiction/toast/to...


Some people have zombie apocalypse plans.

Me? I have P=NP plans.


There's a funny poll on P=?NP that William Gasarch conducted among computer scientists: http://www.cs.umd.edu/~gasarch/papers/poll.pdf

Some argue that the question is not as important as it is widely believed to be (see Sariel Har-Peled's opinion in the poll) - many NP hard problems have practical approximations, many P problems are prohibitively costly to solve.


> many NP hard problems have practical approximations, many P problems are prohibitively costly to solve.

I don't know if there is more to Sariel Har-Peleed's piece than the one paragraph in the poll, but as of today, most P problems used in practice actually have a very good running time O(n^3) or O(n^4). I don't know if there are too many problems that are in P but only "theoretically".

Also, even though P=?NP might not have very practical ramifications, if one believes in the notion of asymptotic complexity, it raises fundamental philosophical questions -- is judging creativity as easy as being creative.

As usual Scott Aaronson has excellent material on this question: http://www.scottaaronson.com/blog/?p=459


I see that piece mentioned a lot, but I don't think it's really in keeping with the existing philosophy or research on computational creativity. There's a lot of disagreement of course, but a vague consensus is that the formalization problem is harder than the computational complexity problem: computers composing novel, good symphonies is not mainly bottlenecked by computational complexity, but because we don't know how to write a program to do it (in any running time).

Put differently, why is symphony composition harder than SAT? You can download programs right now to solve huge classes of SAT, but not to compose huge classes of symphonies (David Cope's interesting work notwithstanding).

(That example from: http://www.kmjn.org/notes/nphard_not_always_hard.html)


That's an interesting read! I think his point is that NP-completeness does not give you an intuition about the hardness of automating creativity. That point is granted. However, if P were equal to NP, then it would imply that we can write algorithms that can automate creativity (Levin's algorithm is an algorithm to solve all NP-complete problems in polynomial time, if P=NP); which will raise an interesting philosophical debate all on its own.


I don't know if there are too many problems that are in P but only "theoretically".

Actually there is a known class of problems that are in P, but only "theoretically"! But for very different reasons than what you are thining of.

See http://en.wikipedia.org/wiki/Robertson%E2%80%93Seymour_theor... for a theorem that implies that certain types of graphs are characterized by a finite set of forbidden graphs that cannot be embedded in any form. (I'm being vague about "in any form" here, what I mean is that you can't do things like subdivide an edge and put a point in the middle then say, "Here! I changed it." More formally the forbidden subgraph can't be a minor of the main graph. See http://en.wikipedia.org/wiki/Minor_%28graph_theory%29 for an explanation of what a minor is.) For instance planar graphs cannot contain in any form 5 points that all connect to each other, nor two collections of 3 points that all connect to each other. (These are known as K5 and K3,3.) Any graph that does not contain these anywhere is planar.

It turns out a finite forbidden set of minors can always be tested in polynomial time. Therefore an class of graphs that meets the conditions for the Robertson-Seymour theorem has a polynomial time test.

Here is the catch. For many classes of graph we can prove that this polynomial time test exists. But we don't actually know what it is. Finding it requires enumerating the finite set of forbidden minors. But we have no way to figure out what they are. For graphs that can be embedded in the plane we know that there are just two. The projective plane turns out to have 138. As of 2004 I know that were nearly 240,000 known for the torus, and this list was not believed to be complete. According to http://www.cs.uvic.ca/~ruskey/Theses/WoodcockMScThesis.pdf there were theoretical algorithms that were O(n) and O(n^3), but nobody had ever implemented them and it was suspected that they would be too slow to use in practice. Moving on, consider the set of graphs that can be embedded in 3D without any knots. To the best of my knowledge nobody even has an exponential algorithm for that - yet we know that the problem must be in P.

So there you are. A whole family of problems, all of whom are known theoretically to have solutions in P, but for most of them we have no way to find said solutions, and even if we did find them they would likely be too slow to use in practice.


> For instance planar graphs cannot contain in any form 5 points that all connect to each other, nor two collections of 3 points that all connect to each other. (These are known as K5 and K3,3.)

Huh. I know this intuitively from doing those "try to connect the three houses to the three respurces without crossing any lines" kind of puzzles when I was younger—but I never made the connection that this kind of puzzle is basically the proof of the four-color theorem. My (puny) knowledge of topology has been made slightly more concrete. :)


but I never made the connection that this kind of puzzle is basically the proof of the four-color theorem.

Sorry, but the proof of the four-color theorem is much, much more difficult than the proof of this result. (Which is called Kuratowski's theorem and was proved in 1930.)

See http://en.wikipedia.org/wiki/Kuratowski%27s_theorem#Kuratows... for more background on the result that I was saying, and http://people.math.gatech.edu/~thomas/FC/fourcolor.html for more on the four color theorem.


Well, n^3 or n^4 might already be considered impractical in many situation and even linear time algorithms might have huge constants that make them impractical.

I agree about the philosophical questions, but don't they also rely on the practical ramifications of the question?

"is judging creativity as easy as being creative" What if P=NP, and for some problem there is a practical polynomial algorithm for checking a solution but only an impractical polynomial algorithm for finding a solution? What I mean is that the philosophical ramifications also depend on the assumption that polynomial~easy.


>n^3 or n^4 might already be considered impractical in many situation

You can always make these arguments for large enough N and short enough time constraints. It is an argument that as an engineer I sympathize with, but as a computer scientist I cannot endorse. The question of P=?NP is a mathematical and philosophical question. The problem of O(N) algorithms being too slow for situation X is an engineering question.

So while I recognize and even sympathize with you point, I do not think it detracts from the fundamental importance of the question at stake.


True, there is the engineering aspect, but I didn't mean that, I was talking about the same fundamental philosophical question you were.

That is, "are there problems for which we can easily verify a solution but not easily find one". P=?NP is only relevant to this philosophical question, if we accept that "polynomial" is synonymous with "easy". That is a widely accepted statement, but not entirely obvious. As it was said in the linked poll, even a polynomial running time could hide contants so large, that it is prohibitively large not just today but anytime in the future until the universe collapses upon itself. On the other hand there can be NP-hard problems for which we can find arbitrarily close approximations in reasonable time. The question is how well are our theoretical efforts capturing this intuition.


> Well, n^3 or n^4 might already be considered impractical in many situation and even linear time algorithms might have huge constants that make them impractical.

Ah, so you now you can see how pathetic our understanding of computational complexity is when we consider algorithms that are linear sometimes impractical but we cannot show we can do better than an exponentially worse off bound for SAT instances (Today's best SAT algorithms run in time 2^O(n)).


That poll was very interesting. I particularly enjoyed this "proof:" http://www.cs.cornell.edu/hubes/pnp.htm


Even accepting the leaps, the false underlying assumption is that if P = NP there must be a proof. Goedel's Incompleteness Theorem's key result is that within any logical system there are truths that cannot be proven.

It follows that we may never be able to prove that P = NP or P ≠ NP, even though one of the two must be true.


Actually, there are problems that are neither provably true/false, nor actually true/false. In fact I think a standard counting argument shows that 99.9999...% are in that category.


Yes but incompleteness refers to things that are true but can't be proven to be true.

I think you're referring to the idea of prospective axioms which can be proven to be independent of existing axioms (notably the axiom of choice). This is another thing altogether.

In the end, knowing enough about something to reduce it to axioms is only the start and not the end of understanding. P = NP wouldn't suddenly trivialize the problems so much as indicate that a polynomial time solution exists somewhere.


There was some good discussion about a P/NP for dummies article a while back, here:

http://news.ycombinator.com/item?id=1605415

And by the same author as the story above, a good list of reasons for believing that P probably != NP:

http://www.scottaaronson.com/blog/?p=122


What if the equality (or inequality) of P and NP is unprovable in the general case? Practical considerations aside, it would probably feel like a recursive joke ;-)


The year is 2230. The Nuclear Winter has passed, and the water wars have come.

One mathematician - the last of his kind - dares to spend precious time puzzling through theorems, seeking out ancient tomes of knowledge written in arcane symbols. He is searching for a proof which meant something to his ancestors hundreds of years ago.

One day, in a dusty library in what used to be called New England, he finds it. Not only through reading the works of others, no, he has proven many new theorems, and his results would have held application to the software efforts of centuries ago. God weeps that there is no software now.

But he has at last found it, the final proof: that it cannot be proven that it cannot be proven ... that it cannot be proven conclusively whether P = NP.


Suppose we could resolve (conclusively prove one way or the other) whether P=NP. Then we could also prove that we could resolve whether P=NP. Thus, if we can prove that you cannot prove that you can resolve P=NP, then we have also proven that we cannot resolve P=NP, a contradiction. Thus proving that we cannot prove that we cannot prove that we cannot resolve whether P=NP. This proves that we cannot prove that we cannot prove that we cannot prove that we cannot resolve whether P=NP. etc.


Let A be the statement: "P=NP or P!=NP" (in other words, suppose P vs. NP is decidable in some chosen axiomatic system, like Zermelo-Fraenkel set theory with or without axiom of choice).

You first said:

Suppose we proved A. Then we could also prove that we proved A. This is practically a tautology, since if we proved A, of course we can prove we proved A. I'll just hand you the proof.

Next, you said:

Suppose we can prove ~A (in other words, suppose we can prove that P vs. NP is undecidable in the given axiomatic system). Contradiction!

To sum it up, you said: "Suppose A and ~A. Contradiction!"

Or am I missing something here?


Ya, it looks like I bungled the logic. Let 'Pr X' means 'X is provable'. Let A be your A. Really what I wanted to say is that:

Pr A -> (~Pr ~Pr A)

and thus, Pr a -> Pr ~Pr ~Pr A.

Hence, ~Pr ~Pr ~Pr A -> ~Pr A

Taking A to be ~Pr A, we get:

~Pr ~Pr ~Pr ~Pr A -> ~Pr ~Pr A

So you can peel off pairs of ~Pr until you get down to one or two. Not very surprising, I guess, since Pr A == A in constructive logic, and you can do similar negation collapsing there.


I'd go see that movie.


The story reads great :D

But first and foremost, I like how ``it cannot be proven that...'' is a special kind of negation, much different than the ordinary negation in boolean logic. Is there any formalized logic system with a negation with properties like ``it cannot be proven that...''?


I'm sure a lot of people are "worried" about that. Remember, the mathematical community went through the same thing about 80 or so yrs ago when Gödel came up with his Incompleteness Theorem just about when most of the mathematical world believed that were were just a few steps shy of axiomatizing all of mathematics in a consistent manner (see: Hilbert's Second Problem).


Can someone explain the P=NP thing to me? I've tried looking at the Wikipedia article, but I'm going to admit right not that my computer science/mathematics skills aren't as amazing as I'd like them to be.

Wouldn't that mean that N == 1 and that P == P?


We're not multiplying N by P. P and NP are complexity classes.

Essentially, a problem is in class P (for polynomial) if an optimal solution can be found in polynomial time (that is, if the number of steps required to solve the problem is at most a polynomial function of the number of factors to check). So if you have a problem, and you can always solve it in polynomial time, it's in P.

A problem is in class NP (for nondeterministic polynomial) if the optimality of any solution can be checked in polynomial time. So if you have what you think is a solution, and you can always verify that in polynomial time, the problem is in NP.

We know trivially that NP is a superset of P: any P problem has to be an NP problem, because determining the solution in polynomial time counts as checking that solution in polynomial time. What we're not sure of is whether NP is a proper superset of P: the two could be equivalent, and we could just be overlooking polynomial-time algorithmic solutions to the problems we currently believe to be NP but not P.


Thanks for the answer. I'm not sure why I was downvoted, because I have looked it up before but just didn't understand. Not everyone gets everything the first time or went to school for CS so I highly appreciate you taking the time to explain.

I'm curious also why this problem is so near and dear to many people. I'm not sure I understand the implications.


The fact that you don't understand why it's dear to so many makes me completely sure that you don't understand the implications. I say that with respect and joviality.

Much of what we do - particularly much of our security - is based on the idea that P != NP, and that those "really hard" problems actually are really hard. For instance, cryptography is based on the fact that prime factorization is NP-hard, so if you use big primes it takes a long time to crack our encrypted information. If P = NP, and someone solves any NP-complete problem, all the NP-complete problems crumble and our security is a thing of the past.

There're good things to come of a constructive P = NP proof, too. We'd have perfect network routing, for one thing. Shipping would be much more efficient. And that damn salesman would finally know that he's getting from New York to San Fransisco and back by way of hundreds of other cities as quickly as possible.


Factorization is NOT NP-hard. There has never been a proof that guarantees I can't wake up tomorrow and factor any public key on the internet in polynomial time. It just so happens that nobody has figured out how to do it in the history of number theory (or to prove that it's impossible).

Shor's Algorithm factors primes. If prime factorization were NP-hard, that would imply BQP=NP (BQP is Bounded-error Quantum Polynomial time), or at least that BQP contains a subset of NP. Scott Aaronson, who has been linked to here a few times, is firmly convinced that is not true. And the implications of it are nearly as huge as the implications of P=NP! (with the small drawback that we can't actually build quantum computers yet :)


Factorization is indeed in NP. It might also be in P. I should've said "based on the idea that" instead of "the fact that."

"Hello World" is NP. It's just not useful to talk about that fact.


"Hello World" isn't a decision problem, but I see your point. However NP-Complete (and by extension NP-Hard) and P are distinct classes of problems, http://en.wikipedia.org/wiki/NP-complete so my statement that factorization is not an NP-Hard problem is true (unless, of course, P=NP).

Either way, my point was that there are systems (i.e. quantum computers) that can factor numbers efficiently, but it is still widely believed that true NP-Complete and NP-Hard problems cannot be solved efficiently even with such systems.


> Factorization is indeed in NP. It might also be in P. I should've said "based on the idea that" instead of "the fact that."

I'll reiterate. It is unknown if factorization is currently NP-hard. UKNOWN. It is most likely NOT NP-hard otherwise there would be huge implications in Complexity Theory.

It suffices for crypto for problems to be hard on an average. Factoring a random product of two large primes is hard. Factoring is probably not NP hard because no one knows if a factoring algorithm will help solve SAT.


NP is a superset of P.


I think I was mistaken in understanding what you said. Yes, factoring is in NP, but it is not known to be NP-hard. Being in NP doesn't automatically imply its usefulness in Crypto (because, as you say, P is a subset of NP). Neither does the NP-hardness of a problem automatically imply its usefulness. Crypto seems to need these weird problems that are not always NP-hard, yet, in some sense, harder than NP-hard problems. You can think of it as: crypto => P != NP, but not vice-versa.


Alright, I've been slightly unsure with each of your replies in this thread, but this one finally convinces me that you're just good at this "April Fools" thing.


"Shor's Algorithm factors primes."

Amazing!


Haha good catch. Should read "factors numbers into primes".


> If P = NP, and someone solves any NP-complete problem, all the NP-complete problems crumble and our security is a thing of the past.

Security can still be achieved. But it will require exponential time for an honest participant (a much lesser exponent than an adversary, but still exponential time). See: http://en.wikipedia.org/wiki/Merkle%27s_Puzzles It doesn't require P!=NP.


Why is this getting down voted? tibbon is asking an honest question...


Because a troll might do the exact the same thing, and it's April Fools.


The NP is just one variable and not N times P, it stands for Nondeterministic Polynomial time. The wikipedia article you want is http://en.wikipedia.org/wiki/P_versus_NP_problem


Wow, downvotes for curiosity. Way to go HN.

Edit: It was at -1


Anyone who finds this speculation about "What if P = NP?" interesting should try Impaggliazzo's excellent paper (it's very readable):

http://cseweb.ucsd.edu/~russell/average.ps


This is a followup, 15 yrs later from the rest of the TCS community:

http://cstheory.stackexchange.com/questions/1026/status-of-i...


It would be a boon for laissez-faire capitalism, as it would prove that markets are at least weak-form efficient.

Reference: http://arxiv.org/abs/1002.2284


Support for laissez-faire capitalism doesn't require that markets are efficient in any absolute sense, but only that using force will not produce a more efficient outcome in real-time. But I don't think people argue for markets to be supplanted by force for efficiency reasons, as its already clear that such a solution is intractable unless actor choices are restricted significantly.


Why did you add the phrase 'in real time' there? I don't follow (sincere question)


Because given enough information about preferences and enough time to think about it, coming up with a more efficient solution to a particular distribution problem than the market did seems possible in principle.


Ah, I'm with you now, thanks.


Correct. I should have said "neo-liberal economics".


What would really be interesting is someone finding a nonconstructive proof that P = NP. It would be quite a scramble to find the missing algorithms...


We already have algorithms for all NP problems, by Levin. See: http://en.wikipedia.org/wiki/P_versus_NP_problem#Polynomial-...

No one knows whether it runs in polynomial time though! It runs in polytime if P=NP.


"// "Polynomial-time" means it returns "yes" in polynomial time when // the answer should be "yes", and runs forever when it is "no"."

That's an odd definition of polynomial time.


It is just a technicality. If you know an upper bound on the running time you can simply run it for that many time steps and then return "no" if it doesn't halt by then (because it could never thereon answer "yes"). This only works with concrete upper bounds on running time (and not for general decidability).


From the beginning of the article: "We know which students are compatible with each other and we want to put them in compatible groups of two. We could search all possible pairings but even for 40 students we would have more than 300 billion trillion possible pairings."

Can someone explain why there are 300 billion trillion pairings instead of 40^2 pairings - 40 repeat pairings - incompatible pairings ?


Pairings involve matching everybody. There are indeed O(n^2) (well n*(n-1)/2) ways of constructing the first match. But then the other n-2 people still need to be paired up.

The exact number is n!/((n/2)!(2^(n/2))). There are n! ways to order them. Pair each with his neighbor. The order of the pairs doesn't matter (divide by (n/2)!). The order within each pair doesn't matter (divide by 2^(n/2)).

Using Stirling's approximation, the log of this is about n log n - (n/2) log (n/2) - (n/2) log 2 = (n/2) log n. The exponential is then n^(n/2). 40^20 is rather large at 109 nonillion. Because we approximated the log, this significantly off. The right answer is 319 sextillion.


Thanks for this! I was confused myself.

http://www.wolframalpha.com/input/?i=n%21%2F%28%28n%2F2%29%2...

seems to give 319830986772877770815625

It can also be done by thinking 39 * 37 * 35 * ... * 1 which also yields the same number. In that way, it is like selecting 1 person, who then has 39 people remaining, then selecting another, who has 37 left to choose from and so on.

I was super confused at first why it wasn't just 40 choose 2.


I see, they're talking about the number of configurations of pairs, not the number of unique pairs themselves.


If aliens arrived and told us P is not NP, would it still be worth trying to prove? What do you gain from the negative (except freed time to tackle other problems)?


Thanks, that's the first of these P = NP posts that explained it for someone uninitiated to the discussion!


Okay, the question of P versus NP is important. Now keep in mind that I admitted this when read the rest below:

Contention: In this research question of P versus NP and in the paper, we are looking at:

(1) A Lot of Hype.

(2) A Search for a Very Long Term Academic Job.

(3) Significant Amounts of Nonsense.

Details:

(1) A Lot of Hype.

(1.A) Nowhere in the article are there any very good explanations that a polynomial algorithm that shows that P = NP would be fast in any practical sense.

Indeed, the article has:

"Technically we could have P = NP, but not have practical algorithms for most NP-complete problems. But suppose in fact we do have very quick algorithms for all these problems."

So, to make such a polynomial algorithm of practical interest, we have to just "suppose" that it will be fast in practical terms.

(1.B) With the "suppose" above, the article has:

"Since all the NP-complete optimization problems become easy, everything will be much more efficient. Transportation of all forms will be scheduled optimally to move people and goods around quicker and cheaper. Manufacturers can improve their production to increase speed and create less waste. And I'm just scratching the surface."

No, it's just "scratching" and not "just scratching the surface."

I can absolutely, positively assure all readers that there are plenty of reasonably efficient and powerful means to attack such problems in practice now. In fact, the people flying airplanes, running manufacturing plants, designing large telecommunications networks, etc. are not much interested in attacking these problems with optimization. The main reason is: They just don't want to be bothered. In particular, these problems have long been part of the field of 'operations research', that has long been a dead field, a "late parrot", a dead duck.

Just what is it about people don't want to be bothered that is so difficult for the author of the paper to understand?

(1.C) Solve It All.

The suggestion in the article is that the question of P versus NP is the grand question and, thus, the last big problem in computational complexity.

Let's see: For many of the optimization problems in, say, airline scheduling, manufacturing scheduling, telecommunications network design, given an optimal solution, over the coming few hours, days, or weeks, real world uncertainty commonly will make that solution out of date and far from 'optimal'. So, the real problem that needs to be attacked in practice is optimization over time under uncertainty, and there was no hint of such problems in the paper or that showing that P = NP would provide solutions. Net, it is not clear from the paper that the NP-complete problems cover all the challenges that remain.

A lot of hype.

(2) A Search for a Very Long Term Academic Job.

The paper ends with:

"Perhaps we will see a resolution of the P versus NP problem in the near future but I almost hope not."

Of course he hopes not: As long as the problem is not solved, a lot of researchers chipping away on apparently quite distant parts continue to have a very stable career!

(3) Significant Amounts of Nonsense.

The article has:

"everything will be much more efficient. Transportation of all forms will be scheduled optimally to move people and goods around quicker and cheaper. Manufacturers can improve their production to increase speed and create less waste."

Glad he's interested in "less waste". But, let's see on three points:

(3.A) Approximately Optimal

Commonly in such cost minimization optimization problems now, we report two numbers: First we report the cost of the feasible, but perhaps not optimal, solution we did find. Second we report a lower bound on the cost of an optimal solution. When these two numbers are close for our practical problem, we quit and accept the feasible and approximately optimal solution.

The last time I did this, I had a 0-1 integer linear program with 600,000 variables and 40,013 constraints and found a feasible solution with cost only 0.025% higher than the lower bound, in 905 seconds on a 90 mHz PC.

So, the practical problem is, can we find techniques that get a feasible solution and a lower bound close enough for practice nearly always on the practical problems we face?

Nowhere did the paper recognize this problem or indicate a close connection with the challenge of P versus NP.

Yes, we can ask, given the optimization problem and a cost c, is there a feasible solution with cost less than c? So, since we can check a proposed solution quickly, this is a problem in NP. Then on this problem we can do a binary search on c and converge to optimality. So if this NP problem is in P, then with the binary search our optimal algorithm is also in P.

But it is not clear if this is the same problem as, can we get a feasible solution (in reasonable time, nearly always, on our practical problems) with cost c only 1% higher than a lower bound u? Or only 1% above the cost of an optimal solution (we don't know the cost of an optimal solution).

So, the question P versus NP is much more difficult than demanded by practice.

(3.B) The Big Savings.

The paper has,

"everything will be much more efficient."

This conclusion is unsupported, wildly unjustified, and from experience nonsense. It is not the least bit clear that optimal solutions will on average cost significantly less than the approximately optimal solutions commonly available now.

(3.C) The Cartoon.

Early in the reference,

Michael R. Garey and David S. Johnson, 'Computers and Intractability: A Guide to the Theory of NP-Completeness', ISBN 0-7167-1045-5, W. H. Freeman, San Francisco, 1979.

and praised in the paper, is a cartoon with an executive sitting behind a desk, a researcher standing just in front of the desk and stretching behind him over the horizon a long line of researchers, and the researcher explaining to the executive that he, the researcher, can't solve the executive's problem but neither can any of the researchers in the long line because none of them could settle P versus NP.

Nonsense. Made up, junk-think, make-work, prof-scam, busy-work nonsense: The executive's problem was just to save nearly all the money nearly all the time on the real problems, or at least to save some significant money sometimes, and not to guarantee to save all the money, down to the last tiny fraction of one penny, with polynomial computer time, on worst case problems, the worst that can exist even in theory.

Instead the researcher deliberately bamboozled the executive by converting his problem into one the researcher could have an excuse to work on for the rest of his career without getting a solution.

There is one more curious point.

The paper mentioned:

"Consider the traveling salesperson problem again with distances between cities given as the crow flies (Euclidean distance). This problem remains NP-complete but Arora4 gives an efficient algorithm that gets very close to the best possible route."

where his reference is

Arora, S. Polynomial time approximation schemes for Euclidean traveling salesman and other geometric problems. J. ACM 45, 5 (Sept. 1998), 753–782.

While I don't know this paper, there is the highly curious,

Richard M. Karp, "The Probabilistic Analysis of Some Combinatorial Search Algorithms," pages 1-19, 'Algorithms and Complexity: New Directions and Recent Results', edited by J. F. Traub, Academic Press, New York, 1976.

So, here's what to do: Given a traveling salesman problem in the plane (or any finite dimensional space) with just Euclidean distances, pick a city, from that city build a minimum spanning tree connecting all the cities (well-known to be polynomial and fast). Then for the traveling salesman tour, just do a depth-first traversal of that tree except do not 'backtrack' in the tree and revisit cities and, instead, just take the direct link to the next city to be visited in the traversal.

Then for cities selected randomly with meager and reasonable assumptions, and as the number of cities n grows, the solutions have distance as close as we please to optimality with probability as high as we please less than 1.

So, for big problems, as long as all we are trying to do is save some travel distance, no problem. For small problems, enumerate!

Broadly, the question of P versus NP does not connect very well with the real needs of optimization in practice.

Ah, never let the real facts get in the way of an exciting story!


[deleted]


What I said is rock solidly true. I hold a Ph.D. in operations research, was Director of Operations research for a major airline, have worked with a good list of some of the best optimization people in the world, and have attacked several challenging combinatorial optimization problems. I've seen people interested and not interested in optimization and concluded with solid evidence that in general, for the problems I mentioned, for optimization, people don't want to be bothered. Here I'm not lacking "imagination" at all. Again, operations research is a dead duck because people don't want to be bothered.

I don't know your field: If you are looking for some 'exact fit' in the sense of, say, the famous NP-complete problem SAT, then the techniques of optimization may be less powerful. But with very different techniques, there has been progress on SAT.

However there is a large body of research with some solid practical power; maybe some of this research would do well for your problems. At least get good with linear programming and, say, C-PLEX. Then look at the old Gilmore-Gomory column generation where the linear program can have many millions of columns, most not even written down yet. Look really hard at nonlinear duality theory -- for a minimization problem, the dual is always maximizing a continuous, concave function! Then look at Lagrangian relaxation. Of course, finish off with branch and bound. Look at the work at Georgia Tech of G. Nemhauser and E. Johnson. Also note: In practice, a large fraction of integer linear programming problems are in fact least cost network flow problems or closely related, and there we can get optimal solutions very quickly and integer optimal solutions for no extra cost. Look at W. Cunningham's work and also D. Bertsekas's. In general, for really large problems, there is a powerful theme: Continuous approximations work well. Your field may not have good knowledge of such work.

Besides, even if what is known is not good for your problems, history shows in solid terms that for progress on your problems, f'get about anything having to do with P versus NP. For getting the solutions you outlined, for years, P versus NP is a fool's errand.

Here I'm giving you good advice in spite of your insult.


I want to live in a P = NP world. Perhaps airline scheduling isn't something to get excited over, but in my field a P = NP world would be the holy grail.

Imagine being able to engineer proteins. ENGINEER PROTEINS. Not just study them or do domain fusions, but to actually be able to design structures to fill a particular need. We could plug into existing metabolic pathways or we could develop entirely novel ones, complete with complex logic circuitry that models interaction with the physical world.

Pollution would be solved. Energy would be solved. Cells would become a new and quite novel form of both computer and machine. A kind that can self-replicate. A kind that we could now feasibly have a compiler for.

Slightly tangent to biotech, consider the computational investigation of all of chemical space. We could quickly and easily discover novel molecular structures and automate their design. We could develop new synthesis reactions and optimize chemical engineering. The products we buy today--think "mundane" things like plastics, or shampoo--could become space age in a matter of years if P = NP.

Too bad this appears to be a different universe I'm describing. In that world all of the "magic" of the computer industry is essentially ported to all of the science fields.


I have some good news for you: For your goals, likely you do not have to wait for P = NP, even if it is true.

Or, for your goals, you do not need the extreme guarantees of P = NP, that is, guaranteed polynomial solutions for ALL your problems in NP, even the worst case that can exist.

Instead, likely you can make nearly all the progress you have in mind with some techniques that just happen to work well for your class of problems. This is what the history shows. That is, people have been doing well solving NP-complete problems well enough for decades without worrying about P versus NP. So, learn some of what has been done, as I outlined and more, and then add to that material in ways important for your problems.

Just MUST realize that the question of P versus NP has been formulated in a way that makes it often shockingly far from getting valuable results in practice. How can this be? Heavily because the P versus NP question concentrates on the worst cases that can exist, and the average cases in practice can be much, MUCH easier.

For more, pay close attention to the Department of Combinatorics and Optimization at Waterloo and Nemhauser's department at Georgia Tech.

Generally it will be tough for me to believe that the field of DNA biology has much knowledge of that material if only because very few people do. Indeed, your desire for P = NP does indicate that your field lets the P versus NP question keep it from going after the field's holy grail, likely for no good reason. Each protein you can correctly fold, each valuable molecule you can create, can be a big step ahead, even without P = NP. Net, f'get about P versus NP.

Next, as I outlined, even if tomorrow someone shows an algorithm that shows P = NP, there is no guarantee that that algorithm will be 'fast'. Instead, something with integer linear programming, touched up with various techniques, might solve nearly all your problems plenty well and be much faster.

Indeed, as in the classic Klee and Minty paper, the simplex algorithm is not polynomial but in practice it totally knocks the socks off the polynomial interior point algorithms. To be more clear, classic simplex runs in 3m where m is the number of constraints and we get to ignore the number of columns. So, classic simplex runs, in practice, faster than a polynomial of degree 1 in the size of the input data. Still, it's 'exponential' in worst case. There are more details on why in a classic paper by K. Borgward.

The polynomial algorithms for linear programming are way too slow for practice.

So, I'm not just blowing smoke here: DO work on your problems but F'GET about P versus NP.


The last paragraph of the article was inspiring. What you say in (2) is nonsense.

Look at it this way: there are lots of examples when someone sought out to solve one problem and ended up solving another or discovering a new problem -- of which is orthogonal to the original problem.

The author was just conveying the field of complexity has grown tremendously from the nature of this problem being so intractable. See Prof. Papadimitriou et al book Combinatorial Complexity as one example that I'm familiar with.

ASIDE: Also for me, I find the discovery of new problems more exhilarating than the solving established problems via new techniques.


What I said in (2) is not nonsense but actually important in the 'sociology' of that field of research: There are people in the field very much hoping that P versus NP will not be resolved so that they can have long lasting jobs, and you would be naive about people and their tactics to say this is "nonsense".

You seem to be forgetting my introduction that I agree that the question of P versus NP is important. The question is good research, and your point is one reason it is.

Note: Although in computing your use of 'orthogonal' is common, a better word choice would be 'independent' or just 'unrelated'.

For you I will try to be still more clear: When I started working on airline scheduling, I talked to a famous mathematician and explained my airline fleet scheduling problem. Right away he said: "NP-complete" and then dismissed my work as hopeless. He was wrong, badly wrong. Airline fleet scheduling can work quite well in practice, thank you. His blurting out "NP-complete" was just a way to dismiss practical problem solving.

For some good public information on airline fleet scheduling, see the work of Ellis Johnson, then at IBM's Yorktown Heights lab, using IBM's Optimization Subroutine Library (OSL), for American Airlines. Ellis understands NP-complete just fine, but he also knows that it's possible in practice to do quite well on the NP-complete problems of real airlines.

Again, our goals in practice do not have to wait for P versus NP. Read again what I wrote about the cartoon.


Umm... I thought it was a pretty good introductory article, listing well-known and uncontroversial stuff. Yes, a polynomial algorithm might not be actually practical. Everybody knows this, and pointing it out every time P=NP comes up is bordering on cliche. Yes, NP-hard combinatorial optimization problems can have easy instances in practice. Why is that a reason for outrage?


I described the reasons. E.g., hype.

Also, the paper was eager to assume that a polynomial algorithm that showed P = NP would be fast and that the world would then get big savings in airlines, manufacturing, etc., and that's nonsense. Generally we can get all but the last pennies of savings now.

Net, the paper is increasing the high confusion about the problem P versus NP.


These claims are false. We can get savings on a small number of "low-hanging fruit" problems, which are easy to approximate on practical instances - bin packing with many small items, scheduling with many short jobs, 2D Euclidean Hamiltonian cycles. What about, for example, the learning applications that Fortnow mentions? Try your C-PLEX on the problem "find the minimal size circuit that explains this big set of observations". You will not get anywhere. There are many other examples.

It makes sense for the industry to concentrate on making a buck out of the easy instances, and leaving the hard stuff to the academics. However, that is different from claiming that hard instances don't exist.


You wrote"

"However, that is different from claiming that hard instances don't exist."

but I didn't claim that there were no hard instances. Again, even showing P = NP does not guarantee to provide a fast algorithm for "hard instances" in NP. Net. the question P versus NP is a bit far from practice.

Again, a big example is the simplex algorithm: In practice, the algorithm finds optimal solutions in about 3m iterations where m is the number of rows, and we get to forget about the number of columns. So in practice simplex is terrific as a 'polynomial' algorithm: It's faster than a degree 1 polynomial since we get to ignore the number of columns. But, simplex, worst case, is exponential. So, there are polynomial algorithms to replace simplex, but they are all far too slow: If simplex takes too long, then the polynomial algorithms take still longer.

Linear programming is one of the best examples we have for where we had an exponential algorithm and found a polynomial one. The result: The polynomial algorithm sucked.

You wrote:

"find the minimal size circuit that explains this big set of observations".

I tried to skip over that part of the paper to keep my response simple.

First it is not clear what he means by "explains", but I fear that I do know. Basically he wants a 'fit', but this is dangerous. In practice, a good approach to finding such fits is classification and regression trees (CART) complete with a book by L. Breiman and others.

But for a 'fit', commonly that's easy: For some positive integer n and, for i = 1, 2, ..., n, we are given real numbers x(i) and y(i). The x(i) are distinct. Now we want a polynomial p of degree n - 1 so that p(x(i)) = y(i). Okay, how to find p? Easy. I leave it as an exercise. Problem is, p doesn't provide much as 'explanation'.

Generally, 'explanation' is tough to get at in part because it tries to get at causality which, just from data, as in the paper, is super tough to get at.

I mentioned C-PLEX for optimization problems. Not all problems in NP are optimization problems. But, curiously, integer linear programming bites off a lot of NP, and C-PLEX with associated techniques is one of the best approaches to integer linear programming.


It's a speculative "what if" piece, dude. Relax.


It makes me feel good about the $200,000 spent on my education that I got to take classes with two of the people mentioned with important results. One of them, Mulmuley, was the most intimidating professor I ever had, and I felt very lucky to get out of that class with a C.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: