{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Proof\n\n1. Suppose first that $n$ is a perfect square, say $n = m^2$ with $m \\ge 0$ an integer. Then $\\sqrt{n} = m$ is rational, so it is not [[irrational|080T2TXVQV]].\n2. Now suppose that $n$ is not a perfect square. Then $n \\ge 2$, since $0 = 0^2$ and $1 = 1^2$. We argue by contradiction.\n3. Assume $\\sqrt{n} = a/b$ with integers $a$ and $b$, $b \\ne 0$. Since $\\sqrt{n} \u003e 0$, we may take $a \u003e 0$ and $b \u003e 0$.\n4. Squaring gives $a^2 = n b^2$.\n5. For a prime $p$ and a positive integer $m$, let $v_p(m)$ be the exponent of $p$ in the prime factorization of $m$. It is well defined by the [[fundamental theorem of arithmetic|084HH1NDCB]].\n6. Uniqueness of factorization gives $v_p(uv) = v_p(u) + v_p(v)$ for positive integers $u$ and $v$: concatenating factorizations of $u$ and $v$ gives the factorization of $uv$.\n7. By steps 4 and 6, $2 v_p(a) = v_p(n) + 2 v_p(b)$ for each prime $p$. So $v_p(n) = 2(v_p(a) - v_p(b))$ is even.\n8. Put $k_p = v_p(n)/2$, a natural number, and $m = \\prod_p p^{k_p}$, a finite product over the primes dividing $n$.\n9. Then $m^2 = \\prod_p p^{v_p(n)} = n$, so $n$ is a perfect square. This contradicts step 2.\n10. So $\\sqrt{n}$ is irrational when $n$ is not a perfect square. With step 1, $\\sqrt{n}$ is irrational if and only if $n$ is not a perfect square.\n\n## Idea\n\nIf $\\sqrt{n} = a/b$, then $n b^2 = a^2$.\nIn $a^2$ and in $b^2$ every prime appears to an even power, so the same holds in $n$, and then $n$ is a square.\n",
  "commit": "4a3290d299c8b2cd6493fce2296920ba7f82d942",
  "front": {
    "kind": "proof",
    "msc": [
      "11J72"
    ],
    "name": "Proof of the irrationality of square roots of non-squares",
    "proves": "0N10YRNNWV",
    "sources": [
      {
        "locator": "Square root of non-square is irrational",
        "url": "https://en.wikipedia.org/wiki/Quadratic_irrational_number"
      }
    ],
    "tag": "WG6EAWSCCP",
    "uses": [
      "084HH1NDCB",
      "080T2TXVQV"
    ]
  },
  "kind": "proof",
  "link": "https://math2.tamnd.com/node/WG6EAWSCCP/",
  "links": [
    {
      "field": "proves",
      "target": "0N10YRNNWV"
    },
    {
      "field": "uses",
      "target": "084HH1NDCB"
    },
    {
      "field": "uses",
      "target": "080T2TXVQV"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/WG6EAWSCCP.md",
  "msc": [
    "11J72"
  ],
  "name": "Proof of the irrationality of square roots of non-squares",
  "prov": null,
  "role": "",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/WG6/WG6EAWSCCP.md",
  "status": null,
  "tag": "WG6EAWSCCP",
  "uri": "m2://WG6EAWSCCP",
  "url": "https://math2.tamnd.com/wiki/proof-of-the-irrationality-of-square-roots-of-non-squares/",
  "writing": {
    "tag": "WG6EAWSCCP",
    "kind": "proof",
    "level": "W0",
    "next": [
      {
        "what": "an inventory row",
        "note": "the row of the inventory that the node accounts for",
        "have": 0,
        "want": 1
      }
    ]
  }
}
