$\DeclareMathOperator\Ent{Ent}\newcommand{\prior}{\mathrm{prior}}\newcommand\Data{\mathrm{Data}}$I came across this paper on the optimality of Bayes' theorem
<https://sinews.siam.org/Portals/Sinews2/Issue%20Pdfs/sn_July-August2021.pdf>
and could not figure out where one inequality comes from.


Denote by $m$ the parameter to estimate and by $D\_{KL}$ the KL distance.


One statement at the end is that from "a duality formulation of variational inference" in a given reference, the following inequality holds
$$
- \log E\_{\pi\_{\prior}}[e^{f(m)}] \leq E\_\rho[f(m)] + D\_{KL}(\rho | \pi\_{\prior}) \;.
$$
with mild conditions on $\pi\_{\prior}(m)$ and $\rho(m)$ and a large class of $f(m)$.
(When $f(m) = \log\_{\pi\_{like}}(\Data|m)$, the equality holds only when $\rho=$ Bayes posterior distribution.)


Q: Where does the inequality comes from? In the reference [http://www.cmap.polytechnique.fr/~merlet/articles/probas\_massart\_stf03.pdf](http://www.cmap.polytechnique.fr/%7Emerlet/articles/probas_massart_stf03.pdf) ,
Section 2.3.1 Duality and variational formulas gives
$$
\Ent\_P[Y] = \sup \{ E\_P[UY] , \, U:\Omega\rightarrow \bar{R},\, E[e^U] = 1 \} \;.
$$


I still don't see how this helps with deriving the inequality.



An inequality in the optimality of Bayes' theorem
First, let us do some cleaning here.


1. Let $\pi:=\pi\_{\mathrm{prior}}$, $Y:=\rho/\pi$, and $F:=f(m)$.
2. You copied the inequality in question incorrectly. In your first-linked paper, the inequality is
$-\ln E\_\pi e^F\le E\_\rho(-F) + D\_{KL}(\rho|\pi)$, that is,
$$E\_\rho F-\ln E\_\pi e^F\le D\_{KL}(\rho|\pi). \tag{0}$$
3. Your first-linked paper uses some facts from your second-linked book. However, the definition of "the Kullback-Leibler information" in that book is non-standard: it is
$$K(\rho,\pi):=E\_\pi Y\ln Y-E\_\pi Y\,E\_\pi\ln Y=E\_\pi(Y\ln Y-\ln Y)
=E\_\rho\ln\frac\rho\pi+E\_\pi\ln\frac\pi\rho,$$
which is the symmetrized version of the standard Kullback--Leibler (KL) information $D\_{KL}(\rho||\pi)=E\_\rho\ln\frac\rho\pi=E\_\pi Y\ln Y$ (your first-linked paper uses the standard definition of the KL information). To avoid further confusion, we are not going to use the book in the rest of this answer.


Thus, the corrected version of your inequality in question is this:
$$E\_\rho F-\ln E\_\pi e^F\le E\_\pi Y\ln Y$$
or, equivalently,
$$E\_\pi YF-\ln E\_\pi e^F\le E\_\pi Y\ln Y. \tag{1}$$


Since $E\_\pi Y=1$, the left-hand side of (1) will not change if $F$ is replaced by $F-c$, for any real constant $c$. So, without loss of generality $E\_\pi e^F=1$, and then (1) becomes
$$E\_\pi YF\le E\_\pi Y\ln Y. \tag{2}$$
By convexity,  

$$e^F\ge e^u+(F-u)e^u$$
for all real $u$. Substituting here $u=\ln Y$ and taking the expectations, we get
$$E\_\pi Y=1=E\_\pi e^F\ge E\_\pi Y+E\_\pi (F-\ln Y)Y,$$
so that (2) follows.


So, (0) holds, as desired.


Of course, (0) will continue to hold with $K(\rho,\pi)$ in place of $D\_{KL}(\rho|\pi)$, because the symmetrized KL information $K(\rho,\pi)$ is no less than the standard KL information $D\_{KL}(\rho|\pi)$.


