Problem
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Problem”,“label”:“problem”,“_index”:0}] Definition 1 (Problem). A problem associates each input to an output. Input and output are strings over a finite alphabet . is infinite set of finite strings.
More simply,
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Decision Problem”,“label”:“decision-problem”,“_index”:1}] Definition 2 (Decision Problem).
Every problem has a simpler decision problem.
Prime Factoring
Given an integer , find its prime factors. Integers are represented as cuz binary.
Problem
outputs set of prime factors.
Decision
outputs whether or not has a prime factor smaller than . Can be paired with binary search to solve original problem.
Computation
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Computation”,“label”:“computation”,“_index”:2}] Definition 3 (Computation).
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Language”,“label”:“language”,“_index”:3}] Definition 4 (Language). : subset of strings over
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Recognition”,“label”:“recognition”,“_index”:4}] Definition 5 (Recognition). set of strings that lead to accept is language recognized by machine
[!math|{“type”:“definition”,“number”:“auto”,“setAsNoteMathLink”:false,“title”:“Decision”,“label”:“decision”,“_index”:5}] Definition 6 (Decision). every other string () leads to reject language is decided by the machine