Tuesday, September 20, 2005
Multiplication gone mad with Lambda Calculus
Let's continue on the madness. The multiplication of two numbers x and y can be computed using the lambda function:

(λxyz.x(yz))What is (λxyz.x(yz))22 ?
(λxyz.x(yz))22
(λyz.2(yz))2
(λz.2(2z))
λz.(λxy.x(x(y)))((λuv.u(u(v)))z)
λz.(λxy.x(x(y)))(λv.z(z(v)))
λz.(λy.(λv.z(z(v)))((λv.z(z(v)))(y)))
λz.(λy.(λv.z(z(v)))(z(z(y))))
λz.(λy.(z(z(z(z(y))))))
λzy.(z(z(z(z(y))))) = 4

Comments:
<< Home
Thank you. I was having trouble with this and your example helped me find my mistake. You are a kind person.
Post a Comment
<< Home