Past exam of the mathematics course of the University of Cambridge 2017 ii Paper 3 11H b Solution Created 2026-09-24 Updated 2026-10-05
The S-m-n theorem says that parameters can be compiled effectively into program indices: for a standard effective numbering, there is a total computable function with for partial computable functions of arguments.
Write , a recursively enumerable halting problem. If is recursively enumerable, make a program with parameter which ignores its input and runs a semidecision procedure for , halting when that procedure halts. By the S-m-n theorem its index is total computable and . Conversely, implies that is recursively enumerable by the previous construction. Thus .
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 135 4 Solution Created 2026-10-03 Updated 2026-10-05
A many-one reduction is a total computable function with . A Turing reduction is an oracle machine which decides with oracle . It may make several adaptive queries and combine their answers. Every many-one reduction is a Turing reduction, by asking the single question . The converse fails: for the diagonal halting set , its complement is Turing-reducible to by reversing one oracle answer, but is not many-one reducible to . Such a reduction would make the complement computably enumerable, contradicting undecidability of the halting problem.
The Friedberg–Muchnik theorem asserts that there are computably enumerable sets with incomparable Turing degrees:Here is a finite-injury priority construction proving it. Enumerate all Turing functionals and put the requirements in the priority orderStart with . Each requirement has a fresh witness, a waiting or acted status, and a restraint on the other set. A restraint forbids lower-priority strategies from enumerating numbers below into that oracle. Globally remember all previously chosen witnesses, including abandoned ones, and never choose any of them again.
For , choose an unused witness outside , larger than the stage and every current higher-priority restraint. Keep it out of . Wait until the bounded simulation converges with value zero. If this happens, enumerate into , put a restraint on , where is one more than the largest oracle query in the observed computation, and mark the strategy acted. For , interchange and .
At stage , consider the first requirements. Choose the highest-priority one needing a witness or waiting with an observed zero computation. Perform its indicated action, then initialize all lower-priority requirements: abandon their witnesses, clear their restraints, and reset their status. Do nothing if no requirement needs attention. Since witness selection respects higher restraints, and higher actions initialize every lower strategy, all protected computations are respected by lower-priority enumerations. Each stage is a finite effective calculation, so and are computably enumerable sets.
Verify by induction along the priority order that every requirement is initialized only finitely often and acts only finitely often. The highest requirement chooses one witness and can diagonalize at most once. After all higher requirements have finished acting, the next requirement is never again initialized; it obtains a final witness and can diagonalize at most once. This proves finite injury for every requirement and ensures that no requirement is permanently starved by higher attention.
Consider after its last initialization. If it acts, its witness belongs to , while the protected computation with oracle remains zero: higher strategies no longer act and lower ones respect its restraint. Thus . If it never acts, its private witness remains outside . Were , the computation on that witness would converge to zero with a finite oracle use. Since the increasing sets eventually agree with on this finite initial segment, a sufficiently late bounded simulation would detect that computation and make act, a contradiction. The symmetric argument verifies every .
Thus the two sets have incomparable Turing degrees. Both are noncomputable, since a computable set is Turing-reducible to every oracle. Both are also strictly below the degree of the halting problem: every computably enumerable set is Turing-reducible to , while completeness of one would make the other reducible to it. This supplies the intermediate degrees sought in Post problem.
Past exam of the mathematics course of the University of Cambridge 2018 ii Paper 1 12G b Solution Created 2026-09-24 Updated 2026-10-03
A many-one reduction is a total computable function such thatIf is a computably enumerable set, compute and run a semidecision procedure for on that value. It halts exactly when , equivalently exactly when . Therefore is computably enumerable.
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 3 12H a Solution Created 2026-09-24 Updated 2026-10-03
Fix an acceptable effective enumeration of the -ary partial computable functions. The S-m-n theorem states that for every there is a total computable function such thatwhere means that both sides have the same value when defined and are otherwise both undefined.
The recursion theorem states that every total computable transformation of program indices has a semantic fixed point: there is an such that
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 1 12F b Solution Created 2026-09-24 Updated 2026-09-29
The partial recursive functions form the smallest class containing the zero function, successor function, and projection functions and closed under composition, primitive recursion, and unbounded minimization.
Fix a register machine with inputs. By the permitted result, its complete configuration after steps,is a recursive function of the inputs and time. The predicate saying that this configuration is halted is therefore recursive. Its halting time is the partial recursive functionwhere unbounded minimization is undefined when no halting time exists. Extracting the output register from a configuration is recursive, sois partial recursive. Hence every partial computable function is partial recursive.
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 2 4F i Solution Created 2026-09-24 Updated 2026-09-29
A subset is recursive when its indicator function is a total computable function. It is recursively enumerable when it is the domain of a partial computable function, equivalently when an algorithm can enumerate its members.
If is recursive, its indicator decides both and its complement, so both sets are recursively enumerable. Conversely, suppose programs enumerate and . On input , run the two enumerations in parallel by dovetailing. Exactly one must eventually print ; accept in the first case and reject in the second. This algorithm always halts and decides . Hence
Past exam of the mathematics course of the University of Cambridge 2021 iii Paper 120 5 Solution 2026-09-28
Fix an effective enumeration of the unary partial computable functions. Suppose the setwere computably enumerable, say as . Thenwould be a total computable function. Hence for some , buta contradiction. Thus the set of Gödel numbers of total computable functions is not recursively axiomatizable; this is the totality problem is not computably enumerable argument.
Let be a recursively axiomatized theory of arithmetic. For each program index , fix an arithmetical sentenceexpressing that the computation with index halts on every input. Enumerate all formal -proofs and output whenever a proof ending in appears. This enumerates exactly the Gödel numbers of the computable functions that proves total, namely the provably total computable functions, so that set is recursively axiomatizable.
Assume now that is sound. Repeat every discovered index indefinitely, obtaining an effective infinite list of the functions whose totality proves. DefineSoundness makes every genuinely total, so is total and computable. If proved its totality, an index for would occur in the list, say , and thenwhich is impossible. Thus is a total computable function whose totality is not provable in .
Past exam of the mathematics course of the University of Cambridge 2021 ii Paper 1 12F iii Solution Created 2026-09-24 Updated 2026-09-25
Let , where is the total primitive-recursive parity function from part (ii), and apply unbounded minimization in :If is even, then and . If is odd, then for every , so the search never terminates and is undefined. Hence is partial recursive. Because every function built without minimization is total, cannot be defined without minimization; the functions and can.
It remains to characterize the functions built using only the initial functions and composition. They are exactly the functionsfor some and some input coordinate .
Indeed, the zero function is the first form, the successor function and each projection function have the second form, and composing functions of these forms preserves the classification: a constant outer function remains constant, while an outer function selects one inner function and adds . This proves necessity by structural induction. Conversely, applying the successor function times to zero produces the constant , and applying it times to produces .
Every function in this class is directly computable: an algorithm either writes the fixed constant , or copies the th input and performs successor steps.
Past exam of the mathematics course of the University of Cambridge 2021 ii Paper 1 4F Solution Created 2026-09-24 Updated 2026-09-25
The S-m-n theorem states that for every there is a total computable function satisfyingwhenever either side is defined.
Suppose first that is recursively enumerable. Choose a program that halts exactly on inputs in , and let index a two-variable program that, on , ignores and runs that program on . By the S-m-n theorem,is total computable and indexes the unary functionThereforeThus .
Conversely, suppose through a total computable . On input , compute and simulate machine on its own code. This procedure halts exactly when , equivalently exactly when . Hence is recursively enumerable. We have proved the many-one completeness of the halting problem:
Past exam of the mathematics course of the University of Cambridge 2023 ii Paper 2 4I b iii Solution Created 2026-09-24 Updated 2026-09-25
Suppose for a partial computable function . Since , fix . Decode each input as a pair . Using the truncated computation function, defineThis is a total computable function, and every output lies in . Conversely, if , choosing at least the halting time gives an input with . Thus , proving (iii)(iv).
Past exam of the mathematics course of the University of Cambridge 2023 ii Paper 2 4I b iv Solution Created 2026-09-24 Updated 2026-09-25
Suppose for a total computable function . Effectively enumerate the words as . On input , computein order and halt as soon as one equals . Every individual computation terminates because is total. The search halts exactly for , so is computably enumerable. This proves (iv)(i) and completes the equivalence recorded by the domain and range characterizations of a nonempty computably enumerable set.
Recursive presentation of a structure 2026-10-06
A recursive presentation identifies the domain of a countable structure with a computable set, with its basic operations given by total computable functions and its basic relations decidable. In a fixed finite signature this makes evaluation of atomic formulas effective. A countable structure may have a recursive presentation of a structure only for some choices of presentation, or none at all.
Enumerate all valid unary primitive recursive functions in intension by their decidable codes , and interpret each extension . The function is a total computable function, since each finite construction terminates. If it were primitive recursive, some would equal , giving . Repeated extensions in the syntax enumeration do not affect this argument.
Total computable function Created 2026-09-24 Updated 2026-09-24