root / CSL16 / bc-convergence.tex @ 47
Historique | Voir | Annoter | Télécharger (7,09 ko)
| 1 | 33 | adas | |
|---|---|---|---|
| 2 | 33 | adas | \section{Convergence of Bellantoni-Cook programs}
|
| 3 | 33 | adas | |
| 4 | 34 | adas | \anupam{In this section, use whatever form of the deduction theorem is necessary and reverse engineer precise statement later.}
|
| 5 | 34 | adas | |
| 6 | 34 | adas | |
| 7 | 33 | adas | \subsection{Bellantoni-Cook programs}
|
| 8 | 33 | adas | We first recall the notion of safe recursion on notation from BC. TODO |
| 9 | 33 | adas | |
| 10 | 33 | adas | \anupam{Do we need simultaneous PRN? cf.\ Bellantoni's thesis.}
|
| 11 | 33 | adas | |
| 12 | 33 | adas | \todo{reformulate below for binary words, not natural numbers?}
|
| 13 | 33 | adas | |
| 14 | 33 | adas | \begin{definition}
|
| 15 | 33 | adas | [BC functions] |
| 16 | 33 | adas | BC is the set of functions generated by the following initial functions and closure schemes. |
| 17 | 33 | adas | |
| 18 | 33 | adas | % \paragraph{Initial functions}
|
| 19 | 33 | adas | There are the following initial functions: |
| 20 | 33 | adas | \begin{enumerate}
|
| 21 | 33 | adas | \item The constant function $0$ which takes no arguments and outputs $0 \in \Nat$. |
| 22 | 33 | adas | \item The projection functions $\pi^{m,n}_k ( x_1 , \dots , x_m ; x_{m+1} , \dots, x_{m+n} ) := x_k$ for $n,m \in \Nat$ and $1 \leq k \leq m+n$.
|
| 23 | 33 | adas | \item The successor functions $\succ_i ( ; x) := xi$ for $i = 0,1$. |
| 24 | 33 | adas | \item The predecessor function $\pred (; x) := \begin{cases}
|
| 25 | 33 | adas | 0 & x = 0 \\ |
| 26 | 33 | adas | x' & x = x'i |
| 27 | 33 | adas | \end{cases}$.
|
| 28 | 33 | adas | \item The conditional function $\cond (;x,y,z) := \begin{cases}
|
| 29 | 33 | adas | y & x \mod{2} = 0 \\
|
| 30 | 33 | adas | z & \text{otherwise}
|
| 31 | 33 | adas | \end{cases}$.
|
| 32 | 33 | adas | \end{enumerate}
|
| 33 | 33 | adas | |
| 34 | 33 | adas | There are the following closure properties. |
| 35 | 33 | adas | \begin{enumerate}
|
| 36 | 33 | adas | \setcounter{enumi}{5}
|
| 37 | 33 | adas | \item Predicative recursion on notation. If $g, h_0, h_1 $ are in BC then so is the function $f$ defined by, |
| 38 | 33 | adas | \[ |
| 39 | 33 | adas | \begin{array}{rcl}
|
| 40 | 33 | adas | f(0, \vec v ; \vec x) & := & g(\vec v ; \vec x) \\ |
| 41 | 33 | adas | f (\succ_i u , \vec v ; \vec x ) & := & h_i ( u , \vec v ; \vec x , f (u , \vec v ; \vec x) ) |
| 42 | 33 | adas | \end{array}
|
| 43 | 33 | adas | \] |
| 44 | 33 | adas | for $i = 0,1$, so long as the expressions are well-formed (i.e.\ in number/sort of arguments). |
| 45 | 33 | adas | \item Safe composition. If $g, \vec h, \vec h'$ are in BC then so is $f$ defined by, |
| 46 | 33 | adas | \[ |
| 47 | 33 | adas | f (\vec u ; \vec x) \quad := \quad g ( \vec h(\vec u ; ) ; \vec h' (\vec u ; \vec x) ) |
| 48 | 33 | adas | \] |
| 49 | 33 | adas | so long as the expression is well-formed. |
| 50 | 33 | adas | \end{enumerate}
|
| 51 | 33 | adas | \end{definition}
|
| 52 | 33 | adas | |
| 53 | 33 | adas | |
| 54 | 40 | adas | \anupam{simultaneous recursion?}
|
| 55 | 33 | adas | |
| 56 | 33 | adas | \subsection{Convergence in arithmetic}
|
| 57 | 33 | adas | \begin{theorem}
|
| 58 | 33 | adas | [Convergence] |
| 59 | 40 | adas | If $\Phi(f)$ is an equational specification corresponding to a BC-program defining $f$, then $\cax{\Sigma^N_1}{\pind} \proves \ !\Phi(f) \limp \forall \vec{x}^{!N} . N(f(\vec x))$.
|
| 60 | 33 | adas | \end{theorem}
|
| 61 | 33 | adas | \begin{proof}
|
| 62 | 40 | adas | % We write function symbols in $\arith$ with arguments delimited by $;$, as for BC-programs. |
| 63 | 40 | adas | We show by induction on the structure of a BC-program for $f(\vec u ; \vec x)$ that: |
| 64 | 33 | adas | \begin{equation}
|
| 65 | 40 | adas | \label{eqn:prv-cvg-ih}
|
| 66 | 40 | adas | \Phi(f) \proves \ \forall \vec{u}^{!\nat} . \forall \vec{x}^\nat . \nat(f(\vec u ; \vec x))
|
| 67 | 33 | adas | \end{equation}
|
| 68 | 33 | adas | We give some key cases in what follows. |
| 69 | 33 | adas | |
| 70 | 40 | adas | Suppose $f$ is defined by PRN as: |
| 71 | 33 | adas | \[ |
| 72 | 33 | adas | \begin{array}{rcl}
|
| 73 | 40 | adas | f(0,\vec v ; \vec x) & = & g(\vec v ; \vec x) \\ |
| 74 | 40 | adas | f(\succ_i u , \vec v; \vec x) & = & h_i (u, \vec v ; \vec x , f(u , \vec v ; \vec x)) |
| 75 | 33 | adas | \end{array}
|
| 76 | 33 | adas | \] |
| 77 | 40 | adas | By the inductive hypothesis we already have \eqref{eqn:prv-cvg-ih} for $g,h_0,h_1$ in place of $f$, so let us suppose that $\nat(\vec v)$ and prove,
|
| 78 | 33 | adas | \begin{equation}
|
| 79 | 40 | adas | \forall u^{!\nat} . (\nat(\vec x) \limp \nat(f(u , \vec v ; \vec x) )
|
| 80 | 33 | adas | \end{equation}
|
| 81 | 40 | adas | by $\cax{\Sigma^N_1}{\pind}$ on $u$.
|
| 82 | 33 | adas | |
| 83 | 41 | adas | In the base case we have the following proof, |
| 84 | 33 | adas | \[ |
| 85 | 33 | adas | \vlderivation{
|
| 86 | 41 | adas | \vlin{\rigrul{\limp}}{}{ \seqar \nat (\vec x) \limp \nat (f(\epsilon , \vec v ; \vec x )) }{
|
| 87 | 41 | adas | \vliq{\beta}{}{ \nat (\vec x) \seqar \nat ( f( \epsilon , \vec v ; \vec x) ) }{
|
| 88 | 41 | adas | \vliq{\alpha}{}{ \nat (\vec x) \seqar \nat ( g (\vec v ; \vec x) ) }{
|
| 89 | 41 | adas | \vltr{IH}{\seqar \forall v^{!\nat} . \forall x^\nat . \nat( g(\vec v ; \vec x) ) }{\vlhy{\quad}}{\vlhy{}}{\vlhy{\quad}}
|
| 90 | 41 | adas | } |
| 91 | 41 | adas | } |
| 92 | 41 | adas | } |
| 93 | 41 | adas | } |
| 94 | 41 | adas | \] |
| 95 | 41 | adas | where $\alpha$ is, |
| 96 | 41 | adas | \[ |
| 97 | 41 | adas | \vlderivation{
|
| 98 | 41 | adas | \vliin{\cut}{}{ \nat (\vec x) \seqar \nat ( g (\vec v ; \vec x)) }{
|
| 99 | 41 | adas | \vlin{\rigrul{!}}{}{\seqar !\nat (v)}{
|
| 100 | 41 | adas | \vlin{assump}{}{\seqar \nat (\vec v)}{\vlhy{}}
|
| 101 | 41 | adas | } |
| 102 | 33 | adas | }{
|
| 103 | 41 | adas | \vliin{\cut}{}{ !\nat (\vec v ) , \nat (\vec x) \seqar \nat (g (\vec v ; \vec x )) }{
|
| 104 | 41 | adas | \vlhy{\seqar \forall \vec v^{!\nat} . \forall \vec x^\nat . \nat (g (\vec v ; \vec x)) }
|
| 105 | 41 | adas | }{
|
| 106 | 41 | adas | \vliq{\lefrul{\forall}}{ }{ !\nat (\vec v) , \nat (\vec x) , \forall \vec v^{!\nat} . \forall \vec x^\nat \nat (g(\vec v ; \vec x )) \seqar \nat (g(\vec v ; \vec x )) }{
|
| 107 | 41 | adas | \vlin{\id}{}{\nat (g(\vec v ; \vec x )) \seqar \nat (g(\vec v ; \vec x ))}{\vlhy{}}
|
| 108 | 41 | adas | } |
| 109 | 41 | adas | } |
| 110 | 33 | adas | } |
| 111 | 33 | adas | } |
| 112 | 33 | adas | \] |
| 113 | 41 | adas | and $\beta$ is: |
| 114 | 41 | adas | \[ |
| 115 | 41 | adas | \vlderivation{
|
| 116 | 41 | adas | \vliin{\cut}{}{\nat (\vec x) \seqar \nat ( f ( \epsilon , \vec v ; \vec x ) ) }{
|
| 117 | 41 | adas | \vlhy{\nat (\vec x) \seqar \nat (g (\vec v ; \vec x) ) }
|
| 118 | 41 | adas | }{
|
| 119 | 41 | adas | \vliin{\cut}{}{ \nat (g (\vec v ; \vec x) ) \seqar \nat (f (\epsilon, \vec v ; \vec x) ) }{
|
| 120 | 41 | adas | \vlin{\Phi}{}{ \seqar f(\epsilon , \vec v ; \vec x) = g(\vec v ; \vec x) }{\vlhy{}}
|
| 121 | 41 | adas | }{
|
| 122 | 41 | adas | \vlin{=}{}{\nat ( g(\vec v ; \vec x) ) , f(\epsilon , \vec v ; \vec x) = g(\vec v ; \vec x) \seqar \nat (f (\epsilon, \vec v ; \vec x) ) }{\vlhy{}}
|
| 123 | 41 | adas | } |
| 124 | 41 | adas | } |
| 125 | 41 | adas | } |
| 126 | 41 | adas | \] |
| 127 | 33 | adas | |
| 128 | 40 | adas | For the inductive step, we suppose that $\nat (u)$ and the proof is as follows, |
| 129 | 33 | adas | \[ |
| 130 | 33 | adas | \vlderivation{
|
| 131 | 40 | adas | \vlin{\rigrul{\limp}}{}{ \nat(\vec x) \limp \nat ( f(u, \vec v ; \vec x) ) \seqar \nat (\vec x) \limp \nat( f(\succ_i u , \vec v ; \vec x) ) }{
|
| 132 | 40 | adas | \vliq{\gamma}{}{\nat(\vec x), \nat(\vec x) \limp \nat ( f(u, \vec v ; \vec x) ) \seqar \nat( f(\succ_i u , \vec v ; \vec x) ) }{
|
| 133 | 40 | adas | \vliin{\lefrul{\limp}}{}{\nat(\vec x), \nat(\vec x), \nat(\vec x) \limp \nat ( f(u, \vec v ; \vec x) ) \seqar \nat( f(\succ_i u , \vec v ; \vec x) ) }{
|
| 134 | 40 | adas | \vlin{\id}{}{\nat(\vec x) \seqar \nat (\vec x) }{\vlhy{}}
|
| 135 | 33 | adas | }{
|
| 136 | 40 | adas | \vliq{\beta}{}{ \nat (\vec x) , \nat (f(u , \vec v ; \vec x) ) \seqar \nat ( f(\succ_i u , \vec v ; \vec x) ) }{
|
| 137 | 40 | adas | \vliq{\alpha}{}{ \nat (\vec x) , \nat (f(u , \vec v ; \vec x) ) \seqar \nat ( h_i( u , \vec v ; \vec x , f( u, \vec v ; \vec x )) ) }{
|
| 138 | 40 | adas | \vltr{IH}{ \seqar \forall u^{!\nat}, \vec v^{!\nat} . \forall \vec x^\nat , y^\nat . \nat( h_i (u, \vec v ; \vec x, y) ) }{\vlhy{\quad}}{\vlhy{}}{\vlhy{\quad}}
|
| 139 | 40 | adas | } |
| 140 | 40 | adas | } |
| 141 | 40 | adas | } |
| 142 | 33 | adas | } |
| 143 | 40 | adas | } |
| 144 | 40 | adas | } |
| 145 | 33 | adas | \] |
| 146 | 41 | adas | where the steps indicated $\alpha$ and $\beta$ are analogous to those for the base case, and $\gamma$ is an instance of the general scheme: |
| 147 | 41 | adas | \begin{equation}
|
| 148 | 41 | adas | \label{eqn:nat-cntr-left-derivation}
|
| 149 | 41 | adas | \vlderivation{
|
| 150 | 41 | adas | \vliin{\cut}{}{ \nat (t) , \Gamma \seqar \Delta }{
|
| 151 | 41 | adas | \vlin{\natcntr}{}{ \nat (t) \seqar \nat (t) \land \nat (t) }{\vlhy{}}
|
| 152 | 41 | adas | }{
|
| 153 | 41 | adas | \vlin{\lefrul{\land}}{}{\nat (t) \land \nat (t) , \Gamma \seqar \Delta}{ \vlhy{\nat (t) ,\nat (t) , \Gamma \seqar \Delta} }
|
| 154 | 41 | adas | } |
| 155 | 41 | adas | } |
| 156 | 41 | adas | \end{equation}
|
| 157 | 40 | adas | |
| 158 | 40 | adas | % |
| 159 | 40 | adas | %For the inductive step, we need to show that, |
| 160 | 40 | adas | %\[ |
| 161 | 40 | adas | %\forall x^{!N} . (( N(\vec y) \limp N( f(x, \vec x ; \vec y) ) ) \limp N(\vec y) \limp N(f(\succ_i x , \vec x ; \vec y) ) )
|
| 162 | 40 | adas | %\] |
| 163 | 40 | adas | %so let us suppose that $N(x)$ and we give the following proof: |
| 164 | 40 | adas | %\[ |
| 165 | 40 | adas | %\vlderivation{
|
| 166 | 40 | adas | % \vlin{N\cntr}{}{N(y) \limp ( N(y ) \limp N(f( x , \vec x ; \vec y ) ) ) \limp N(f (\succ_i x , \vec x ; \vec y) ) }{
|
| 167 | 40 | adas | % \vliin{}{}{N(y) \limp N(y) \limp ( N(y ) \limp N(f( x , \vec x ; \vec y ) ) ) \limp N(f (\succ_i x , \vec x ; \vec y) ) }{
|
| 168 | 40 | adas | % \vliin{}{}{ N(y) \limp N(y) \limp ( N(y) \limp N( f(x, \vec x ; \vec y) ) ) \limp N( h_i (x , \vec x ; \vec y , f(x , \vec x ; \vec y) ) ) }{
|
| 169 | 40 | adas | % \vltr{MLL}{( N(\vec y) \limp (N (\vec y) \limp N(f(x, \vec x ; \vec y) )) \limp N(f(x, \vec x ; \vec y)) }{\vlhy{\quad }}{\vlhy{\ }}{\vlhy{\quad }}
|
| 170 | 40 | adas | % }{
|
| 171 | 40 | adas | % \vlhy{2}
|
| 172 | 40 | adas | % } |
| 173 | 40 | adas | % }{
|
| 174 | 40 | adas | % \vlhy{3}
|
| 175 | 40 | adas | %} |
| 176 | 40 | adas | %} |
| 177 | 40 | adas | %} |
| 178 | 40 | adas | %\] |
| 179 | 40 | adas | %TOFINISH |
| 180 | 33 | adas | \end{proof}
|
| 181 | 40 | adas |