{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Statement\n\nLet $p$ be an odd prime and let $a$ be a positive integer with $p \\nmid a$.\nThen\n$$\\left(\\frac{a}{p}\\right) = (-1)^{\\sum_{u} \\lfloor a u / p \\rfloor},$$\nwhere the sum runs over the even integers $u = 2, 4, \\dots, p - 1$, and $\\left(\\frac{a}{p}\\right)$ is the [[Legendre symbol|01J8AMV9RS]].\n\n## Remarks\n\nFor example, take $p = 7$ and $a = 3$. The sum is $\\lfloor 6/7 \\rfloor + \\lfloor 12/7 \\rfloor + \\lfloor 18/7 \\rfloor = 0 + 1 + 2 = 3$, so $\\left(\\frac{3}{7}\\right) = -1$.\nA common variant holds for odd $a$: then $\\left(\\frac{a}{p}\\right) = (-1)^{\\sum_{k=1}^{(p-1)/2} \\lfloor k a / p \\rfloor}$.\nThe proof is similar to the proof of [[Gauss's lemma|037ACYXB5Z]].\nEisenstein used the lemma in a proof of [[quadratic reciprocity|085MJS6907]] that counts lattice points in a triangle.\n\n## Explanations\n\n### L1 human\n\nThe lemma turns the question \"is $a$ a square modulo $p$?\" into a count of integer parts of fractions.\nThe parity of the count gives the answer.\n",
  "commit": "f591989ed15704e9d8755a7a5a6426d73de7a3ae",
  "front": {
    "kind": "statement",
    "msc": [
      "11A15"
    ],
    "name": "Eisenstein's lemma",
    "role": "lemma",
    "sources": [
      {
        "locator": "Eisenstein's proof",
        "url": "https://en.wikipedia.org/wiki/Proofs_of_quadratic_reciprocity"
      }
    ],
    "tag": "0XSDBCP4RZ",
    "uses": [
      "01J8AMV9RS",
      "037ACYXB5Z"
    ]
  },
  "kind": "statement",
  "link": "https://math2.tamnd.com/node/0XSDBCP4RZ/",
  "links": [
    {
      "field": "uses",
      "target": "01J8AMV9RS"
    },
    {
      "field": "uses",
      "target": "037ACYXB5Z"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/0XSDBCP4RZ.md",
  "msc": [
    "11A15"
  ],
  "name": "Eisenstein's lemma",
  "prov": null,
  "role": "lemma",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/0XS/0XSDBCP4RZ.md",
  "status": null,
  "tag": "0XSDBCP4RZ",
  "uri": "m2://0XSDBCP4RZ",
  "url": "https://math2.tamnd.com/wiki/eisensteins-lemma/",
  "writing": {
    "tag": "0XSDBCP4RZ",
    "kind": "statement",
    "level": "W0",
    "next": [
      {
        "what": "an inventory row",
        "note": "the row of the inventory that the node accounts for",
        "have": 0,
        "want": 1
      }
    ]
  }
}
