Full search page →

Compare a function with its chord

IntermediateOPT 02 · Convex Functions, Composition and ConjugatesInteractive plot

Description

Measure the Jensen gap while moving between two inputs. A negative gap supplies a concrete counterexample.

Try this: Compare x² with −x² at weight 0.5. Why do both gaps become zero at the endpoints?

Hints

The chapter section that uses this lab:

Lab · Compare a function with its chord

Input
0.5
Chord − function
2.25

The function is no higher than this chord at the selected point.

Try this: Compare x² with −x² at weight 0.5. Why do both gaps become zero at the endpoints?

For endpoints a=−1 and b=2, gap = (1−λ)f(a)+λf(b)−f((1−λ)a+λb). Nonnegative gap on this single segment is not a proof on every domain.

Method sources

Open in the Playground →