Answers.Body: <p>One totally intuitive way to introduce the concept is with Excel formulas.  So, imagine in <code>A1</code>, we have the value <code>10</code>.  In <code>B1</code>, we have the formula <code>=power(A1,2)</code>, and in <code>B2</code>, we have the formula <code>=(A1+A1)/A1</code>.  So, at this point, our sheet looks like this:</p>
  
  <pre><code>        A   B   C
      1   10  100
      2       2
  </code></pre>
  
  <p>In actuality, we have now created a literal, and two lambda expressions: $10$, $(\lambda x.(power\, x\, 2))$ and $(\lambda x.(/\, (+\, x\, x)\, x))$.</p>
  
  <p>Now, let's add a formula into <code>C1</code>.  That formula will be: <code>=B1+1</code>.  This is a third $\lambda$ expression: $(\lambda x.(+\, x\, 1))$.  Our sheet now looks like this:</p>
  
  <pre><code>        A   B   C
      1   10  100 101
      2       2
  </code></pre>
  
  <p>Since we are pointing <code>C1</code> to <code>B1</code>, which itself points to <code>A1</code>, we have now created $(\lambda x.(+\, x\, 1))\, (\lambda x.(power\, x\, 2))\, 10$, which resolves now in exactly the way you would expect from the Excel formulas:</p>
  
  <p>$(\lambda x.(+\, x\, 1))\, (\lambda x.(power\, x\, 2))\, 10$</p>
  
  <p>$(\lambda x.(+\, x\, 1))\, (power\, 10\, 2)$</p>
  
  <p>$(+\, (power\, 10\, 2)\, 1))$</p>
  
  <p>$(+\, 100\, 1))$</p>
  
  <p>$101$</p>
  
  <p>Simply re-pointing <code>C1</code> to <code>B2</code> gives us a new lambda expression:</p>
  
  <p>$(\lambda x.(+\, x\, 1))\, (\lambda x.(/\, (+\, x\, x)\, x))\, 10$</p>
  
  <p>Which again, resolves to 3 as you would expect.</p>
  
  <p>What's nice here is that if you get rid of the 10 in <code>A1</code> (you must replace it with a non-number so that Excel does not convert it to 0), you will get <code>#VALUE</code>, because you have created a $lambda$ expression, but not fed in the rightmost value.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-06-12T22:52:48.440Z
Answers.LastActivityDate: 2017-06-13T02:19:33.600Z
Answers.LastEditDate: 2017-06-13T02:19:33.600Z
Answers.UserDisplayName: Ben I.
Body: <p>My students are pretty confused by lambda calculus. I'm looking for a way to start them off. Is there some image or analogy for lambda calculus that I can use to help them understand in the beginning?</p>
  
  <p>My kids are college sophomores, and I would just like to give them a clear way to start thinking about it.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-12T21:05:31.663Z
Comments.Text: Welcome to CSE.SE!  This question needs some more detail.  What is the level of the students in question?  And are you literally only asking for an opener?
Comments.UserDisplayName: Ben I.
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-12T22:48:50.093Z
Comments.Text: It would help us to give better answers if you could tell us the general methods you have tried, and what seems to be the part that they don't grasp. It would also be help if you told us the context for this. Is it in preparation for a functional language, or for closures in a procedural language, or some other context entirely?
Comments.UserDisplayName: Gypsy Spellweaver
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-15T03:05:49.520Z
Comments.Text: How does teaching the Lambda Calculus differ from teaching about functions in math?
Comments.UserDisplayName: Ellen Spertus
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-15T03:06:31.960Z
Comments.Text: I know you asked about images and analogies, not code, but are you using Scheme? It's essentially an interpreter for the Lambda Calculus.
Comments.UserDisplayName: Ellen Spertus
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-07-07T18:16:59.823Z
Comments.Text: Math:   The "There exists" and "For all it is true" equations (don't know how to make the actual symbols here) do the exact same thing as lambda expressions.
Comments.UserDisplayName: Thorbjørn Ravn Andersen
Tags: <teaching-analogy>
Title: How can I explain lambda calculus to my class?
ThreadText: # How can I explain lambda calculus to my class?
  
  (Asked by: username_0 on 2017-06-12)
  
  My students are pretty confused by lambda calculus. I'm looking for a way to start them off. Is there some image or analogy for lambda calculus that I can use to help them understand in the beginning?
  
  My kids are college sophomores, and I would just like to give them a clear way to start thinking about it.
  
  **Tags:** teaching-analogy
  
  > **Comments:**
  > **username_1**: Welcome to CSE.SE!  This question needs some more detail.  What is the level of the students in question?  And are you literally only asking for an opener?  
  > **username_2**: It would help us to give better answers if you could tell us the general methods you have tried, and what seems to be the part that they don't grasp. It would also be help if you told us the context for this. Is it in preparation for a functional language, or for closures in a procedural language, or some other context entirely?  
  > **username_3**: How does teaching the Lambda Calculus differ from teaching about functions in math?  
  > **username_3**: I know you asked about images and analogies, not code, but are you using Scheme? It's essentially an interpreter for the Lambda Calculus.  
  > **username_4**: Math:   The "There exists" and "For all it is true" equations (don't know how to make the actual symbols here) do the exact same thing as lambda expressions.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-06-12. Score: 4 | Accepted answer
  
  One totally intuitive way to introduce the concept is with Excel formulas. So, imagine in `A1`, we have the value `10`. In `B1`, we have the formula `=power(A1,2)`, and in `B2`, we have the formula `=(A1+A1)/A1`. So, at this point, our sheet looks like this:
  
  ```
          A   B   C
      1   10  100
      2       2
  
  ```
  
  In actuality, we have now created a literal, and two lambda expressions: $10$, $(\lambda x.(power\, x\, 2))$ and $(\lambda x.(/\, (+\, x\, x)\, x))$.
  
  Now, let's add a formula into `C1`. That formula will be: `=B1+1`. This is a third $\lambda$ expression: $(\lambda x.(+\, x\, 1))$. Our sheet now looks like this:
  
  ```
          A   B   C
      1   10  100 101
      2       2
  
  ```
  
  Since we are pointing `C1` to `B1`, which itself points to `A1`, we have now created $(\lambda x.(+\, x\, 1))\, (\lambda x.(power\, x\, 2))\, 10$, which resolves now in exactly the way you would expect from the Excel formulas:
  
  $(\lambda x.(+\, x\, 1))\, (\lambda x.(power\, x\, 2))\, 10$
  
  $(\lambda x.(+\, x\, 1))\, (power\, 10\, 2)$
  
  $(+\, (power\, 10\, 2)\, 1))$
  
  $(+\, 100\, 1))$
  
  $101$
  
  Simply re-pointing `C1` to `B2` gives us a new lambda expression:
  
  $(\lambda x.(+\, x\, 1))\, (\lambda x.(/\, (+\, x\, x)\, x))\, 10$
  
  Which again, resolves to 3 as you would expect.
  
  What's nice here is that if you get rid of the 10 in `A1` (you must replace it with a non-number so that Excel does not convert it to 0), you will get `#VALUE`, because you have created a $lambda$ expression, but not fed in the rightmost value.
  
  
  ---
  
  