How statement and proof provenance work
The first chip identifies the source of the statement or construction; the second identifies the source of its local proof or verification.
- Literature-sourced: the exact statement appears in a cited source; only wording and notation differ.
- AI-adapted: a semantically identical restatement of literature-sourced material, modulo indexing, notation, and boundary cases adopted by the library.
- AI-generated: a genuinely novel statement formulated by AI, with no source for the claim itself.
These labels describe origin, not correctness: citations and verification chips remain separate evidence.
Convex and Semicontinuous Functions on R^n: Examples and Counterexamples
1 · Prerequisites
- Binary Operations, Monoids, Groups and Subgroups
- Compactness
- Compactness in Metric Spaces
- Completeness, Completion, and Uniform Continuity
- Construction of the Natural Numbers
- Construction of the Real Numbers via Cauchy Sequences
- Construction of the Real Numbers via Dedekind Cuts
- Continuity, IVT, EVT, and Uniform Continuity
- Convex and Semicontinuous Functions on Rⁿ
- Convexity
- Countability and Uncountability
- Darboux, L'Hôpital, and Taylor's Theorem
- Filters and Ultrafilters
- Finite Counting, Factorials and Binomial Coefficients
- Foundations of the Real Numbers for Analysis
- Limits of Real Functions
- limsup, liminf, and Subsequential Limits
- Linear Independence, Bases and Dimension
- Linear Transformations, Rank-Nullity and Quotient Spaces
- Metric Spaces
- Mixed Partials, Taylor Formulae, and Extrema
- Monotone Functions, Discontinuities, and Continuity Sets
- Monotone Sequences, Bolzano-Weierstrass, and Cauchy Completeness
- Order, Zorn's Lemma, and the Axiom of Choice
- Properties of the Integral and the Working FTC
- Relations, Functions, and Quotients
- Rings, Subrings, Integral Domains and Fields
- Rⁿ as a Normed Space; Vector-Valued Functions
- Roots, Rational Powers, and Classical Inequalities
- Sequences and Limits
- Subspaces, Products, and Quotients
- Suprema and Infima
- The Derivative and the Mean Value Theorems
- The Riemann Integral in Rᵐ and Jordan Content
- The Riemann Integral: Definition and Integrability
- The Topology of Euclidean Space
- The Total Derivative in ℝᵐ → ℝⁿ
- The ZFC Axioms and the Basic Set Constructions
- Topological Spaces and Continuity
- Topology of ℝ
- Vector Spaces, Linear Subspaces, Span and Direct Sums
2 · Summary
3 · Logical flowchart
4 · Definitions, theorems and proofs
None yet.
5 · Examples, counterexamples and false statements
The Euclidean norm and its square are convex, with a ball of subgradients at zero for the norm
Example
Let . The Euclidean norm is convex and its subdifferential at zero is the closed unit ball. The squared norm is strictly convex and satisfies
Facts & Assumptions
Given: The Euclidean norm The -norms for rational , and , convexity Convex and strictly convex functions on Euclidean convex sets, and uniqueness of the subgradient of a differentiable convex function The subdifferential of a differentiable convex function is its gradient singleton.
The Euclidean norm is a norm on and therefore satisfies the triangle inequality and homogeneity (Cauchy-Schwarz with its equality case, the triangle inequality for , the parallelogram law and polarisation).
A function on an open convex set is convex if and only if its Hessian is positive semidefinite everywhere (A function is convex exactly when its Hessian is positive semidefinite).
A function on an open convex set whose Hessian is positive definite everywhere is strictly convex (An everywhere-positive-definite Hessian implies strict convexity).
The Euclidean inner product satisfies (Cauchy-Schwarz with its equality case, the triangle inequality for , the parallelogram law and polarisation).
The derivative of is for every integer (For a natural the function is differentiable everywhere with derivative ; for it is the constant , with derivative ; for a natural the function is differentiable at every with derivative ; consequently every polynomial function is differentiable at every real, with the derivative computed term by term).
Sums and scalar multiples of differentiable real functions are differentiable with the expected derivatives (Sums, scalar multiples, products and quotients: , , , and when ).
Sums and scalar multiples of totally differentiable Euclidean maps are totally differentiable with the expected derivatives (Sums and scalar multiples of totally differentiable maps are totally differentiable with the expected derivatives).
Verification
Homogeneity and the triangle inequality in [L1] give so the norm is convex.
If , [L4] gives , so is a subgradient of the norm at zero. Conversely, a subgradient satisfies for all ; taking gives , hence .
Since , coordinatewise differentiation with [L5]–[L7] gives gradient and constant Hessian , so is and its Hessian is positive definite. Thus [L2] gives convexity, [L3] gives strict convexity, and differentiable subgradient uniqueness gives .
A finite maximum of affine functions and its active subgradients
Example
Let , let , and let . Define by
and let be the active index set. Then is convex and
For the two-dimensional function , the subdifferential at zero is .
Facts & Assumptions
Given: The affine family above, subgradients as in Subgradients and the subdifferential of a convex function, and finite convex combinations as in Finite Jensen inequality for convex functions on .
The pointwise maximum of a nonempty finite family of convex functions on a common convex domain is convex (Nonnegative combinations, affine precomposition, and finite pointwise maxima preserve convexity).
A point outside a nonempty closed convex set is strictly separated from it (A point outside a nonempty closed convex set is strictly separated from it).
For positive Euclidean dimension, a subset is compact if and only if it is closed and bounded (Heine-Borel in : with the Euclidean metric a subset of is compact if and only if it is closed and bounded, and the proof by bisection uses no choice principle; the same holds on the real line).
The continuous image of a compact subset is compact (The image of a compact metric space under a continuous map is compact, and so is the image of any compact subset).
A compact subset of a metric space is closed and bounded (A compact subset of a metric space is closed and bounded).
Verification
Each affine constituent is convex, so [L1] makes their nonempty finite maximum convex.
If , then . Nonnegative weighted sums of these inequalities show that every convex combination of active slopes is a subgradient.
The active-weight simplex is closed and bounded, hence compact by [L3]; its affine image is compact by [L4] and closed by [L5]. If a subgradient lay outside this active convex hull, [L2] would give a direction with strictly larger than every active . Finiteness lets one choose small enough that inactive affine pieces remain below the active maximum at . Then the subgradient inequality would require an increment at least , while the actual increment is , a contradiction. The displayed four-piece formula follows from its four active slopes at zero.
A convex function on that is discontinuous at the boundary
Statement refuted
Every convex real-valued function on a convex subset of Euclidean space is continuous on its whole domain.
The counterexample below establishes: The function is convex on but is not continuous at .
Facts & Assumptions
Given: Define by and for .
The function is convex when for all and (Convex and strictly convex functions on Euclidean convex sets).
Every convex function on an open convex set is continuous on that set (A convex function on an open convex set is continuous).
Counterexample
A convex combination of two domain points equals zero only when every endpoint having positive weight is zero. In that case [F1] is an equality. Otherwise the left side is zero and the right side is nonnegative, so [F1] again holds.
For every positive , , whereas , so the right-hand limit at zero is not the function value. The function is convex on but is not continuous at . This does not contradict [L1], because the domain is not open at zero.
has empty subdifferential on the unit-sphere boundary
Statement refuted
Every convex real-valued function on a closed convex domain has a subgradient at every domain point.
Facts & Assumptions
Given: Let for (The -norms for rational , and ) and define on , with convexity as in Convex and strictly convex functions on Euclidean convex sets. For the comparison with the interior-point theorem, assume the Axiom of Choice and the Axiom of Countable Choice (The Axiom of Choice, The Axiom of Countable Choice ()).
A vector is a subgradient of at when for every in the domain (Subgradients and the subdifferential of a convex function).
Assuming the Axiom of Choice and the Axiom of Countable Choice, a convex function has nonempty subdifferential at every interior point of its domain (A convex function has a subgradient at every interior point of its domain).
The Euclidean norm is a norm on and satisfies the triangle inequality (Cauchy-Schwarz with its equality case, the triangle inequality for , the parallelogram law and polarisation).
Counterexample
Put . The lifted vectors have norm one in . By the triangle inequality in [L2], the convex combination has norm at most one, so its nonnegative last coordinate is at most . Negating gives the convexity inequality for on the whole closed ball.
Fix a unit vector and suppose satisfied [F1] at . Testing for gives The right side is unbounded as approaches , impossible for the fixed vector . Hence .
Step 2.1 applies to every sphere point, while [L1] gives nonempty subdifferentials at every interior point. Thus the interior hypothesis in the existence theorem is sharp.
A lower semicontinuous function on with no maximum
Statement refuted
Every lower semicontinuous real-valued function on a nonempty compact set attains both a minimum and a maximum.
Facts & Assumptions
Given: Define by and for , with the one-dimensional convention identified by Upper and lower semicontinuity on subsets of , Euclidean semicontinuity agrees with the published real-line definition.
Lower semicontinuity is equivalent to relative openness of every strict superlevel set and to relative closedness of every weak sublevel set (Semicontinuity on is characterized by strict open level sets and weak closed level sets).
Every lower semicontinuous real-valued function on a nonempty compact Euclidean set is bounded below and attains a minimum (Semicontinuous extreme value theorem on compact Euclidean sets).
Counterexample
The weak sublevel is empty for , equals at , equals for , and is all of for . Each is relatively closed, so [L1] makes lower semicontinuous.
Every value of is negative, but approaches zero through positive natural . Hence and the supremum is not attained, so has no maximum.
The function does attain its minimum at zero, as [L2] requires. It is only the unsupported opposite extremum that fails.
Characteristic functions of open and closed sets are one-sided semicontinuous
Example
Let , let , and let . The characteristic function is lower semicontinuous when is relatively open, and upper semicontinuous when is relatively closed. On , the characteristic function of is upper semicontinuous but discontinuous at zero, and its negative is lower semicontinuous but discontinuous there.
Facts & Assumptions
Given: The relative Euclidean topology and the semicontinuity convention Upper and lower semicontinuity on subsets of .
Upper semicontinuity is equivalent to relative openness of every strict sublevel set, and lower semicontinuity is equivalent to relative openness of every strict superlevel set (Semicontinuity on is characterized by strict open level sets and weak closed level sets).
A set is closed exactly when its complement is open (The metric topology: a set is open when every one of its points has a ball around it inside the set; closed means open complement).
Verification
Strict superlevels of are empty, , or all of , while strict sublevels are empty, , or all of . By [L1] and [L2], is lower semicontinuous when is open and upper semicontinuous when is closed.
For in , step 1.1 gives upper semicontinuity, but values at positive points tend to zero rather than the value one at zero. Negation exchanges upper and lower semicontinuity, so supplies the lower-semicontinuous discontinuous example.
A positive-semidefinite Hessian need not give strict convexity
Statement refuted
If a function on an open convex set has a positive-semidefinite Hessian everywhere, then it is strictly convex.
The counterexample below establishes: The Hessian of is positive semidefinite everywhere, but is not strictly convex.
Facts & Assumptions
Given: The positive-semidefinite quadratic-form convention Positive definite, negative definite, semidefinite, and indefinite quadratic forms and strict convexity Convex and strictly convex functions on Euclidean convex sets.
A function on an open convex set is convex if and only if its Hessian is positive semidefinite everywhere (A function is convex exactly when its Hessian is positive semidefinite).
The derivative of is for every integer (For a natural the function is differentiable everywhere with derivative ; for it is the constant , with derivative ; for a natural the function is differentiable at every with derivative ; consequently every polynomial function is differentiable at every real, with the derivative computed term by term).
Scalar multiples of differentiable real functions are differentiable with the expected derivatives (Sums, scalar multiples, products and quotients: , , , and when ).
Counterexample
By [L2] and [L3], the Hessian of is , which is positive semidefinite. By [L1], is convex.
The distinct points and , and every point of the segment joining them, all have value zero. Thus the strict convexity inequality is an equality on that segment. The Hessian of is positive semidefinite everywhere, but is not strictly convex.
A strictly convex function can have a singular Hessian
Statement refuted
Every twice differentiable strictly convex function has a positive-definite Hessian at every point.
The counterexample below establishes: For every , the function given by is strictly convex, but its Hessian at the origin is the zero matrix.
Facts & Assumptions
Given: Fix . Strict convexity is as in Convex and strictly convex functions on Euclidean convex sets, and the Hessian convention is The Hessian matrix and critical points of a scalar field.
For every integer , the function is differentiable everywhere and satisfies (For a natural the function is differentiable everywhere with derivative ; for it is the constant , with derivative ; for a natural the function is differentiable at every with derivative ; consequently every polynomial function is differentiable at every real, with the derivative computed term by term).
For a continuous real function on a closed interval that is differentiable in its interior, one secant slope equals an interior derivative (The mean value theorem, as the case of Cauchy's: for continuous on with and differentiable on there is with ).
Scalar multiples of differentiable real functions are differentiable with the expected derivatives (Sums, scalar multiples, products and quotients: , , , and when ).
Counterexample
Let and , and put . Apply [L2] on and . The two secant slopes equal and for some by [L1], so the first is strictly smaller; rearranging gives . Thus is strictly convex. For distinct vectors, at least one coordinate gives this strict inequality and every other coordinate gives the corresponding weak one; adding shows that is strictly convex for .
Differentiating again with [L1] and [L3], the Hessian is diagonal with entries and zero off-diagonal entries. At the origin it is the zero matrix, hence singular and not positive definite because . Thus is strictly convex, but its Hessian at the origin is the zero matrix.
FALSE: a convex function on a convex set is continuous
Statement
False claim: every convex real-valued function on a convex Euclidean domain is continuous at every domain point.
Facts & Assumptions
Given: No openness assumption is imposed.
There is a function on that is convex on but is not continuous at (A convex function on that is discontinuous at the boundary).
Refutation
The interval in [L1] is convex and the displayed function is convex on it.
The same function fails continuity at the boundary point zero by [L1], so it refutes the claim. Openness of the domain, or restriction to its interior, is essential.
FALSE: every convex function is differentiable
Statement
False claim: every convex real-valued function on an open Euclidean convex set is differentiable everywhere.
Facts & Assumptions
Given: Positive Euclidean dimension.
The Euclidean norm is convex and its subdifferential at zero is the closed unit ball (The Euclidean norm and its square are convex, with a ball of subgradients at zero for the norm).
If a convex function is differentiable at , then (The subdifferential of a differentiable convex function is its gradient singleton).
Refutation
In positive dimension, the closed unit ball in [L1] contains more than one vector, so the norm has a nonsingleton subdifferential at zero.
By [L2], differentiability there would force the subdifferential to be a singleton. Hence the convex Euclidean norm is not differentiable at zero, and the claim is false.
FALSE: semicontinuity implies continuity on a compact set
Statement
False claim: an upper or lower semicontinuous real-valued function on a compact Euclidean set must be continuous.
Facts & Assumptions
Given: The compact interval .
On , the characteristic function of is upper semicontinuous but discontinuous at zero, and its negative is lower semicontinuous but discontinuous there (Characteristic functions of open and closed sets are one-sided semicontinuous).
Refutation
The first function in [L1] satisfies upper semicontinuity on a compact domain and fails continuity.
Its negative in [L1] separately satisfies lower semicontinuity and fails continuity on the same compact domain. Thus neither one-sided notion implies continuity.
FALSE: a positive-semidefinite Hessian gives strict convexity
Statement
False claim: an everywhere-positive-semidefinite Hessian forces a function on an open convex set to be strictly convex.
Facts & Assumptions
Given: No assumptions beyond the false claim.
The Hessian of is positive semidefinite everywhere, but is not strictly convex (A positive-semidefinite Hessian need not give strict convexity).
Refutation
The function in [L1] satisfies the Hessian hypothesis of the false claim.
It is constant along every vertical line and therefore violates strict convexity by [L1]. Hence the claim is false.
FALSE: strict convexity gives a positive-definite Hessian
Statement
False claim: every twice differentiable strictly convex function has a positive-definite Hessian at every point.
Facts & Assumptions
Given: No assumptions beyond the false claim.
For every , the function given by is strictly convex, but its Hessian at the origin is the zero matrix (A strictly convex function can have a singular Hessian).
Refutation
The function in [L1] satisfies strict convexity globally.
Its Hessian at the origin is zero and hence not positive definite by [L1], directly refuting the claim.
Sources
- S. Boyd and L. Vandenberghe, Convex Optimization, §§3.1–3.2
- D. Bertsekas, MIT 6.253 Convex Analysis and Optimization, Lecture 12
- S. Boyd and L. Vandenberghe, Convex Optimization, §3.2.3
- S. Boyd and L. Vandenberghe, Convex Optimization, §3.1
- CUHK ENGG 5501 Convex Analysis notes
- D. Bertsekas, MIT 6.253 Convex Analysis and Optimization, Lectures 2 and 5
- D. Bertsekas, MIT 6.253 Convex Analysis and Optimization, Lectures 2 and 4
- S. Boyd and L. Vandenberghe, Convex Optimization, §3.1.4