Solution (source code)

= Solution

Use the maximizing-dual convention. For the <perturbation function> $f(x,u)$, define
$$
\boxed{\varphi(x)=f(x,0),\qquad
\psi(y)=-f^*(0,y),\qquad
p(u)=\inf_x f(x,u),\qquad
q(v)=\sup_y[-f^*(v,y)].}
$$
The <primal problem> is $\inf_x\varphi(x)=p(0)$; the <Lagrangian dual problem> is $\sup_y\psi(y)=q(0)$. The sign convention makes the dual marginal $q$ concave for jointly convex data; some formulations negate $q$ to express a minimization problem.

The central <convex perturbation duality> calculation is
$$
p^*(y)=\sup_{u,x}\{\langle y,u\rangle-f(x,u)\}=f^*(0,y),
\qquad
q(0)=p^{**}(0)\leq p(0).
$$
The last inequality is <weak duality>. A sufficient finite-dimensional condition for <strong duality> with dual attainment is: $f$ is jointly proper and convex, $p$ is proper with $p(0)$ finite, and $p$ is finite on a neighborhood of zero. More generally $0\in\operatorname{ri}(\operatorname{dom}p)$ suffices.

Indeed <continuity of a convex function> on the interior of its domain gives a supporting <subgradient> $y_*\in\partial p(0)$, so
$$
p(u)\geq p(0)+\langle y_*,u\rangle
\quad\Longrightarrow\quad
p^*(y_*)=-p(0).
$$
Therefore $\psi(y_*)=p(0)$ and the dual maximum is attained. \b[This qualification establishes equality and dual attainment; it does not by itself establish a primal minimizer.]