{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Statement\n\nLet $X$ be a finite set with $n$ elements, let $d \\ge 0$ be an integer, and let $\\mathcal{F}$ be a [[family|0C21Q694AG]] of subsets of $X$.\nSuppose that $\\mathcal{F}$ has [[VC dimension|14HX3QF45H]] at most $d$, that is, no subset of $X$ with $d + 1$ elements is shattered by $\\mathcal{F}$.\nThen\n$$|\\mathcal{F}| \\le \\sum_{i=0}^{d} \\binom{n}{i}.$$\n\n## Remarks\n\nA stronger statement holds: every family $\\mathcal{F}$ shatters at least $|\\mathcal{F}|$ subsets of $X$, where the empty set counts and is shattered by every nonempty family.\nIt is proved by induction on $n$, splitting $\\mathcal{F}$ according to a fixed element $x$.\nIf the VC dimension is at most $d$, all shattered sets have at most $d$ elements, which gives the lemma.\n\nThe bound is sharp: for $d \\le n$, the family of all subsets of $X$ with at most $d$ elements has VC dimension $d$ and exactly $\\sum_{i \\le d} \\binom{n}{i}$ members.\nFor fixed $d$ the bound is a polynomial of degree $d$ in $n$, while $X$ has $2^n$ subsets.\n\n## Explanations\n\n### L1 human\n\nIf a family of sets cannot realise every pattern on any $d + 1$ points, then it is small: its size grows only like $n^d$ instead of $2^n$.\nSo a single local obstruction forces a strong global limit.\n\n### L2 human\n\nIn learning theory, the lemma bounds the number of ways a class of classifiers with finite [[VC dimension|KCFXR9K3GD]] can label $n$ points.\nThis polynomial growth is the key step in the proof that such classes are learnable from a number of samples that depends on the dimension.\nIn combinatorial geometry it bounds the complexity of set systems such as half-planes, which leads to the existence of small $\\varepsilon$-nets.\n",
  "commit": "efe85cee8dbc57d85bedbacfb97b99d1b7bee843",
  "front": {
    "about": [
      "KCFXR9K3GD"
    ],
    "kind": "statement",
    "msc": [
      "05D05",
      "68Q32"
    ],
    "name": "Sauer–Shelah lemma",
    "role": "lemma",
    "same_as": {
      "wikidata": "Q17156650",
      "wikipedia": "Sauer–Shelah lemma"
    },
    "sources": [
      {
        "url": "https://en.wikipedia.org/wiki/Sauer–Shelah_lemma"
      }
    ],
    "tag": "Y4FQT5WPQJ",
    "uses": [
      "14HX3QF45H",
      "0C21Q694AG",
      "0GBZM0MT0F"
    ]
  },
  "kind": "statement",
  "link": "https://math2.tamnd.com/node/Y4FQT5WPQJ/",
  "links": [
    {
      "field": "about",
      "target": "KCFXR9K3GD"
    },
    {
      "field": "uses",
      "target": "14HX3QF45H"
    },
    {
      "field": "uses",
      "target": "0C21Q694AG"
    },
    {
      "field": "uses",
      "target": "0GBZM0MT0F"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/Y4FQT5WPQJ.md",
  "msc": [
    "05D05",
    "68Q32"
  ],
  "name": "Sauer–Shelah lemma",
  "prov": null,
  "role": "lemma",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/Y4F/Y4FQT5WPQJ.md",
  "status": null,
  "tag": "Y4FQT5WPQJ",
  "uri": "m2://Y4FQT5WPQJ",
  "url": "https://math2.tamnd.com/wiki/sauer-shelah-lemma/",
  "writing": {
    "tag": "Y4FQT5WPQJ",
    "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
      }
    ]
  }
}
