P vs. NP and the Computational Complexity Zoo (2014) [video]
youtube.com
youtube.com
So when they talk about the problem of finding the number of moves it takes to unscramble a Rubik's cube, you need to translate that into a decision problem in order to place it into one of these classes. If you can then solve the decision problem efficiently, you should be able to use that to solve the computational problem efficiently.
That could be: given a Rubik's cube and an integer k, is it possible to unscramble it in at most k moves.
When the problem is to find the discrete log of a curve point on an Elliptic Curve, the decision version could be: given a point P on a curve of order < 2^n with generator G, and a bitstring x of length at most n, is there a n-bit number k with prefix x such that P = xy * G ?
If you like this, you might also like his only other upload, on Haskell Curry'd book on mathematical philosophy and the foundations of set theory: https://www.youtube.com/watch?v=AmySxYHqQCQ
P vs. NP and the Computational Complexity Zoo (2014) [video] - https://news.ycombinator.com/item?id=9596496 - May 2015 (53 comments)
I meant polynomial time can in practical terms stomp computers even if you are allowed to time travel to a future point in moores law. Maybe n^2 is enough but need to do the math! The derivative is 2n so seems like it depends on n and the problem and of course the constants.
Or maybe human life is just too short to wait for the “42”
By "natural" I mean a problem that one would actually want to solve, not some contrived problem specifically to make it O(n^100) since that's obviously easily possible.
Finding the correct N-bit long (binary) number (that someone is thinking of, they only reply yes or no to a guess). Verifying if the number is correct can be done in Polynomial time yet finding the correct number can only be achieved by trying (brute force) all the 2^N possibilities?
But how do you know that Turing machine couldn't be somehow reverse-engineered to find the number without trying every possibility? You don't know, you're just assuming it. Proving that assumption is the entire point of the problem.
If your problem statement includes the number to be guessed, it's trivial and solvable in linear time without non-determinism.
If it does not include the number to be guessed, then the process of "verifying the solution" has no access to this info by definition too, and it is not possible to verify the solution at all!?
Apart from that, the verifiability of a solution in polynomial time on a deterministic Turing machine is a necessary consequence of a problem being in NP, but the reverse direction does not apply without additional conditions, IIRC.
If you want to say anything interesting about related problems in regard to complexity theory, you'll have to introduce an "oracle".
As far as my knowledge goes, even this doesn't make the problem of "guess an unknown number" without further qualification more interesting.
Maybe it would be a good exercise to apply these ideas to binary search for an unknown number, with the answer (greater, smaller, correct) as an oracle. Of course the number must be computable, which doesn't preclude it from being transcendental. Another interesting rabbit hole :)
It looks as if you exclude any numbers with an infinite decimal representation by allowing an oracle that says "yes" or "no" to a guess — but of course numbers can also be defined using different means, e.g. convergent sum series etc — and we both know that Pi is finite, right?
A formula that can calculate Pi to an arbitrary precision is a finite and complete representation of Pi, just not as a sequence of digits.
Digging further into this would lead away from CS and into Maths, particularly there are old and new discussions about the "existance" of transcendental numbers (irrational would suffice, too). This is a part of our shared scientific basics, at least in any math-adjacent field.
Googling "Nicolas Bourbaki" is at least as interesting as the complexity theory zoo :)
But probably I'm going over my head here since I don't know much about complexity theory apart from faint CS course memories about Cook's theorem.
A kind of nitpicky distinction, but this is such a common misunderstanding.
It's certainly not true in principle that most problems in P have a small exponent. There is no shortage of graph related algorithms in P that have absolutely absurd exponents, like on the order of 10^100. It is true that practical decision problems that are in P have small exponents but that's exactly the point being made, namely that problems in P with large exponents are not practical and hence don't get much attention.
In many applications, the data grows at least as quickly as computer performance. If the fastest known algorithm is superlinear, today's computers take longer to solve today's problems than yesterday's computers solving yesterday's problems. While O(n^2) time algorithms used to be pretty fast in the 80s, today they are often unusable.
This is an active research topic of trying to characterize worst-case assumptions (i.e., the traditional kind) that imply average-case hardness for some problems, with several recent exciting results. See, for instance, an excellent talk here: https://www.youtube.com/watch?v=aQZEsmpbWE0&t=578s
A simpler way to think about this concept in general would be, assume that it's undecidable in ZFC whether every even natural number greater than 2 is the sum of two primes.
Well if it's undecidable in ZFC then it must be true. If it weren't true then it would be possible to present an even number that isn't the sum of two primes, but presenting such a number would be a proof and hence contradict the assumption that it's undecidable. Hence the only way for it to be undecidable in ZFC is if there isn't any such even number, but ZFC is not powerful enough to prove that no such number exists.
This is the subtle difference between decidability and truth. For certain classes of statements (not all), especially ones involving existence, if they are undecidable within ZFC then they must be true.
Another subtlety is that one can never state categorically that a statement is undecidable, a statement can only be undecidable with respect to a formal system, and being undecidable with respect to a formal system does not mean that we can't ever know if that statement is actually true or false, it just means that said formal system is not powerful enough of proving from within that system whether it's true or false.
Assume an algorithm X halts for every input and it's undecidable in ZFC whether X is correct for all inputs. Well if X were incorrect for some input Q, then since X halts for every input, Q could be used to prove in ZFC that X is incorrect. Since we assumed that X's correctness is undecidable in ZFC, it follows that no such X exists.
To better understand the nature of this issue, it boils down to the fact that ZFC can not unambiguously define the natural numbers. For every definition of the natural numbers in ZFC, there are at least two possible interpretations, one interpretation is the actual natural numbers 0, 1, 2, ... where every single natural number consists of a finite sequence of digits. But ZFC will also have another interpretation of the natural numbers which are not the ACTUAL natural numbers but a kind of mutation of the natural numbers, these natural numbers can have an infinite sequence of digits.
In situations where the correctness of an algorithm is undecidable in ZFC, it means that there is some interpretation of the natural numbers, some mutated system of numbers where the algorithm would give the wrong answer. The algorithm gives the correct answer for all ACTUAL natural numbers, but will give an incorrect answer for some mutated "natural number" consisting of an infinite sequence of digits. Because ZFC is not powerful enough to distinguish between the actual natural numbers and the mutated natural numbers, ZFC is not powerful enough to prove that the algorithm is correct for the actual natural numbers.
You can read more about these mutations here:
https://en.wikipedia.org/wiki/Non-standard_model_of_arithmet...
Now you might think that 3SAT isn't about natural numbers, the input for 3SAT is a boolean formula, not a number. Well that's a minor detail since for every single boolean formula, there is a 1-to-1 correspondence to a natural number. So this hypothetical algorithm would be correct for every formula that has a correspondence to an actual natural number, and each of these formulas would consist of a finite sequence of symbols, ∨, ∧, ¬. However, there would also be mutated versions of these formulas that don't correspond to a natural number but do correspond to a mutated natural number. These formulas would consist of an infinite sequence of symbols, ∨, ∧, ¬. Since the algorithm is undecidable in ZFC, then there is some mutated formula for which the algorithm gives an incorrect answer and since ZFC can not distinguish between mutated formulas and actual real formulas, that's where the undecidability lies.
And finally, you may be tempted to think that you can just define the natural numbers in such a way that they must consist of a finite sequence of digits and this whole issue will go away, surely there must be some way we can define the natural numbers so that they consist only of a finite sequence of digits and rid ourselves of these infinite sequence mutations. And well what we know from Godel's incompleteness theorem is that there is a way to do that, but it involves making your system inconsistent.
uhh... huh.
Does the standard construction of the natural numbers in ZFC, if considered in a non-standard model of ZFC, produce a nonstandard model of PA? That's not what I had expected.
err... I guess there isn't necessarily a thing which is considered "the standard model of ZFC", so I guess I mean, "is there a model of ZFC in which the usual construction of the natural numbers, isn't the standard model of the natural numbers?" (where the model of ZFC is I guess a model within another ZFC or some other set theory, and asking whether the set of natural numbers in that model, is the standard one, is asking about how it compares to the model of the natural numbers in the outer set theory)
Anyway, it’s just a thought. Think of it as complexity-poetry.
To be clear, we absolutely need optimists to keep looking at it and learning more.
But the way it is taught often makes it seem like proving or disproving P=NP is just a matter of time, when the safe bet is that it will never be solved.
existential quantifier: “there exists an x such that...”
universal quantifier: “for every x such that..."
NP is the truthyness of yes-instances
co-NP is the truthyness of no-instances
P=co-P but we think NP!=co-NP
NP is the same as a second order logic with an existential second order part.
co-NP is the same as second order logic with a universal second order part.
Consider how the following two are different:
“there exists an x such that there exists a y such that...”
“there exists an x such that for every y such that...”
That is an oversimplified bad example, but set theory, logic, and complexity are were to start.
Gödel is another lens, but the difference between syntactic and symantic completeness causes problems. As well as Gödel dealing with TMs and not the physically unrealizable NTM.
Proving P=NP would have the implication that NP=co-NP
Proving P!=NP would prove the opposite.
IMHO the most likely lottery winning outcome is that we prove that we can't prove P=NP, but that would cause other issues.
More likely we will have to accept the limits of computable proofs and have an unsatisfying result and the problem will stay open.
Of course, it could be that humans, with AI and CRISPR, will soon become that organism, but it seems unlikely to me that this capability wouldn't evolve more naturally with fewer intermediate steps.
Consider, we know that Game of Life is equivalent to a Turing machine. It still doesn't immediately follow that any program you write will be found in a Game of Life. Closest we have there, is folks are able to build a VM in it where they can make a program in another language that they can play in it. Realistically, they should be able to skip the VM phase, but I don't see that happening any time soon. (Oddly, this same example goes for traditional computers. Consider something like sorting networks and contrast them to how we usually sort numbers in a computer.)
Indeed the evidence would tend to point towards big-step being the primary mechanism of speciation (fossil gaps, bizzareness of many intermediary states), but this is such a strange proposition to folks who have a P != NP prior that they tend to dismiss it out of hand.
Kind of like guessing a passcode to a lock. You still try all the combinations, but there are no intermediate steps - you either guess it all at once, or not at all.
If we see a bunch of locks opened by someone who couldn't have had the code, it doesn't mean they had a method to open. They could've just spent a lot of time guessing.
Granted, sometimes those small steps come faster than others, e.g. adaptive radiations. But there's still only so big a change you can make in a single generation that both doesn't immediately render the organism nonviable and gets through all the checks designed to prevent mutations.
Anyway, last I heard the biggest driver for speciation was just reproductive isolation, so unguided genetic drift can make the two sides incompatible.
And there's a high wall. Even if it's in P, calculating the structure of a protein from a functional goal is going to be energetically expensive on the scale of a cell. That's energy the organism could have used for eating or reproduction instead. And before that you have to biochemically represent goals for a protein, and match them with outside stimuli. More complexity, more energy. It doesn't seem worth it; life is already shockingly adaptable. Oh, and if you want arbitrary organelles, multiply all that by 10-1000.
P=NP is an extremely important and deep theoretical problem, but it is very unlikely to have direct practical implications.