Logarithmic water filling 2026-10-07
To maximize for positive baselines, nonnegative allocations and a positive budget , the KKT conditions equalize the shifted values on allocated coordinates. The unique water level solves . Inactive coordinates have baselines at least the water level. Strict convexity of the negative objective ensures uniqueness, and sorting the baselines gives an efficient water-filling algorithm.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 38 1 a Solution Created 2026-10-03 Updated 2026-10-07
Let . The feasible probability simplex is a nonempty compact convex set, so the extreme value theorem guarantees a minimizer. Its Hessian matrix is diagonal with positive entries , making a strictly convex function. Hence the minimizer is unique.
Use the Lagrange multipliers for the sum constraint and for . The Lagrangian isThe KKT conditions areA strictly positive feasible allocation exists, so the Slater condition holds. These conditions are necessary and sufficient for this convex optimization. At least one coordinate is positive, giving . Put . For a positive coordinate, complementary slackness gives . At a zero coordinate, stationarity gives , or . ThusHere . This logarithmic water filling raises the smaller baseline values to a common level. The scalar left side is a continuous function and strictly increasing above , starts at zero, and tends to infinity, so exactly one solves it. One can find it by interval bisection, or sort the baseline values increasingly and find an index for whichusing . Equality at the next baseline simply gives a zero allocation. Sorting and a running sum implement the water-filling algorithm in time.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 38 1 b Solution Created 2026-10-03 Updated 2026-10-07
The increasing baseline order is . A water-filling algorithm with three active coordinates givesTherefore, in the original coordinate order,The first three shifted coordinates all equal , the fourth remains , and the allocations sum to one. For an explicit KKT certificate take , , and . The strict convexity established above makes this optimum unique.
Past exam of the mathematics course of the University of Cambridge 2018 ib Paper 3 21H i Solution Created 2026-09-24 Updated 2026-10-03
The Lagrange sufficiency theorem says that if a feasible point and nonnegative multipliers satisfy complementary slackness and globally maximizes the Lagrangian function in constrained optimization, then globally solves the constrained maximization problem. Indeed, for every feasible , the signs of the constraints give . Concavity and the Karush-Kuhn-Tucker conditions are a common way to verify the global Lagrangian maximum.
For fixed , A maximizessubject to and . This is a concave function of . On every active coordinate, the multiplier equation isThus A's optimal allocation is given by the water-filling algorithm:where is chosen so that . Coordinates with zero expression receive no resource. This is a water-filling algorithm. The formula gives the optimum when every . If , any already gives A the whole market in that region, so A assigns such coordinates arbitrarily small positive amounts and applies water filling to the remaining budget; without a convention for , the resulting value can be a supremum rather than an attained maximum.