-
-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How can integer factorization be classified as an NP problem if it is not a decision yes or no problem but rather a search problem? #63
Comments
Some ideas:
|
EDIT: Publishing a final answer at: https://cs.stackexchange.com/questions/9664/is-it-necessary-for-np-problems-to-be-decision-problems/128702#128702
The Wikipedia page of NP completeness, and many other sources I've looking into, seems to define NP completeness only for decision problems, i.e. problems for which the solution is either yes or no, or in other words: the output of the Turing machine is one bit long. For example: are two graphs isomorphic? has a yes/no answer, and is classified in that page as NP:
However, other sources, such as the integer factorization wiki page also classify this problem as NP:
But what I don't understand is: integer factorization is not a decision problem itself, but rather what some would classify as a "search problem" since the output is multiple integers, and therefore more than 1 yes or no bit.
Or alternatively: is there any fundamental reason why we don't just extend the definition of NP completeness to: "given the answer to an instance and the instance, can you verify it in polynomial time", regardless of whether the answer is one bit or more? Why do we care about the one bit thing at all in practical terms?
I have also been pointed to the FNP complexity class at: https://stackoverflow.com/questions/40773886/what-are-np-intermediate-problems#comment111064899_40773945 So is that the more correct classification of integer factorization, and is saying that integer factorization is NP just not strictly correct? This appears to be the case, the wiki page clarifies a bit more down below:
linking to https://en.wikipedia.org/wiki/Function_problem
I think that https://cseweb.ucsd.edu/~mihir/cse200/decision-search.pdf "4 Decision vs Search for NP-complete languages" is saying that for NP-complete problems, the having a P solution to the decision problem (e.g. "is there a solution to this SAT problem?") implies that you can get a P solution to the search problem as well by breaking up the larger problem into smaller ones and asking the decision problem on smaller versions (easy to prove for SAT as done at "2 Self-reducibility of SAT"). This could explain why the label NP gets loosely applied both decision and search versions of NP-complete problems.
However, as shown on the integer factorization wiki page, we don't know yet if integer factorization is NP-complete or not, and it is is suspected that it isn't. And, to make matters worse, we already have a P algorithm for the decision version of the problem (can this integer be factored) via the AKS primality test. So in this case, decision vs search could really matter if we force the definition of NP to be only for decision problems: https://cs.stackexchange.com/questions/50767/why-is-not-known-whether-integer-factorization-can-be-done-in-polynomial-time-kn So maybe this is why we need to split NP from FNP: they are only equal in case P = NP.
As an interesting related fact, this page: https://blog.computationalcomplexity.org/2019/01/search-versus-decision.html claims without proof that graph isomorphism search (find the isomorphism) can solved efficiently if you had a P decision oracle. So sometimes, problem structure does seem to imply that efficient decision implies efficient search, even if we are not NP-complete (supposing graph isomorphism is truly not NP-complete). Though this does not seem to always be the case (e.g. so far with integer factorization).
Some related question:
The text was updated successfully, but these errors were encountered: