The study of convex functions - in particular, of their optimization (really *minimization*) is one of the most important fields of applied mathematics. Convexity seems to be one of those incredibly well-chosen hypotheses which is just specific enough to admit a wealth of theorems, just general enough to produce a nontrivial theory (and a large amount of important examples).

Convex optimization, possibly because it has an "analytical" rather than "algebraic" feel, has not been very thoroughly studied by applied category theorists. The one notable exception is , which studies the decomposition of optimization problems by categorical means. This paper takes a different approach, attempting to define a category with optimization problems as the objects, and to derive theorems about optimization by categorical means.

A *convex optimization problem in standard form* consists of

- A convex function
f_0: \mathbb {R} ^k \to \mathbb {R} - A list of convex functions
f_1, \dots f_n: \mathbb {R} ^k \to \mathbb {R} - A list of
*affine*functionsg_1, \dots g_m: \mathbb {R} ^k \to \mathbb {R}

Let *Lagrangian* of this problem is the function *nonnegative* reals.

Observe that

It is natural to ask about the existence of Nash equilibria in this game - observe that the existence of an equilibrium

The *dual problem* is the problem of *maximizing* the function

In the world of convex optimization, two problems whose constraints carve out the same subset of *equivalent*. But they can clearly not be regarded as *isomorphic*, because the choice of constraint functions makes an important difference to the theory of optimization (for example, it can lead to different dual problems). Here we take the viewpoint that the *Lagrangian* is really the fundamental object in convex optimization - by passing to a suitable category of Lagrangians, we can make the dual problem into an actual self-duality on this category.

The category of *convex spaces* is the category of algebras for the monad * \Delta-homomorphisms* or

So as not to multiply notation unnecessarily, we simply denote the category of convex spaces by

A function between vector spaces is called *affine* if it preserves those linear combinations

Let *convex function on X* is a function

A *concave function* is a function so that

The term "convex function" in this sense clashes with the usual practice of naming structure-preserving functions after the structure they preserve (since convex functions do not preserve the convex structure). Unfortunately this usage is far too established to alter. (Convex functions are called convex because they are exactly those functions where the area above their graph is a convex subset of

The inequality
*Jensen's inequality*.
Sometimes this name is used for a stronger version of this inequality,
like the claim that

There is an natural way to extend the convex structure of

This doesn't work for the extended real line

Hence we adopt the convention that a function

A function between vector spaces is affine if and only if it is a

It's clear that an affine function is a

Convex spaces admit both a Cartesian product (given by the product of the underlying sets equipped with pointwise operations) and a tensor product, which (co)represents "bihomomorphisms". This is analogous to the situation for vector spaces. Unlike vector spaces, however, since all constant maps are homomorphisms, the projections

Since we are generally dealing with convex or concave functions, which can't freely be extended to the tensor product, we will work with the Cartesian product in this paper. But it's very possible that most of our constructions would work also with the tensor product, and maybe there is some situation where the extra generality is necessary.

The free convex space on a finite set * n-simplex* and denoted

A *topological convex space* is a convex space

A *minmax problem* is a triple

- Pointwise
*convex*inX - for eachy , givenx_1,x_2 \in X, \theta \in [0,1] ,L( \theta x_1 + (1- \theta )x-2,y) \leq \theta L(x_1,y) + (1- \theta )L(x_2,y) - Pointwise
*concave*inY - for eachx , giveny_1,y_2 \in Y, \theta \in [0,1] ,L(x, \theta y_1 + (1- \theta )y_2) \geq \theta L(x,y_1) + (1- \theta )L(x,y_2)

A *morphism of minmax problems*

We will see that various constructions on this category, which are natural and well-behaved from the point of view of category theory, capture relevant constructions from the theory of convex optimization.

\mathsf { Minmax } is bifibred over\mathsf { Set } ^ \Delta \times \mathsf { Set } ^{ \Delta , \mathrm {op} } , and the Cartesian and coCartesian lifts capture the operations of minimizing over the primal variables or maximizing over the dual variables- The property of
*strong duality*amounts to the claim that a particular diagram has the local Beck-Chevalley property - Relatedly, the existence of a Nash equilibrium for the game corresponding to
L amounts to the existence of a certain morphism. The fact that this implies strong duality can be derived by purely categorical means.

Let

Observe that minmax problems affine in

On the other hand, if

However, if

Let *primal optimization problem* associated to *minimize* this function).

The dual optimization problem is the function

Let *dual* problem given by

If

We will often utilize this duality to abbreviate proofs, proving something, for example, for the forwards direction and arguing "by duality" that it holds for the backwards direction as well.

Let a morphism *forwards* if *backwards* if

Note that

We will say a morphism in

Let

Let

Since if

Applying convexity, we get

The forgetful functor

