{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Statement\n\nFix a standard [[Gödel numbering|MFJXPAF0R0]] of programs, and let $\\varphi^{(k)}_e$ be the partial [[computable function|KZSB5E471K]] of $k$ arguments computed by program $e$.\nLet $m, n \\ge 1$.\nThen there is a [[primitive recursive|5NVA2JRHPV]] function $s^m_n \\colon \\N^{m+1} \\to \\N$ such that for all $e \\in \\N$, $\\bar x \\in \\N^m$ and $\\bar y \\in \\N^n$:\n$$\\varphi^{(n)}_{s^m_n(e, \\bar x)}(\\bar y) \\simeq \\varphi^{(m+n)}_e(\\bar x, \\bar y).$$\nHere $\\simeq$ means that both sides are undefined, or both are defined and equal.\n\n## Remarks\n\nThe program $s^m_n(e, \\bar x)$ first writes the fixed numbers $\\bar x$ in front of its input $\\bar y$, then runs program $e$.\nBuilding this program from $e$ and $\\bar x$ is a simple manipulation of codes, so $s^m_n$ is primitive recursive.\n\nExample: let $e$ be a program for $(x, y) \\mapsto x + y$.\nThen $s^1_1(e, 5)$ is the number of a program for $y \\mapsto 5 + y$, and $x \\mapsto s^1_1(e, x)$ computes an index for \"add $x$\" from $x$.\n\nThe theorem is also called the parameter theorem, and it is due to Kleene.\n\n## Explanations\n\n### L1 human\n\nIf a program takes two inputs and you fix the first one, you get a program with one input.\nThe smn theorem says that the new program can be produced from the old one and the fixed input by a simple mechanical rule.\nIn programming terms, it is partial application, or currying, done on source code.\n\n### L2 human\n\nThe smn theorem is used to turn a construction \"uniform in a parameter\" into a computable function on indices.\nIt is the main tool in the proof of [[Kleene's recursion theorem|F3Z30M606H]].\nIt is also used to build many-one reductions, for example in the proof of [[Rice's theorem|AKDR5YBBE2]].\nNumberings that satisfy the smn theorem and have a universal function are called acceptable, and any two of them are computably isomorphic by a theorem of Rogers.\n",
  "commit": "547b6eddb8f2feb8d579f2d633d22a27b7e132fc",
  "front": {
    "about": [
      "KZSB5E471K"
    ],
    "kind": "statement",
    "msc": [
      "03D20"
    ],
    "name": "Smn theorem",
    "role": "theorem",
    "same_as": {
      "wikidata": "Q1766814",
      "wikipedia": "Smn theorem"
    },
    "sources": [
      {
        "url": "https://en.wikipedia.org/wiki/Smn_theorem"
      }
    ],
    "tag": "YWX4FCFPAP",
    "uses": [
      "KZSB5E471K",
      "MFJXPAF0R0",
      "5NVA2JRHPV"
    ]
  },
  "kind": "statement",
  "link": "https://math2.tamnd.com/node/YWX4FCFPAP/",
  "links": [
    {
      "field": "about",
      "target": "KZSB5E471K"
    },
    {
      "field": "uses",
      "target": "KZSB5E471K"
    },
    {
      "field": "uses",
      "target": "MFJXPAF0R0"
    },
    {
      "field": "uses",
      "target": "5NVA2JRHPV"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/YWX4FCFPAP.md",
  "msc": [
    "03D20"
  ],
  "name": "Smn theorem",
  "prov": null,
  "role": "theorem",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/YWX/YWX4FCFPAP.md",
  "status": null,
  "tag": "YWX4FCFPAP",
  "uri": "m2://YWX4FCFPAP",
  "url": "https://math2.tamnd.com/wiki/smn-theorem/",
  "writing": {
    "tag": "YWX4FCFPAP",
    "kind": "statement",
    "level": "W0",
    "next": [
      {
        "what": "a source with a locator",
        "have": 0,
        "want": 1
      }
    ]
  }
}
