KKT Conditions and Water-Filling
From Duality to Optimality Conditions
The KKT conditions are the "first-order necessary and sufficient conditions" for convex problems with strong duality. They unify unconstrained optimality () with constraint handling. The most celebrated application in wireless is water-filling: optimal power allocation across parallel channels.
Theorem: Karush–Kuhn–Tucker (KKT) Conditions
Consider a convex problem with differentiable and affine equality constraints. If strong duality holds (e.g., Slater's condition), then is optimal if and only if there exist and such that:
-
Stationarity:
-
Primal feasibility: ,
-
Dual feasibility:
-
Complementary slackness: for all
Complementary slackness says: either a constraint is tight () or its multiplier is zero (). An inactive constraint exerts no "force" on the optimal solution. This is the key to water-filling: channels with too-poor quality get zero power (their constraint is inactive).
Start from the fact that minimises the Lagrangian over .
Use strong duality to show .
Necessity
Since strong duality holds, .
But
(since and ). Combined with the infimum bound, we get equality everywhere.
Complementary slackness
The equality with and forces each product .
Stationarity
Since minimises the (convex) Lagrangian over , the gradient must vanish at : .
Historical Note: The KKT Conditions
1939–1951William Karush derived these conditions in his 1939 master's thesis at the University of Chicago, but the work went largely unnoticed. Harold Kuhn and Albert Tucker independently rediscovered them in 1951. The conditions were initially named "Kuhn–Tucker"; Karush's priority was recognised only in the 1970s.
Definition: Water-Filling Problem
Water-Filling Problem
Consider parallel sub-channels with gains and noise powers . The goal is to maximise the total rate (sum capacity):
where is the power allocated to sub-channel and is the total power budget.
Theorem: Water-Filling Solution
The optimal power allocation for the water-filling problem is
where and the water level is chosen so that .
The quantity is the "noise floor" of sub-channel . The solution "pours water" up to a common level : channels with high noise floors may receive zero power.
Imagine sub-channels as vessels of different heights (the noise floor ). Pouring a fixed volume of water (the power budget ) fills the vessels to a common water level . Tall vessels (poor channels) may not receive any water if the total budget is small.
Write the Lagrangian with multiplier for the power constraint and for .
Apply the KKT stationarity condition: .
Use complementary slackness: either or .
Form the Lagrangian
(We minimise the negative of the rate.)
KKT stationarity
If , then (complementary slackness), so .
Threshold channels
If , then (the channel is too noisy to deserve power). Absorbing into , we write where is determined by the total power constraint.
Example: Water-Filling with 4 Sub-Channels
Given 4 OFDM sub-channels with noise floors and total power , find the optimal power allocation.
Try all channels active
Assume for all . Then , so , giving .
Check positivity
, , , . Channel 4 gets negative power — contradiction.
Remove channel 4
Set . Repeat with 3 active channels: , so . , , , . All non-negative.
Compute rates
for active channels. The total rate is bits/s/Hz.
Water-Filling Animation
Watch water pour into vessels of different heights as the total power budget increases. Observe how channels with high noise floors receive zero power until the water level rises enough.
Parameters
Water-Filling Power Allocation Sweep
Key Takeaway
Water-filling is the prototypical example of KKT in action. Complementary slackness yields the operator: allocate resources only to channels good enough to clear the noise floor. This principle recurs in OFDMA, MIMO spatial multiplexing, and cognitive radio spectrum allocation.
Water-Filling in Practice — From Theory to Standards
The elegant water-filling solution assumes perfect channel state information (CSI) at the transmitter. In real systems, several practical constraints modify the solution:
- Discrete modulation: Power is not allocated continuously but mapped to discrete MCS (modulation and coding scheme) levels. In LTE/5G NR, each resource block uses one of ~30 MCS indices. The effective allocation is a quantised approximation of water-filling.
- Feedback delay: CSI is outdated by the time the transmitter uses it. At vehicular speeds (120 km/h, 3.5 GHz carrier), the coherence time is ms — comparable to the feedback loop. Equal power allocation can outperform water-filling with stale CSI.
- Per-antenna power constraints: Unlike the total power constraint in classic water-filling, practical amplifiers have per-element peak power limits. The resulting optimisation is still convex but no longer admits a closed-form solution.
- Computational cost: For sub-channels, the water-filling algorithm runs in (sorting-based) or (bisection on ). Both are negligible compared to channel estimation.
- •
MCS quantisation: ~30 discrete levels in 5G NR (TS 38.214 Table 5.1.3.1-1)
- •
Feedback delay limits CSI freshness; equal power may be preferable at high mobility
- •
Per-antenna power limits require iterative solvers instead of closed-form water-filling
Why This Matters: Water-Filling in OFDM Systems
In an OFDM system with sub-carriers, each sub-carrier is a parallel sub-channel. If the transmitter knows the channel (via feedback), it applies water-filling to allocate power across sub-carriers. In 5G NR, this is approximated by adaptive modulation and coding (AMC) per resource block.
See full treatment in Transmit Diversity
Common Mistake: Equal Power Allocation Is Not Always Optimal
Mistake:
Assuming that dividing power equally across sub-channels () is optimal.
Correction:
Equal power is optimal only when all sub-channels have the same noise floor. In frequency-selective fading, water-filling significantly outperforms equal allocation, especially at low SNR. At very high SNR, the difference diminishes because all channels are active and the water-level differences become negligible.
Quick Check
In the KKT conditions, complementary slackness states . If a constraint is strictly inactive (), what can we conclude about ?
can be any non-negative value
Correct. Since and , we must have . The inactive constraint exerts no force on the solution.
Deeper Treatment in the ITA Book
Water-filling reappears as the capacity-achieving input distribution for parallel Gaussian channels in information theory (§Capacity with Diversity). The ITA book (Chapters 5–6) provides the full derivation from mutual information maximisation, including the continuous-frequency generalisation and the connection to rate-distortion theory. The MIMO book (Chapter 5) extends water-filling to the spatial domain via SVD precoding: the MIMO channel decomposes into parallel singular-value sub-channels, each receiving water-filled power.
KKT Conditions
Karush–Kuhn–Tucker conditions: necessary and sufficient conditions for optimality in convex problems with strong duality. Comprise stationarity, primal feasibility, dual feasibility, and complementary slackness.
Related: Lagrangian and Lagrangian Dual Function, Complementary Slackness, Water-Filling Problem
Water-Filling
Optimal power allocation across parallel channels: where is the water level determined by the total power constraint.
Related: KKT Conditions, Water-Filling in OFDM Systems, Power Allocation