{
  "aliases": null,
  "backlinks": null,
  "body": "\n## Statement\n\nLet $a_1 \\ge a_2 \\ge \\dots \\ge a_n$ and $b_1 \\ge b_2 \\ge \\dots \\ge b_n$ be real numbers.\nThen\n$$\\frac{1}{n} \\sum_{i=1}^{n} a_i b_i \\ge \\Big( \\frac{1}{n} \\sum_{i=1}^{n} a_i \\Big) \\Big( \\frac{1}{n} \\sum_{i=1}^{n} b_i \\Big).$$\n\n## Remarks\n\nProof idea: expand to get the identity\n$$n \\sum_{i=1}^{n} a_i b_i - \\sum_{i=1}^{n} a_i \\sum_{j=1}^{n} b_j = \\frac{1}{2} \\sum_{i=1}^{n} \\sum_{j=1}^{n} (a_i - a_j)(b_i - b_j).$$\nEach term on the right is $\\ge 0$, because $a_i - a_j$ and $b_i - b_j$ have the same sign for [[monotone sequences|0KN22AAW5R]] ordered the same way.\n\nIf one sequence decreases and the other increases, the inequality is reversed.\nThe common ordering is needed: for $a = (1, 0)$ and $b = (0, 1)$, the left side is $0$ and the right side is $1/4$.\n\nExample: taking $b = a$ gives $n \\sum a_i^2 \\ge (\\sum a_i)^2$, which holds for every real sequence after sorting.\n\nMathlib states a form as `Monovary.sum_mul_sum_le_card_mul_sum`.\n\n## Explanations\n\n### L1 human\n\nIf two lists are sorted in the same order, the average of their products is at least the product of their averages.\nLarge values meet large values, so the products are pushed up.\nFor lists sorted in opposite orders the reverse holds.\n\n### L2 human\n\nThe inequality follows from the [[rearrangement inequality|6E9TAF8HCY]] by summing over the $n$ cyclic shifts of the second sequence.\nIt has an integral form: if $f$ and $g$ are both increasing on $[0, 1]$, then $\\int_0^1 f g \\ge \\int_0^1 f \\int_0^1 g$.\nIn probability it says that two increasing functions of the same random variable have nonnegative covariance.\n",
  "commit": "547b6eddb8f2feb8d579f2d633d22a27b7e132fc",
  "front": {
    "about": [
      "0KN22AAW5R"
    ],
    "kind": "statement",
    "msc": [
      "26D15"
    ],
    "name": "Chebyshev's sum inequality",
    "role": "theorem",
    "same_as": {
      "wikidata": "Q1428736",
      "wikipedia": "Chebyshev's sum inequality"
    },
    "sources": [
      {
        "url": "https://en.wikipedia.org/wiki/Chebyshev%27s_sum_inequality"
      }
    ],
    "tag": "S8X2N1DW8P",
    "uses": [
      "0KN22AAW5R"
    ]
  },
  "kind": "statement",
  "link": "https://math2.tamnd.com/node/S8X2N1DW8P/",
  "links": [
    {
      "field": "about",
      "target": "0KN22AAW5R"
    },
    {
      "field": "uses",
      "target": "0KN22AAW5R"
    }
  ],
  "markdown": "https://math2.tamnd.com/node/S8X2N1DW8P.md",
  "msc": [
    "26D15"
  ],
  "name": "Chebyshev's sum inequality",
  "prov": null,
  "role": "theorem",
  "source": "https://github.com/tamnd/math2/blob/main/nodes/S8X/S8X2N1DW8P.md",
  "status": null,
  "tag": "S8X2N1DW8P",
  "uri": "m2://S8X2N1DW8P",
  "url": "https://math2.tamnd.com/wiki/chebyshevs-sum-inequality/",
  "writing": {
    "tag": "S8X2N1DW8P",
    "kind": "statement",
    "level": "W0",
    "next": [
      {
        "what": "a source with a locator",
        "have": 0,
        "want": 1
      }
    ]
  }
}
