If for a random variable $X$ we have that $$e^{\mathbb{E}[X]} = \mathbb{E}[{e^{X}}],$$

how can I show that $$X= c$$ almost surely, where $c$ is constant?

Proof: Suppose that $$ \exp\left(\int_X f(x)d\mu(x)\right) = \int_X e^{f(x)}d\mu(x). \qquad (1)$$ We want to show that if equality holds then $f$ is constant.

Let us denote $c=\int_X f(x) \,\mathrm{d}\mu(x)$. The above inequality can now be rewritten as $e^c = \int_X e^{f(x)} \,\mathrm{d}\mu(x)$.

Suppose that $f$ is not constant, i.e. $f(x)\ne c$ on a set of positive measure. Then both sets $A=\{x; f(x)>c\}$ and $B=\{x; f(x)<c\}$ must have positive measure. (Otherwise we would get a contradiction with the definition of $c$ as the mean value of $f$.)

For any $t\ne c$ we have $e^t>e^c+e^c(t-c)$, since the graph of $e^x$ lies above the tangent line at the point $c$. (The factor $e^c$ is the slope at the point $c$.) This means $$e^t-e^c>e^c(t-c).$$

Thus for any $x\in A\cup B$ we have strict inequality $e^{f(x)}-e^c>(f(x)-c)e^{c}$. For any $x$ we have $e^{f(x)}-e^c \ge (f(x)-c)e^c$. Integrating gives $$\int_X e^{f(x)} \,\mathrm{d}\mu(x) - e^c > e^c \left(\int_X f(x) \,\mathrm{d}\mu(x) -c \right) = 0,$$ contradicting the equality (1).

Am I getting it right?

  • $\begingroup$ Apply Jensen's Inequality (or the AM-GM inequality). $\endgroup$
    – whuber
    Commented Feb 4, 2021 at 18:20
  • $\begingroup$ $$ e^{\sup_{x} \Phi(x)} = \sup_{x} e^{\Phi(x)} $$ for every real-valued family $\{\Phi(x)\}_x$. This holds more generally for any increasing (and continuous) function $f\colon \mathbb{R}\to\mathbb{R}$: $$ f(\sup_{x} \Phi(x)) = \sup_{x} f(\Phi(x)) $$ $\endgroup$
    – user310375
    Commented Feb 4, 2021 at 18:30
  • $\begingroup$ @whuber I edited my answer $\endgroup$
    – user310375
    Commented Feb 4, 2021 at 18:40

1 Answer 1


Without invoking any special results, a direct demonstration might go like this.

Let (for notational convenience) $\mu=E[X],$ which I suppose is finite. The line with equation $e^\mu(x-\mu) + e^\mu$ is a support line for the graph of the exponential function: it is tangent to the graph at the point $(\mu, e^\mu)$ and otherwise lies strictly below the graph. Thus, for all $x,$

$$e^x \ge e^\mu(x-\mu) + e^\mu$$

with equality if and only if $x=\mu.$ Applying this to the random variable $X$ and taking expectations gives

$$E\left[e^X\right] \ge E\left[e^\mu(X-\mu)+e^\mu\right] = e^\mu E[X]+e^\mu(1-\mu)=e^\mu=e^{E[X]},$$

with equality if and only if $X$ is almost surely equal to $\mu,$ QED.

Post script

You posted essentially the same argument as an edit while I was posting this answer, so all I have contributed (apart from affirmation of your approach) is an indication of how statistical language (of expectations) might streamline the presentation.

  • $\begingroup$ thanks @whuber for the support and the confirmation $\endgroup$
    – user310375
    Commented Feb 4, 2021 at 18:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.