Kleene's recursion theorem: Difference between revisions

Content deleted Content added
No edit summary
ref to 'Further reading' | {{reflist|refs}} | from parenthetical referencing (deprecated) to short footnote | -{{Use parenthetical referencing}} | +{{Use shortened footnotes}}
Line 1:
{{Use Harvard referencing|date=August 2020}}
{{distinguish|text=[[Kleene's theorem]] for regular languages}}
{{Use shortened footnotes|date=May 2021}}
{{Format footnotes|date=January 2021|reason=Parenthetical referencing has been [[WP:PARREF|deprecated]]; convert to [[Help:Shortened footnotes|shortened footnotes]].}}
In [[computability theory]], '''Kleene's recursion theorems''' are a pair of fundamental results about the application of [[computable function]]s to their own descriptions. The theorems were first proved by [[Stephen Cole Kleene|Stephen Kleene]] in 1938{{r|Kleene1938}} and appear in his 1952 book ''[[#CITEREFKleene1952|Introduction to Metamathematics]]''.{{sfn|Kleene|1952}} A related theorem, which constructs fixed points of a computable function, is known as '''Rogers's theorem''' and is due to [[Hartley Rogers, Jr.]] .{{harvsfn|Rogers|1967}}.
 
The recursion theorems can be applied to construct [[fixed point (mathematics)|fixed points]] of certain operations on [[computable function]]s, to generate [[quine (computing)|quines]], and to construct functions defined via [[recursive definition]]s.
 
== Notation ==
 
The statement of the theorems refers to an [[admissible numbering]] <math>\varphi</math> of the [[partial recursive function]]s, such that the function corresponding to index <math>e</math> is <math>\varphi_e</math>. In programming terms, <math>e</math> represents a program and <math>\varphi_e</math> represents the function computed by this program.
 
Line 13 ⟶ 11:
 
== Rogers's fixed-point theorem ==
Given a function <math>F</math>, a '''fixed point''' of <math>F</math> is an index <math>e</math> such that <math>\varphi_e \simeq \varphi_{F(e)}</math>. Rogers {{harv|Rogers|1967|loc=§11.2}} describes the following result as "a simpler version" of Kleene's (second) recursion theorem.{{sfn|Rogers|1967|loc=§11.2}}
 
:'''Rogers's fixed-point theorem'''. If <math>F</math> is a total computable function, it has a fixed point.
Line 29 ⟶ 27:
 
=== Fixed-point-free functions ===
A function <math>F</math> such that <math> \varphi_e \not \simeq \varphi_{F(e)}</math> for all <math>e</math> is called '''fixed-point free'''. The fixed-point theorem shows that no total computable function is fixed-point free, but there are many non-computable fixed-point-free functions. '''Arslanov's completeness criterion''' states that the only [[recursively enumerable]] [[Turing degree]] that computes a fixed-point-free function is '''0&prime;''', the degree of the [[halting problem]] .{{harvr|Soare|1987|p=88Soare1987_88}}.
 
A function <math>F</math> such that <math> \varphi_e \not \simeq \varphi_{F(e)}</math> for all <math>e</math> is called '''fixed-point free'''. The fixed-point theorem shows that no total computable function is fixed-point free, but there are many non-computable fixed-point-free functions. '''Arslanov's completeness criterion''' states that the only [[recursively enumerable]] [[Turing degree]] that computes a fixed-point-free function is '''0&prime;''', the degree of the [[halting problem]] {{harv|Soare|1987|p=88}}.
 
== Kleene's second recursion theorem ==
 
The second recursion theorem is a generalization of Rogers's theorem with a second input in the function. One informal interpretation of the second recursion theorem is that it is possible to construct self-referential programs; see "Application to quines" below.
 
Line 41 ⟶ 37:
 
=== Comparison to Rogers's theorem ===
Kleene's second recursion theorem and Rogers's theorem can both be proved, rather simply, from each other .{{harvsfn|Jones|1997|pp=229{{ndash-30}}230}}. However, a direct proof of Kleene's theorem {{harvsfn|Kleene|1952|pp=352{{ndash}}353-3}} does not make use of a universal program, which means that the theorem holds for certain subrecursive programming systems that do not have a universal program.
 
=== Application to quines ===
A classic example using the second recursion theorem is the function <math>Q(x,y)=x</math>. The corresponding index <math>p</math> in this case yields a computable function that outputs its own index when applied to any value .{{harvr|Cutland|1980|p=204Cutland1980_204}}. When expressed as computer programs, such indices are known as '''[[Quine (computing)|quine]]s'''.
 
A classic example using the second recursion theorem is the function <math>Q(x,y)=x</math>. The corresponding index <math>p</math> in this case yields a computable function that outputs its own index when applied to any value {{harv|Cutland|1980|p=204}}. When expressed as computer programs, such indices are known as '''[[Quine (computing)|quine]]s'''.
 
The following example in [[Lisp programming language|Lisp]] illustrates how the <math>p</math> in the corollary can be effectively produced from the function <math>Q</math>. The function <code>s11</code> in the code is the function of that name produced by the [[S-m-n theorem]].
Line 82 ⟶ 77:
 
=== Reflexive programming ===
Reflexive, or [[Reflection (computer programming)|reflective]], programming refers to the usage of self-reference in programs. Jones {{harv|Jones|1997}} presents a view of the second recursion theorem based on a reflexive language.{{sfn|Jones|1997}}
It is shown that the reflexive language defined is not stronger than a language without reflection (because an interpreter for the reflexive language can be implemented without using reflection); then, it is shown that the recursion theorem is almost trivial in the reflexive language.
 
== The first recursion theorem ==
 
While the second recursion theorem is about fixed points of computable functions, the first recursion theorem is related to fixed points determined by enumeration operators, which are a computable analogue of inductive definitions. An '''enumeration operator''' is a set of pairs (''A'',''n'') where ''A'' is a ([[Gödel number|code]] for a) finite set of numbers and ''n'' is a single natural number. Often, ''n'' will be viewed as a code for an ordered pair of natural numbers, particularly when functions are defined via enumeration operators. Enumeration operators are of central importance in the study of [[enumeration reducibility]].
 
Line 100 ⟶ 94:
 
=== Example ===
 
Like the second recursion theorem, the first recursion theorem can be used to obtain functions satisfying systems of recursion equations. To apply the first recursion theorem, the recursion equations must first be recast as a recursive operator.
 
Line 126 ⟶ 119:
 
=== Proof sketch for the first recursion theorem ===
 
The proof of part 1 of the first recursion theorem is obtained by iterating the enumeration operator Φ beginning with the empty set. First, a sequence ''F''<sub>''k''</sub> is constructed, for <math>k = 0, 1, \ldots</math>. Let ''F''<sub>0</sub> be the empty set. Proceeding inductively, for each ''k'', let ''F''<sub>''k'' + 1</sub> be <math>F_k \cup \Phi(F_k)</math>. Finally, ''F'' is taken to be <math>\bigcup F_k</math>. The remainder of the proof consists of a verification that ''F'' is recursively enumerable and is the least fixed point of Φ. The sequence ''F''<sub>''k''</sub> used in this proof corresponds to the Kleene chain in the proof of the [[Kleene fixed-point theorem]].
 
Line 132 ⟶ 124:
 
=== Comparison to the second recursion theorem ===
Compared to the second recursion theorem, the first recursion theorem produces a stronger conclusion but only when narrower hypotheses are satisfied. Rogers {{harv|Rogers|1967}} uses the term '''weak recursion theorem''' for the first recursion theorem and '''strong recursion theorem''' for the second recursion theorem.{{sfn|Rogers|1967}}
 
Compared to the second recursion theorem, the first recursion theorem produces a stronger conclusion but only when narrower hypotheses are satisfied. Rogers {{harv|Rogers|1967}} uses the term '''weak recursion theorem''' for the first recursion theorem and '''strong recursion theorem''' for the second recursion theorem.
 
One difference between the first and second recursion theorems is that the fixed points obtained by the first recursion theorem are guaranteed to be least fixed points, while those obtained from the second recursion theorem may not be least fixed points.
Line 140 ⟶ 131:
 
== Generalized theorem ==
In the context of his theory of numberings, [[Yury Yershov|Ershov]] showed that Kleene's recursion theorem holds for any [[precomplete numbering]] .{{harvr|Barendregt|Terwijn|2019|p=1151BarendregtTerwijn2019_1151}}. A Gödel numbering is a precomplete numbering on the set of computable functions so the generalized theorem yields the Kleene recursion theorem as a special case. <ref>See {{harvharvnb|Ershov|1999|loc=§4.14}} for a survey in English.</ref>
 
Given a precomplete numbering <math>\nu</math>, then for any partial computable function <math>f</math> with two parameters there exists a total computable function <math>t</math> with one parameter such that
Line 151 ⟶ 142:
 
== References ==
* {{Cite book |last=Ershov |first=Yuri L. |author-link=Yury Yershov |date=1999 |chapter=Part 4: Mathematics and Computability Theory. 14. Theory of numbering |editor-last=Griffor |editor-first=Edward R. |title=Handbook of Computability Theory |series=Studies in logic and the foundations of mathemtics |volume=140 |___location=Amsterdam |publisher=[[Elsevier]] |pp=473-503 |isbn=9780444898821 |oclc=162130533 |access-date=6 May 2020 |url=https://books.google.com/books?id=KqeXZ4pPd5QC
* {{Cite journal|last1=Barendregt|first1=Henk|author-link1=Henk Barendregt|last2=Terwijn|first2=Sebastiaan A.|date=2019|title=Fixed point theorems for precomplete numberings|url=http://www.sciencedirect.com/science/article/pii/S016800721930048X|journal=Annals of Pure and Applied Logic|language=en|volume=170|issue=10|pages=1151{{ndash}}1161|doi=10.1016/j.apal.2019.04.013|hdl=2066/205967|s2cid=52289429|issn=0168-0072|access-date=6 May 2020|url-access=subscription|hdl-access=free}}
}}
* {{Cite book|last=Cutland|first=Nigel J.|author-link=Nigel Cutland|date=1980|title=Computability: An Introduction to Recursive Function Theory|url=https://books.google.com/books?id=wAstOUE36kcC|publisher=[[Cambridge University Press]]|language=en|doi=10.1017/cbo9781139171496|isbn=9781139935609|oclc=488175597|access-date=6 May 2020}}
* {{Cite book |last=ErshovJones |first=YuriNeil D. L|author-link=YuryNeil Yershov|editor-last=Griffor|editor-first=EdwardD. Jones R|date=1999|url=https://books.google.com/books?id=KqeXZ4pPd5QC1997 |title=Handbook of Computability Theory|chapter=Partand 4complexity: MathematicsFrom anda ComputabilityProgramming Theory.Perspective 14. Theory of numbering|series___location=Studies[[Cambridge, in logic and the foundations ofMassachusetts]] mathemtics|volume=140|pages=473{{ndash}}503|publisher=[[ElsevierMIT Press]] |___locationisbn=Amsterdam|language=en9780262100649 |oclc=162130533|isbn=9780444898821|access-date=6 May 2020}}981293265
}}
* {{Cite journal|last=Kleene|first=S. C.|author-link=Stephen Cole Kleene|date=1938|title=On notation for ordinal numbers|url=http://www.thatmarcusfamily.org/philosophy/Course_Websites/Readings/Kleene%20-%20Ordinals.pdf|journal=[[Journal of Symbolic Logic]]|language=en|volume=3|issue=4|pages=150{{ndash}}155|doi=10.2307/2267778|jstor=2267778|issn=0022-4812|access-date=6 May 2020}}
* {{Cite book |last=Kleene |first=S.Stephen C. |author-link=Stephen Cole Kleene |date=1952 |title=Introduction to Metamathematics |urlseries=https://archive.org/details/BubliothecaMathematicaStephenColeKleeneIntroductionToMetamathematicsWoltersNoordhoffPublishing1971Bibliotheca Mathematica |publisher=[[North-Holland Publishing]]|language=en|series=Bibliotheca Mathematica|isbn=9780720421033 |oclc=459805591 |url=https://archive.org/details/BubliothecaMathematicaStephenColeKleeneIntroductionToMetamathematicsWoltersNoordhoffPublishing1971 |access-date=6 May 2020}}
}}
* {{Cite journal|last1=Jockusch|first1=C. G.|author-link1=Carl Jockusch|last2=Lerman|first2=M.|last3=Soare|first3=R. I.|author-link3=Robert I. Soare|last4=Solovay|first4=R. M.|author-link4=Robert M. Solovay|date=1989|title=Recursively enumerable sets modulo iterated jumps and extensions of Arslanov's completeness criterion|journal=[[The Journal of Symbolic Logic]]|language=en|volume=54|issue=4|pages=1288{{ndash}}1323|doi=10.1017/S0022481200041104|jstor=2274816|issn=0022-4812}}
* {{Cite book |last=JonesRogers |first=NeilHartley D.|date=1997|author-link=NeilHartley DRogers Jr. Jones|date=1967 |title=ComputabilityTheory of recursive functions and complexity:effective Fromcomputability a|___location=[[Cambridge, ProgrammingMassachusetts]] Perspective|publisher=[[MIT Press]] |isbn=97802621006499780262680523 |___locationoclc=Cambridge,933975989 Massachusetts|languageaccess-date=en6 May 2020 |oclcurl-access=981293265registration |url=https://archive.org/details/theoryofrecursiv00roge}}
 
* {{Cite book|last=Rogers|first=Hartley|author-link=Hartley Rogers Jr.|date=1967|title=Theory of recursive functions and effective computability|url=https://archive.org/details/theoryofrecursiv00roge|publisher=[[MIT Press]]|___location=Cambridge, Massachusetts|language=en|oclc=933975989|isbn=9780262680523|access-date=6 May 2020|url-access=registration}}
'''Footnotes'''
* {{Cite book|last=Soare|first=R. I.|author-link=Robert I. Soare|title=Recursively Enumerable Sets and Degrees: A Study of Computable Functions and Computably Generated Sets|series=Perspectives in Mathematical Logic|date=1987|publisher=[[Springer-Verlag]]|isbn=9780387152998|___location=Berlin; New York|language=en|oclc=318368332}}
{{reflist|refs=
*<ref name=Kleene1938>{{Cite journal |last=Kleene |first=S.Stephen C. |author-link=Stephen Cole Kleene |date=1938 |title=On notation for ordinal numbers|url=http://www.thatmarcusfamily.org/philosophy/Course_Websites/Readings/Kleene%20-%20Ordinals.pdf |journal=[[Journal of Symbolic Logic]]|language=en |volume=3 |issue=4 |pagespp=150{{ndash}}-155 |issn=0022-4812 |doi=10.2307/2267778 |jstor=2267778|issn=0022-4812 |access-date=6 May 2020 |url=http://www.thatmarcusfamily.org/philosophy/Course_Websites/Readings/Kleene%20-%20Ordinals.pdf}}</ref>
 
*<ref name=Soare1987_88>{{Cite book |last=Soare |first=R. I. |author-link=Robert I. Soare |date=1987 |title=Recursively Enumerable Sets and Degrees: A Study of Computable Functions and Computably Generated Sets|series=Perspectives in Mathematical Logic |date___location=1987Berlin and New York City |publisher=[[Springer-Verlag]] |isbnp=978038715299888 |___locationisbn=Berlin;9780387152998 New York|language=en|oclc=318368332}}</ref>
 
*<ref name=Cutland1980_204>{{Cite book |last=Cutland |first=Nigel J. |author-link=Nigel Cutland |date=1980 |title=Computability: An Introduction to Recursive Function Theory |urlpublisher=[[Cambridge University Press]] |at=[https://books.google.com/books?id=wAstOUE36kcC|publisher&pg=[[CambridgePA204 Universityp. Press]204] |languageisbn=en9781139935609 |doi=10.1017/cbo9781139171496|isbn=9781139935609 |oclc=488175597 |access-date=6 May 2020 |url=https://books.google.com/books?id=wAstOUE36kcC}}</ref>
 
*<ref name=BarendregtTerwijn2019_1151>{{Cite journal |last1=Barendregt |first1=Henk |author-link1=Henk Barendregt |last2=Terwijn |first2=Sebastiaan A. |date=2019 |title=Fixed point theorems for precomplete numberings|url=http://www.sciencedirect.com/science/article/pii/S016800721930048X |journal=Annals of Pure and Applied Logic|language=en |volume=170 |issue=10 |pagespp=1151{{ndash}}-1161 |issn=0168-0072 |doi=10.1016/j.apal.2019.04.013 |hdl=2066/205967 |s2cidhdl-access=52289429free |issns2cid=0168-007252289429 |access-date=6 May 2020 |url-access=subscription |hdl-accessurl=freehttp://www.sciencedirect.com/science/article/pii/S016800721930048X }} p. 1151.</ref>
}}
 
==Further reading==
* {{Cite journal |last1=Jockusch |first1=C. G. |author-link1=Carl Jockusch |last2=Lerman |first2=M. |last3=Soare |first3=R. I. |author-link3=Robert I. Soare |last4=Solovay |first4=R. M. |author-link4=Robert M. Solovay |date=1989 |title=Recursively enumerable sets modulo iterated jumps and extensions of Arslanov's completeness criterion |journal=[[The Journal of Symbolic Logic]]|language=en |volume=54 |issue=4 |pagespp=1288{{ndash}}-1323 |issn=0022-4812 |doi=10.1017/S0022481200041104 |jstor=2274816|issn=0022-4812}}
 
== External links ==