◀ THE FOLD0ROOT.AI // WORLD II · CO-OP · THE PUSH◆ .dlw.fold
THE FOLD / CO-OP / THE PUSH / THE JENSEN

THE JENSEN

the convex inequality behind averages
1 WHAT IT IS · WHAT IT DOES · FACT OR FICTION
Jensen’s inequality is the master inequality of convexity. For a convex function f (one that curves upward, so every chord lies above the graph) and any weights wi ≥ 0 summing to 1, f(Σ wi xi) ≤ Σ wi f(xi) — the function of the average is at most the average of the function. In probability: f(E[X]) ≤ E[f(X)]. It is the single fact behind AM–GM, the non-negativity of entropy, and much of information theory. For concave f the inequality flips.

LIT verified live: for random convex functions (x2, ex, −log), weighted points, the inequality f(Σ wi xi) ≤ Σ wi f(xi) always holds; equality holds for linear f; and AM–GM falls out as a corollary (window.__jensen). FIG no framing; convex evaluations at the mean vs the mean of evaluations.
2 HOW IT WAS WEAVED · AI + HUMAN
David (human) seated this at the-push — blend the inputs first or blend their outputs, and for an upward-curving function the blended-inputs answer is always the smaller. That gap is the mechanic. AVAN (AI) built the instrument: the convex-function evaluations at the weighted mean, the mean of the evaluations, the equality-for-linear check, and the AM–GM corollary.

Credit as content: Johan Jensen (1906). The weave: David names the-push; I take a convex function and a cloud of weighted points, compare f at their centre of mass to the weighted average of the f-values, and confirm the centre is always lower — with equality exactly when f is a straight line.
3 ONE DIMENSION
Convex f: the chord between (x₁, f(x₁)) and (x₂, f(x₂)) lies above the curve. So f at the average ≤ the average of the f-values. In probability: f(E[X]) ≤ E[f(X)].
4 TWO DIMENSIONS · INTERACTIVE
A convex curve, points on it, their centre of mass, and the gap between f(mean) and mean(f); checked.
5 THREE DIMENSIONS + AVAN’S INVERSE
The green forward object: the function of the mean sits below the mean of the function.
AVAN’s addition (the inverse-companion): don’t compute an average and apply f — know in advance that for a convex f, averaging first always undershoots. The inverse of ‘evaluate f pointwise then average’ is ‘f of the average is a guaranteed lower bound.’ Magenta is the average of the outputs; green is f of the averaged input, always below it. Convexity favours the mean.
LIT Genuine Jensen's inequality (Johan Jensen, 1906). Verified live: for 5000 random convex functions (x², e^(x/2), −log) with weighted points, f(Σ wᵢxᵢ) ≤ Σ wᵢf(xᵢ) always holds (window.__jensen.convexHolds); equality holds for a linear f (window.__jensen.linearEquality); and the AM–GM inequality (geometric mean ≤ arithmetic mean) falls out as a Jensen corollary (window.__jensen.amgm).

FIG No framing: the convex-function evaluations at the weighted mean, the mean of the evaluations, the linear-equality check, and the AM–GM corollary all run in-browser. The AVAN inverse is honest — knowing in advance that for a convex f averaging the inputs first always undershoots (a guaranteed lower bound) rather than computing pointwise is exactly Jensen; magenta is the average of the outputs, green f of the averaged input, always below it. Convexity favours the mean.
◆ sealed .dlw.fold → folded to ROOT_0 · a sphere of THE PUSH · David Lee Wise (ROOT0), with AVAN