- A forwards morphism
( \phi ,1_A): (X,A,L) \to (Y,A,L') is Cartesian if and only ifL(x,a) = L'( \phi (x),a) for allx,a - A forwards morphism
( \phi ,1_A): (X,A,L) \to (Y,A,L') is coCartesian if and only ifL'(y,a) = \inf _{ \phi (x) = y} L(x,a) - A backwards morphism
(1_X, \phi ): (X,A,L) \to (X,B,L') is Cartesian if and only ifL(x,a) = \inf _{ \phi (b)=a} L'(x,b) - A backwards morphism
(1_X, \phi ): (X,A,L) \to (X,B,L') is coCartesian if and only ifL'(x,b) = L(x, \phi (b))

Note that it suffices to provide Cartesian and coCartesian lifts for backwards and forwards morphisms (), since such lifts compose. Hence it suffices to verify that the given descriptions are correct, since clearly they suffice to compute a (co)Cartesian lift over any such morphism.

Note also that, since the forgetful functor is faithful, to verify a morphism

Thus let

Now let

Let

Let

Now the case for backwards morphisms simply follows by duality.

What's "really" going on here is that *bi*fibration). But the theory of bifibrations is quite complicated in general, and we will not go into it here.

Note also that this functor is quite close to displaying *topological*. If we remove the restriction that minmax problems be convex/concave, we can construct the universal lifts required using a similar supremum formula. The problem is that the supremum of a general set of concave functions is not automatically concave (however, the supremum taken over a convex set, in a suitable sense, is).

Let

Let

The assignment

Similarly,

The assignment

The assignment

We will abuse notation and identify

Using these identifications, we have

Note that if

Note also that the reflexive subcategory *colocalization* with respect to the class of backwards morphisms).

There is a monoidal structure on minmax problems, given by

A state is a point

Note that

Thus a choice of *solution* of the minmax game. In other words,

(By duality, and since

The forgetful functor

In the case of a Cartesian base, a monoidal fibration (like the one we have here) is equivalent to a fibration with a monoidal structure on each fiber, compatible with the reindexing in a certain way. Our base is not Cartesian, but does seem to come from a monoidal structure on each fiber, given by addition of *coCartesian* lift of *monoidal two-sided fibrations*, but this notion does not appear to have been studied before.

The localization (resp. colocalization)

Let

The equations are clearly true by definition.
Note that the inequality is equivalent to the existence of a morphism

We have canonical morphisms

Since

Let *satisfies strong duality* if it is an isomorphism. (Note that this is really just an inequality of real numbers, which must be an equality).

Let

If a minmax problem is a zero-sum game, a point

Let

Consider an optimization problem in standard form:

- Minimize
f_0(x), x \in \mathbb {R} ^k - Subject to
f_1(x), \dots , f_n(x) \leq 0 - And
g_1(x), \dots , g_m(x) = 0 - With each
f_i convex and eachg_i affine

Note: This is usually stated for a function defined on an arbitrary convex subset of

(Proof adapted from Convex Optimization)

For simplicity, we will assume

Let

Let

First assume

If

Inserting

Let

This theorem can be derived from the Kakutani fixpoint theorem in a very similar way to the usual proof of Nash's theorem about general, non-zerosum games - although note that it is not a special case, since *affine* as it is for a game-theoretic game.

However, we will give a different proof, which uses the structure of

Let *solvable pair* if, for any continuous minmax problem

The pair

Let

Consider the set

Let

(B,A) is solvable.- For every
b \in B ,(E_b,A) is solvable, whereE_b \subseteq E is the fiber.

Recall that

Now we can factor this as follows:

Note that the right-hand square here has the Beck-Chevalley condition by assumption. So it suffices to show the left-hand square does. For a given

If

Let

If

It is interesting to note the use of compactness here. Recall that topological compactness is closely connected with the property, also called compactness, of

The idea of proceeding by induction on *affine* games, and hence their induction step is completely different (and they have no need for the complicated

We can use the minimax theorem to derive other statements of interest about convex optimization

Let

Consider the minmax problem

Since the closed unit ball is compact, by the minimax theorem there exists an equilibrium

By disjointness,

By the equilibrium property, we see that

Let

Let

- For each
i ,K_i,L_i are disjoint. - For each
i ,K_i \subseteq K_{i+1} - Each of the
K_i,L_i are compact and convex \cup _i K_i = X, \cup _i L_i = Y

Now for each

Let *convex conjugate*

The convex conjugate is also called the *Legendre transform* or the *Fenchel-Legendre transform*. It is intimately related to convex duality. We will prove the following fundamental property of the convex conjugate using the categorical language of minmax problems, and along the way we will see the role that convex duality plays. Note that our invocation of the term "strong duality" here is somewhat more complicated than strictly necessary - normally one would merely invoke the separating hyperplane theorem directly.

Let

Then

Note that the two uses of the asterisk in this equation conflict.
We have both the reversed optimization problem

Given a minmax problem

Then the Legendre transform

Let

Observe that

Clearly *all*

Recall that the minmax problem

Clearly, for our

Given a commutative square:

Let

Recall that

Now observe that, restricted to the subcategory

Since

(Note that this inequality actually holds even if

Observe that, using the natural identification

Our claim now is that we may exchange these extremizers by strong duality. This amounts to the claim that the local Beck-Chevalley property holds for this square at

But by , strong duality holds in every square of the form

Let

For this composition to be associative relies on a strong duality property. We probably shouldn't want to treat this as well-defined unless it holds.

Note that by the convex duality stuff, the minmax problem

This may fit together into a double category type structure for minmax problems (maybe restricted to linear maps between the spaces).

Since the category of minmax problems is very similar to a Chu construction, we might hope that we could define a similar star-autonomous structure on minmax problems. Unfortunately, this does not work. We do have the duality, Dual minmax problem, but it doesn't extend to a star-autonomous structure.

Morally speaking, the tensor product of

The category of minmax problems has products, given by

Here

By duality (with

If

A function between vector spaces is affine if and only if it is a

It's clear that an affine function is a

Let