Convex Sets and Convex Functions

Why Convexity Is the Dividing Line

In wireless system design we constantly solve optimization problems — allocating power, designing beamformers, scheduling users. The fundamental question is: can we find the global optimum efficiently?

The answer hinges on convexity. If an optimization problem is convex, every local minimum is a global minimum, and efficient polynomial-time algorithms exist. If not, we generally face NP-hard problems and must settle for heuristics.

This section develops the vocabulary: convex sets, convex functions, and the key tests for verifying convexity.

Definition:

Convex Set

A set CRn\mathcal{C} \subseteq \mathbb{R}^n is convex if for every x,yC\mathbf{x}, \mathbf{y} \in \mathcal{C} and every θ[0,1]\theta \in [0, 1],

θx+(1θ)yC.\theta \mathbf{x} + (1 - \theta) \mathbf{y} \in \mathcal{C}.

In words: the line segment connecting any two points in C\mathcal{C} lies entirely within C\mathcal{C}.

The empty set \emptyset and singletons {x0}\{\mathbf{x}_0\} are convex by convention (the line-segment condition is vacuously satisfied).

Example: Standard Examples of Convex Sets

Verify that each of the following sets is convex:

  1. Hyperplane: {xRn:aTx=b}\{\mathbf{x} \in \mathbb{R}^n : \mathbf{a}^T \mathbf{x} = b\}
  2. Halfspace: {xRn:aTxb}\{\mathbf{x} \in \mathbb{R}^n : \mathbf{a}^T \mathbf{x} \leq b\}
  3. Euclidean ball: B(x0,r)={x:xx0r}\mathcal{B}(\mathbf{x}_0, r) = \{\mathbf{x} : \|\mathbf{x} - \mathbf{x}_0\| \leq r\}
  4. Ellipsoid: E={x:(xxc)TP1(xxc)1}\mathcal{E} = \{\mathbf{x} : (\mathbf{x} - \mathbf{x}_c)^T \mathbf{P}^{-1} (\mathbf{x} - \mathbf{x}_c) \leq 1\} where P0\mathbf{P} \succ 0.

Definition:

Convex Cone

A set KRn\mathcal{K} \subseteq \mathbb{R}^n is a cone if xK    αxK\mathbf{x} \in \mathcal{K} \implies \alpha \mathbf{x} \in \mathcal{K} for all α0\alpha \geq 0.

A convex cone is a set that is both convex and a cone: for any x,yK\mathbf{x}, \mathbf{y} \in \mathcal{K} and α,β0\alpha, \beta \geq 0,

αx+βyK.\alpha \mathbf{x} + \beta \mathbf{y} \in \mathcal{K}.

The positive semidefinite cone S+n={XSn:X0}\mathbb{S}^n_+ = \{\mathbf{X} \in \mathbb{S}^n : \mathbf{X} \succeq 0\} is a fundamental convex cone in optimization.

The PSD cone S+n\mathbb{S}^n_+ is self-dual: its dual cone is itself. This property underlies the elegance of SDP duality.

Theorem: Intersection of Convex Sets Is Convex

If {Ci}iI\{\mathcal{C}_i\}_{i \in I} is any (possibly infinite) collection of convex sets, then iICi\bigcap_{i \in I} \mathcal{C}_i is convex.

Each set independently "passes" the line-segment test. The intersection inherits this property because a line segment in the intersection lies in every Ci\mathcal{C}_i.

Definition:

Polyhedron

A polyhedron is the intersection of finitely many halfspaces and hyperplanes:

P={x:Axb,  Cx=d}\mathcal{P} = \{\mathbf{x} : \mathbf{A}\mathbf{x} \preceq \mathbf{b},\; \mathbf{C}\mathbf{x} = \mathbf{d}\}

where \preceq denotes componentwise inequality. A bounded polyhedron is called a polytope.

Every feasible region of a linear program is a polyhedron. In wireless scheduling, the rate region of a broadcast channel is a polyhedron (or its convex hull).

Convex Set Visualization

Explore the intersection of halfplanes in R2\mathbb{R}^2 and verify that the resulting polyhedron is convex. Drag the halfplane parameters to reshape the feasible region.

Parameters
1
2
-1
1

Convex vs. Non-Convex Sets — The Line Segment Test

Visualise the defining property of convexity: for a convex set, the line segment between any two points stays inside the set. For a non-convex set, the segment can exit.
Left: an ellipse (convex) — the line segment stays inside. Right: an L-shaped region (non-convex) — the midpoint escapes.

Key Takeaway

A polyhedron {x:Axb}\{\mathbf{x} : \mathbf{A}\mathbf{x} \preceq \mathbf{b}\} is always convex because it is the intersection of halfspaces, each of which is convex. This is why linear and quadratic programs have well-structured feasible regions.

Definition:

Convex Function

A function f:RnRf : \mathbb{R}^n \to \mathbb{R} is convex if its domain dom(f)\text{dom}(f) is a convex set and for all x,ydom(f)\mathbf{x}, \mathbf{y} \in \text{dom}(f) and θ[0,1]\theta \in [0, 1],

f(θx+(1θ)y)θf(x)+(1θ)f(y).f(\theta \mathbf{x} + (1-\theta)\mathbf{y}) \leq \theta f(\mathbf{x}) + (1-\theta) f(\mathbf{y}).

The function is strictly convex if the inequality is strict whenever xy\mathbf{x} \neq \mathbf{y} and θ(0,1)\theta \in (0,1).

It is concave if f-f is convex.

Equivalently, ff is convex iff its epigraph epi(f)={(x,t):f(x)t}\text{epi}(f) = \{(\mathbf{x}, t) : f(\mathbf{x}) \leq t\} is a convex set. This is the "epigraph characterization."

Definition:

Epigraph

The epigraph of f:RnRf : \mathbb{R}^n \to \mathbb{R} is

epi(f)={(x,t)Rn+1:xdom(f),  f(x)t}.\text{epi}(f) = \{(\mathbf{x}, t) \in \mathbb{R}^{n+1} : \mathbf{x} \in \text{dom}(f),\; f(\mathbf{x}) \leq t\}.

ff is convex if and only if epi(f)\text{epi}(f) is a convex set. The epigraph is the "region above the graph" of ff.

Theorem: First-Order Condition for Convexity

Let f:RnRf : \mathbb{R}^n \to \mathbb{R} be differentiable. Then ff is convex if and only if dom(f)\text{dom}(f) is convex and

f(y)f(x)+f(x)T(yx)f(\mathbf{y}) \geq f(\mathbf{x}) + \nabla f(\mathbf{x})^T (\mathbf{y} - \mathbf{x})

for all x,ydom(f)\mathbf{x}, \mathbf{y} \in \text{dom}(f).

The first-order Taylor approximation (the tangent hyperplane) is a global under-estimator of a convex function. This is the key geometric property that makes gradient-based algorithms work: the gradient always points toward the minimizer.

Theorem: Second-Order Condition for Convexity

Let f:RnRf : \mathbb{R}^n \to \mathbb{R} be twice differentiable. Then ff is convex if and only if dom(f)\text{dom}(f) is convex and the Hessian is positive semidefinite everywhere:

2f(x)0xdom(f).\nabla^2 f(\mathbf{x}) \succeq 0 \quad \forall\, \mathbf{x} \in \text{dom}(f).

ff is strictly convex if 2f(x)0\nabla^2 f(\mathbf{x}) \succ 0 for all x\mathbf{x} (this is sufficient but not necessary for strict convexity).

The Hessian being PSD means the function curves upward in every direction — like a bowl, never a saddle.

Example: Verifying Convexity via the Hessian

Show that the following functions are convex:

  1. f(x)=xTAxf(\mathbf{x}) = \mathbf{x}^T \mathbf{A} \mathbf{x} where A0\mathbf{A} \succeq 0
  2. f(x)=eaxf(x) = e^{ax} for any aRa \in \mathbb{R}
  3. f(x)=log(1+eaTx+b)f(\mathbf{x}) = \log(1 + e^{\mathbf{a}^T \mathbf{x} + b}) (log-sum-exp building block)

Common Mistake: Maximising a Concave Function \neq Minimising a Convex One?

Mistake:

Students sometimes think that maximising a concave function is a fundamentally different problem from minimising a convex function.

Correction:

Maximising ff (concave) is identical to minimising f-f (convex). The distinction is purely notational. In wireless communications, capacity-maximisation problems (concave objective) are exactly as "easy" as their minimisation reformulations.

Theorem: Operations That Preserve Convexity

The following operations preserve convexity of functions:

  1. Non-negative weighted sum: If f1,,fkf_1, \ldots, f_k are convex and wi0w_i \geq 0, then iwifi\sum_i w_i f_i is convex.
  2. Pointwise supremum: If fαf_\alpha is convex for each αA\alpha \in \mathcal{A}, then g(x)=supαfα(x)g(\mathbf{x}) = \sup_\alpha f_\alpha(\mathbf{x}) is convex.
  3. Composition with affine map: If ff is convex, then g(x)=f(Ax+b)g(\mathbf{x}) = f(\mathbf{A}\mathbf{x} + \mathbf{b}) is convex.
  4. Partial minimisation: If f(x,y)f(\mathbf{x}, \mathbf{y}) is convex in (x,y)(\mathbf{x}, \mathbf{y}), then g(x)=infyf(x,y)g(\mathbf{x}) = \inf_{\mathbf{y}} f(\mathbf{x}, \mathbf{y}) is convex (provided g>g > -\infty).

Rule 2 is especially powerful: a maximum of convex functions is convex. For example, x=maxixi\|\mathbf{x}\|_\infty = \max_i |x_i| is convex as the pointwise max of the convex functions xi|x_i|.

Why This Matters: Convexity in Rate Regions

The capacity region of a multiple-access channel (MAC) is a convex polytope. The sum-rate boundary is a concave function of the individual rates. Understanding convexity lets us move freely between "maximise sum rate" and "find the Pareto-optimal rate tuple" — both are convex optimisation problems.

See full treatment in Turbo Codes

Historical Note: A Brief History of Convexity

1896–2004

The study of convex sets goes back to Hermann Minkowski (1896), who used convex bodies in his geometry of numbers. Werner Fenchel developed convex conjugates in the 1940s. The systematic treatment of convex optimisation was pioneered by Rockafellar's Convex Analysis (1970). The field was transformed by Boyd and Vandenberghe's 2004 textbook, which showed that many engineering problems — including wireless resource allocation — are secretly convex.

Quick Check

Which of the following sets is not convex?

{(x1,x2):x12+x221}\{(x_1, x_2) : x_1^2 + x_2^2 \leq 1\} (unit disk)

{(x1,x2):x12+x221}\{(x_1, x_2) : x_1^2 + x_2^2 \geq 1\} (exterior of unit disk)

{(x1,x2):x1+x21}\{(x_1, x_2) : |x_1| + |x_2| \leq 1\} (1\ell_1 ball)

{XSn:X0}\{\mathbf{X} \in \mathbb{S}^n : \mathbf{X} \succeq 0\} (PSD cone)

Quick Check

Which function is convex on R\mathbb{R}?

f(x)=x3f(x) = x^3

f(x)=logxf(x) = -\log x on x>0x > 0

f(x)=sinxf(x) = \sin x

f(x)=x2f(x) = -x^2

Convex Set

A set C\mathcal{C} where the line segment between any two points in C\mathcal{C} remains in C\mathcal{C}: θx+(1θ)yC\theta \mathbf{x} + (1-\theta)\mathbf{y} \in \mathcal{C} for θ[0,1]\theta \in [0,1].

Related: Convex Function, Convex Cone, Polyhedron

Convex Function

A function ff whose epigraph is a convex set, equivalently, f(θx+(1θ)y)θf(x)+(1θ)f(y)f(\theta \mathbf{x} + (1-\theta)\mathbf{y}) \leq \theta f(\mathbf{x}) + (1-\theta) f(\mathbf{y}) for θ[0,1]\theta \in [0,1].

Related: Convex Set, Epigraph, Hessian

Epigraph

The set of points lying on or above the graph of a function: epi(f)={(x,t):f(x)t}\text{epi}(f) = \{(\mathbf{x}, t) : f(\mathbf{x}) \leq t\}. ff is convex iff its epigraph is a convex set.

Related: Convex Function

Convex Cone

A set that is closed under non-negative linear combinations: αx+βyK\alpha \mathbf{x} + \beta \mathbf{y} \in \mathcal{K} for α,β0\alpha, \beta \geq 0. The PSD cone S+n\mathbb{S}^n_+ is the most important example in optimisation.

Related: Convex Set, Psd Cone