12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- <html lang="en">
- <head>
- <title>Fan - avram - a virtual machine code interpreter</title>
- <meta http-equiv="Content-Type" content="text/html">
- <meta name="description" content="avram - a virtual machine code interpreter">
- <meta name="generator" content="makeinfo 4.13">
- <link title="Top" rel="start" href="index.html#Top">
- <link rel="up" href="Deconstruction.html#Deconstruction" title="Deconstruction">
- <link rel="prev" href="Field.html#Field" title="Field">
- <link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
- <meta http-equiv="Content-Style-Type" content="text/css">
- <style type="text/css"><!--
- pre.display { font-family:inherit }
- pre.format { font-family:inherit }
- pre.smalldisplay { font-family:inherit; font-size:smaller }
- pre.smallformat { font-family:inherit; font-size:smaller }
- pre.smallexample { font-size:smaller }
- pre.smalllisp { font-size:smaller }
- span.sc { font-variant:small-caps }
- span.roman { font-family:serif; font-weight:normal; }
- span.sansserif { font-family:sans-serif; font-weight:normal; }
- --></style>
- </head>
- <body>
- <div class="node">
- <a name="Fan"></a>
- <p>
- Previous: <a rel="previous" accesskey="p" href="Field.html#Field">Field</a>,
- Up: <a rel="up" accesskey="u" href="Deconstruction.html#Deconstruction">Deconstruction</a>
- <hr>
- </div>
- <h5 class="subsubsection">2.7.8.2 Fan</h5>
- <p><a name="index-g_t_0040code_007bfan_007d-294"></a>In cases where a deconstructions would be needed to apply the same
- function to both sides of a pair, the overhead can be avoided by means
- of a property of the virtual machine intended for that purpose.
- <p>A <code>silly</code> definition of <code>fan</code> implying the following theorem is
- helpful in expressing such an application.
- <dl>
- <dt><em>T14</em><dd>[[<code>fan</code>]] <var>f</var> = <code>((nil,nil),((nil,</code><var>f</var><code>),(nil,nil)))</code>
- </dl>
- <p class="noindent">The virtual machine recognizes when an application has the form shown
- above, and uses <var>f</var> as a function to be applied to both sides
- of the argument.
- <dl>
- <dt><em>P13</em><dd>([[<code>fan</code>]] <var>f</var>) <code>(</code><var>x</var><code>,</code><var>y</var><code>)</code> = <code>(</code><var>f</var> <var>x</var><code>,</code><var>f</var> <var>y</var><code>)</code>
- </dl>
- </body></html>
|