{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Statement\n\nLet $P$ be a simple [[polygon|8VEFWD3EJB]] in $\\R^2$ with vertices $(x_1, y_1), \\ldots, (x_n, y_n)$ listed in order along its boundary.\nPut $(x_{n+1}, y_{n+1}) = (x_1, y_1)$.\nThen the area $A$ of the region bounded by $P$ is\n$$A = \\frac{1}{2} \\abs{\\sum_{i=1}^{n} \\left(x_i y_{i+1} - x_{i+1} y_i\\right)}.$$\n\n## Remarks\n\nWithout the absolute value, the sum gives the signed area, which is positive when the vertices run counterclockwise.\nEach term $\\frac{1}{2}(x_i y_{i+1} - x_{i+1} y_i)$ is the signed area of the triangle with vertices $0$, $P_i$, $P_{i+1}$, and these signed areas add up to the area of $P$.\nEquivalently, the formula is [[Green's theorem|0HR3N02317]] applied to the line integral $\\frac{1}{2}\\oint (x \\, dy - y \\, dx)$ along the boundary.\nExample: for the triangle $(0, 0), (4, 0), (0, 3)$ the sum is $0 + 12 + 0 = 12$, so $A = 6$.\nSimplicity is needed: for a self-crossing figure eight the two lobes have opposite orientation, and the sum gives the difference of their areas.\n\n## Explanations\n\n### L1 human\n\nThe shoelace formula computes the area of a polygon from the coordinates of its corners alone.\nWrite the coordinates in two columns, multiply them crosswise like the laces of a shoe, and take half the difference of the two totals.\n\n### L2 human\n\nThe formula is the standard way to compute polygon areas in computational geometry and surveying.\nIt is a discrete case of Green's theorem, and it is also the main tool in many proofs of [[Pick's theorem|K9SBQZMWB9]].\n",
  "commit": "ff8a40749dc16545e3d2fc637f6b0196e81d0bfa",
  "front": {
    "about": [
      "8VEFWD3EJB"
    ],
    "kind": "statement",
    "msc": [
      "51M25",
      "51N20"
    ],
    "name": "Shoelace formula",
    "role": "theorem",
    "same_as": {
      "wikidata": "Q3748369",
      "wikipedia": "Shoelace formula"
    },
    "sources": [
      {
        "url": "https://en.wikipedia.org/wiki/Shoelace_formula"
      }
    ],
    "tag": "SDHZRWMSTT",
    "uses": [
      "8VEFWD3EJB"
    ]
  },
  "kind": "statement",
  "link": "https://tamnd.github.io/math2/node/SDHZRWMSTT/",
  "links": [
    {
      "field": "about",
      "target": "8VEFWD3EJB"
    },
    {
      "field": "uses",
      "target": "8VEFWD3EJB"
    }
  ],
  "markdown": "https://tamnd.github.io/math2/node/SDHZRWMSTT.md",
  "msc": [
    "51M25",
    "51N20"
  ],
  "name": "Shoelace formula",
  "prov": null,
  "role": "theorem",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/SDH/SDHZRWMSTT.md",
  "status": null,
  "tag": "SDHZRWMSTT",
  "uri": "m2://SDHZRWMSTT",
  "url": "https://tamnd.github.io/math2/wiki/shoelace-formula/",
  "writing": {
    "tag": "SDHZRWMSTT",
    "kind": "statement",
    "level": "W0",
    "next": [
      {
        "what": "an inventory row",
        "note": "the row of the inventory that the node accounts for",
        "have": 0,
        "want": 1
      },
      {
        "what": "a source with a locator",
        "have": 0,
        "want": 1
      }
    ]
  }
}
