{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Proof\n\nWe show that $n! + 1$ has a prime divisor larger than $n$.\n\n1. Let $n$ be a natural number, and put $N = n! + 1$. Here $n! = 1 \\cdot 2 \\cdots n$, with $0! = 1$.\n2. Since $n! \\ge 1$, $N \\ge 2$. By the [[existence of a prime divisor|0SPBEDVNW1]], there is a [[prime number|0SN0MAEKYX]] $p$ with $p \\mid N$.\n3. Suppose $p \\le n$. Since $p \\ge 2$, $p$ is one of the factors $1, 2, \\dots, n$ of $n!$, so $p$ [[divides|096PW7Q014]] $n!$.\n4. Then $p$ divides $N - n! = 1$. But $p \\ge 2$, and $2$ or more cannot divide $1$. This is a contradiction.\n5. So $p \u003e n$, and in particular $p \\ge n$. This proves the second form of the statement.\n6. Suppose there were only finitely many primes. Let $n$ be one more than the largest of them.\n7. By step 5, there is a prime $p \\ge n$. Then $p$ is larger than every prime, which is impossible. So there are infinitely many primes.\n\n## Idea\n\nEvery number from $2$ to $n$ divides $n!$, so it leaves remainder $1$ when it divides $n! + 1$. Hence every prime factor of $n! + 1$ is larger than $n$, and there is always a prime beyond any given bound.\n",
  "commit": "4a3290d299c8b2cd6493fce2296920ba7f82d942",
  "front": {
    "kind": "proof",
    "msc": [
      "11A41"
    ],
    "name": "Proof of Euclid's theorem using n! + 1",
    "proves": "0292EPPPT0",
    "sources": [
      {
        "locator": "Euclid's proof, Variations",
        "url": "https://en.wikipedia.org/wiki/Euclid%27s_theorem"
      }
    ],
    "tag": "TMXSM5BNVK",
    "uses": [
      "0SN0MAEKYX",
      "0SPBEDVNW1",
      "096PW7Q014"
    ]
  },
  "kind": "proof",
  "link": "https://math2.tamnd.com/node/TMXSM5BNVK/",
  "links": [
    {
      "field": "proves",
      "target": "0292EPPPT0"
    },
    {
      "field": "uses",
      "target": "0SN0MAEKYX"
    },
    {
      "field": "uses",
      "target": "0SPBEDVNW1"
    },
    {
      "field": "uses",
      "target": "096PW7Q014"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/TMXSM5BNVK.md",
  "msc": [
    "11A41"
  ],
  "name": "Proof of Euclid's theorem using n! + 1",
  "prov": null,
  "role": "",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/TMX/TMXSM5BNVK.md",
  "status": null,
  "tag": "TMXSM5BNVK",
  "uri": "m2://TMXSM5BNVK",
  "url": "https://math2.tamnd.com/wiki/proof-of-euclids-theorem-using-n-1/",
  "writing": {
    "tag": "TMXSM5BNVK",
    "kind": "proof",
    "level": "W0",
    "next": [
      {
        "what": "an inventory row",
        "note": "the row of the inventory that the node accounts for",
        "have": 0,
        "want": 1
      }
    ]
  }
}
