Sindbad~EG File Manager

Current Path : /usr/home/beeson/public_html/michaelbeeson/research/otter-lambda/examples/LambdaLogic/
Upload File :
Current File : /usr/home/beeson/public_html/michaelbeeson/research/otter-lambda/examples/LambdaLogic/lambda.html

<p>This example demonstrates the basic facilities for lambda calculus that are built into Otter-&lambda;, and it also demonstrates how beta reduction is combined with ordinary demodulation. With this latter aim in mind, the file provides one demodulator:</p>
<p>x *x = x.</p>
<p>List(sos) then contains the disjunction of several negated goals, so that all the examples can run at once. In this commentary we consider them one at a time, and take the negation signs off so that we can consider the true form of the goal. </p>
<p><strong>Example 1: </strong> ap(ap(lambda(x,lambda(y,x)),c*c),y) = c.</p>
<p>ap(lambda(x,lambda(y,x)),c*c) is reduce by substituting c*c for x in lambda(y,x), so we get lambda(y,c*c). Now when we apply that term to y, we get c*c, which is then demodulated to c. This demonstrates the combination of demodulation with beta-reduction. The beta reduction is actually performed before the demodulation, as indicated here. </p>
<p>  <strong>Example2: </strong>ap(lambda(x,lambda(y,x)),y) = lambda(z,y) </p>
<p>If we were to simply textually replace x by y when reducing the left side, we would get lambda(y,y), which is wrong. The bound variable y on the left must first be renamed to avoid capturing the free variable y when it is substituted. This does happen as it should. </p>
<p><br>
  <strong>Example 3: </strong>lambda(x,x) = lambda(z,z)</p>
<p>These two terms differ by renaming a bound variable, so they should be equal. Indeed they unify.</p>
<p><strong>Example 4: </strong> lambda(z,a) = lambda(z,x) </p>
<p>This is proved with the substitution x = a. </p>
<p><strong>Example 5: </strong>lambda(w,a) = lambda(z,x).</p>
<p>Works the same as the previous example, even though the names of the bound variables are different. </p>
<p> <strong>Example 6: </strong> lambda(x,a) = lambda(z,x) would be illegal input, since x occurs both free and lambda-bound in the same clause.<br>
The bound x would have to be renamed first.  As of June 10, 2004, Otter-&lambda; does not check the input file to enforce this condition, so it is possible to enter illegal input. The principle &quot;garbage in, garbage out&quot; applies. Eventually we will write code to detect and refuse such input.</p>
<p> <br>
</p>
<p>&nbsp; </p>

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists