Lably
Skip to content

Convex function

Real function with secant line between points above the graph itself

  • 13 min read
  • 7 chapters

Related on Lably

Through Mathematics, Real-valued function and Graph of a function

A twice-differentiable function of a single variable is convex if and only if its second derivative is nonnegative on its entire domain. Well-known examples of convex functions of a single variable include a linear function f(x)=cx (where c is a real number), a quadratic function cx2 (c as a nonnegative real number) and an exponential function cex (c as a nonnegative real number).

Convex functions play an important role in many areas of mathematics. They are especially important in the study of optimization problems where they are distinguished by a number of convenient properties. For instance, a strictly convex function on an open set has no more than one minimum. Even in infinite-dimensional spaces, under suitable additional hypotheses, convex functions continue to satisfy such properties and as a result, they are the most well-understood functionals in the calculus of variations. In probability theory, a convex function applied to the expected value of a random variable is always bounded above by the expected value of the convex function of the random variable. This result, known as Jensen's inequality, can be used to deduce inequalities such as the arithmetic–geometric mean inequality and Hölder's inequality.

Definition

Let X be a convex subset of a real vector space and let f:X→R be a function.

Then f is called convex if and only if any of the following equivalent conditions hold:

  1. For all 0≤t≤1 and all x1,x2∈X: f(tx1+(1−t)x2)≤tf(x1)+(1−t)f(x2) The right hand side represents the straight line between (x1,f(x1)) and (x2,f(x2)) in the graph of f as a function of t; increasing t from 0 to 1 or decreasing t from 1 to 0 sweeps this line. Similarly, the argument of the function f in the left hand side represents the straight line between x1 and x2 in X or the x-axis of the graph of f. So, this condition requires that the straight line between any pair of points on the curve of f be above or just meeting the graph.
  2. For all 0<t<1 and all x1,x2∈X such that x1≠x2: f(tx1+(1−t)x2)≤tf(x1)+(1−t)f(x2) The difference of this second condition with respect to the first condition above is that this condition does not include the intersection points (for example, (x1,f(x1)) and (x2,f(x2))) between the straight line passing through a pair of points on the curve of f (the straight line is represented by the right hand side of this condition) and the curve of f; the first condition includes the intersection points as it becomes f(x1)≤f(x1) or f(x2)≤f(x2) at t=0 or 1, or x1=x2. In fact, the intersection points do not need to be considered in a condition of convex using f(tx1+(1−t)x2)≤tf(x1)+(1−t)f(x2) because f(x1)≤f(x1) and f(x2)≤f(x2) are always true (so not useful to be a part of a condition).

The second statement characterizing convex functions that are valued in the real line R is also the statement used to define convex functions that are valued in the extended real number line [−∞,∞]=R∪{±∞}, where such a function f is allowed to take ±∞ as a value. The first statement is not used because it permits t to take 0 or 1 as a value, in which case, if f(x1)=±∞ or f(x2)=±∞, respectively, then tf(x1)+(1−t)f(x2) would be undefined (because the multiplications 0⋅∞ and 0⋅(−∞) are undefined). The sum −∞+∞ is also undefined so a convex extended real-valued function is typically only allowed to take exactly one of −∞ and +∞ as a value.

The second statement can also be modified to get the definition of strict convexity, where the latter is obtained by replacing ≤ with the strict inequality <. Explicitly, the map f is called strictly convex if and only if for all real 0<t<1 and all x1,x2∈X such that x1≠x2: f(tx1+(1−t)x2)<tf(x1)+(1−t)f(x2)

A strictly convex function f is a function such that the straight line between any pair of points on the curve f is above the curve f except for the intersection points between the straight line and the curve. An example of a function which is convex but not strictly convex is f(x,y)=x2+y. This function is not strictly convex because any two points sharing an x coordinate will have a straight line between them, while any two points NOT sharing an x coordinate will have a greater value of the function than the points between them.

The function f is said to be concave (resp. strictly concave) if −f (f multiplied by −1) is convex (resp. strictly convex).

Sign in to keep reading

6 more chapters are free with a Lably account.

More in Topics in mathematics