{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Proof\n\nExistence is a known result; we prove uniqueness by [[strong induction|0KMVFSHFGZ]] on $n$, using Euclid's lemma.\n\n1. Let $n$ be a positive integer. By the [[existence of prime factorization|020K0X7HVR]], $n$ has a [[prime factorization|0AEKDFCYFA]] $n = p_1 \\cdots p_k$ with $p_1 \\le \\dots \\le p_k$.\n2. First a claim. Let $p$ be a prime, and let $q_1, \\dots, q_l$ be primes with $l \\ge 1$ and $p \\mid q_1 \\cdots q_l$. Then $p = q_j$ for some $j$.\n3. We prove the claim by induction on $l$. If $p \\mid q_j$ for a prime $q_j$, then $p$ is a positive divisor of $q_j$ other than $1$, so $p = q_j$.\n4. For $l = 1$, step 3 applies directly. For $l \\ge 2$, we have $p \\mid q_1 \\cdot (q_2 \\cdots q_l)$.\n5. By [[Euclid's lemma|051VYKA1EX]], $p \\mid q_1$ or $p \\mid q_2 \\cdots q_l$. In the first case, step 3 gives $p = q_1$. In the second case, the induction hypothesis gives $p = q_j$ with $j \\ge 2$.\n6. Now let $U(n)$ say: any two prime factorizations of $n$ are equal. Assume that $U(m)$ holds for all positive $m \u003c n$.\n7. Let $n = p_1 \\cdots p_k = q_1 \\cdots q_l$ with [[primes|0SN0MAEKYX]] $p_1 \\le \\dots \\le p_k$ and $q_1 \\le \\dots \\le q_l$.\n8. If $n = 1$, then $k = l = 0$, because a product of at least one prime is at least $2$. So the two factorizations are equal.\n9. Let $n \\ge 2$. Then $k \\ge 1$ and $l \\ge 1$.\n10. Since $p_1 \\mid n = q_1 \\cdots q_l$, the claim gives $p_1 = q_j$ for some $j$. So $p_1 \\ge q_1$.\n11. In the same way, $q_1 \\mid p_1 \\cdots p_k$ gives $q_1 = p_i$ for some $i$. So $q_1 \\ge p_1$. Hence $p_1 = q_1$.\n12. Put $m = n / p_1$. Cancelling $p_1 = q_1$ gives $m = p_2 \\cdots p_k = q_2 \\cdots q_l$. Here $1 \\le m \u003c n$, because $p_1 \\ge 2$.\n13. These are two prime factorizations of $m$. By $U(m)$, $k - 1 = l - 1$ and $p_i = q_i$ for $2 \\le i \\le k$.\n14. With step 11, $k = l$ and $p_i = q_i$ for each $i$. So $U(n)$ holds.\n15. By strong induction, $U(n)$ holds for every positive integer $n$. Together with step 1, each positive integer has exactly one prime factorization.\n\n## Idea\n\nThe smallest prime of one factorization divides the other product, so by Euclid's lemma it appears in the other factorization. Comparing the smallest primes on both sides shows that they are equal. Cancelling them gives a smaller number, where induction finishes the job.\n",
  "commit": "4a3290d299c8b2cd6493fce2296920ba7f82d942",
  "front": {
    "kind": "proof",
    "msc": [
      "11A51"
    ],
    "name": "Proof of the fundamental theorem of arithmetic",
    "proves": "084HH1NDCB",
    "sources": [
      {
        "locator": "Proof",
        "url": "https://en.wikipedia.org/wiki/Fundamental_theorem_of_arithmetic"
      }
    ],
    "tag": "CTSV0ZESYF",
    "uses": [
      "0AEKDFCYFA",
      "020K0X7HVR",
      "051VYKA1EX",
      "0SN0MAEKYX",
      "0KMVFSHFGZ"
    ]
  },
  "kind": "proof",
  "link": "https://math2.tamnd.com/node/CTSV0ZESYF/",
  "links": [
    {
      "field": "proves",
      "target": "084HH1NDCB"
    },
    {
      "field": "uses",
      "target": "0AEKDFCYFA"
    },
    {
      "field": "uses",
      "target": "020K0X7HVR"
    },
    {
      "field": "uses",
      "target": "051VYKA1EX"
    },
    {
      "field": "uses",
      "target": "0SN0MAEKYX"
    },
    {
      "field": "uses",
      "target": "0KMVFSHFGZ"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/CTSV0ZESYF.md",
  "msc": [
    "11A51"
  ],
  "name": "Proof of the fundamental theorem of arithmetic",
  "prov": null,
  "role": "",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/CTS/CTSV0ZESYF.md",
  "status": null,
  "tag": "CTSV0ZESYF",
  "uri": "m2://CTSV0ZESYF",
  "url": "https://math2.tamnd.com/wiki/proof-of-the-fundamental-theorem-of-arithmetic/",
  "writing": {
    "tag": "CTSV0ZESYF",
    "kind": "proof",
    "level": "W0",
    "next": [
      {
        "what": "an inventory row",
        "note": "the row of the inventory that the node accounts for",
        "have": 0,
        "want": 1
      }
    ]
  }
}
