Lambdia

The Average of e to the X Is Never One

Moving the average inside the exponential returns 1, and 1 happens to be the exact median and the exact geometric mean of e^X, which is why the mistake survives every re-check of the arithmetic. Completing the square in the exponent gives the true value e^(sigma squared over two), or 1.6487 at unit spread, because multiplying a Gaussian density by e^x slides its centre and scales its mass. Convexity settles the direction before any integral is set up, and on a heavy-tailed variable the quantity stops being finite at all.

Let XX be normal with mean zero and variance σ2\sigma^2. What is the average of eXe^{X}?

The answer is eσ2/2e^{\sigma^2/2}, which at σ=1\sigma = 1 comes to 1.64871.6487. The answer almost everybody gives first is 11, arrived at by moving the average inside the exponential: the average of XX is zero, and e0=1e^{0} = 1. That is a sixty-five per cent error, and the interesting part is that 11 is the exact answer to a closely related question, which is why the mistake is so durable.

What moving the average inside actually assumes

Written out, the reflex is a chain of two equalities: E[eX]=eE[X]=e0=1\mathbb{E}[e^{X}] = e^{\mathbb{E}[X]} = e^{0} = 1. The second is arithmetic. The first is the whole problem. Expectation commutes with a function gg for every non-degenerate XX precisely when gg is affine, because expectation is a linear operator and nothing more. The exponential is strictly convex, so the identity fails, and convexity even tells you the direction of the failure before a single integral is set up.

The integral, in full

Take σ=1\sigma = 1 first, where the algebra is cleanest. By definition,

E ⁣[eX]  =  exex2/22πdx  =  12πexx2/2dx.\mathbb{E}\!\left[e^{X}\right] \;=\; \int_{-\infty}^{\infty} e^{x} \, \frac{e^{-x^{2}/2}}{\sqrt{2\pi}} \, \mathrm{d}x \;=\; \frac{1}{\sqrt{2\pi}} \int_{-\infty}^{\infty} e^{\,x - x^{2}/2} \, \mathrm{d}x.
(1)

Everything now hangs on the exponent. Complete the square in it:

xx22  =  12(x1)22.x - \frac{x^{2}}{2} \;=\; \frac{1}{2} - \frac{(x-1)^{2}}{2}.
(2)

Expand the right-hand side if you want to check it, and note that the identity holds for every real xx rather than approximately near the origin. Substituting it back pulls the constant out of the integral and leaves a Gaussian density with its centre moved from 00 to 11 and its width untouched. A density integrates to one, so the remaining integral needs no work at all:

E ⁣[eX]  =  e1/2e(x1)2/22πdx=1  =  e1/2  =  1.6487\mathbb{E}\!\left[e^{X}\right] \;=\; e^{1/2} \underbrace{\int_{-\infty}^{\infty} \frac{e^{-(x-1)^{2}/2}}{\sqrt{2\pi}} \, \mathrm{d}x}_{=\,1} \;=\; e^{1/2} \;=\; 1.6487\ldots
(3)

The content of the calculation is a single geometric fact. Multiplying a Gaussian density by exe^{x} does not change its shape. It slides the centre to the right by one unit and multiplies the total mass by e1/2e^{1/2}. That surplus mass is the answer.

Any spread, and the function that carries all of them

The same completion works at general σ\sigma, with the shift and the constant both scaling:

xx22σ2  =  σ22(xσ2)22σ2E ⁣[eX]=eσ2/2.x - \frac{x^{2}}{2\sigma^{2}} \;=\; \frac{\sigma^{2}}{2} - \frac{(x - \sigma^{2})^{2}}{2\sigma^{2}} \qquad \Longrightarrow \qquad \mathbb{E}\!\left[e^{X}\right] = e^{\sigma^{2}/2}.
(4)

The centre now moves to σ2\sigma^2 instead of one, and the mass multiplier is eσ2/2e^{\sigma^2/2}. Replacing xx by txtx throughout gives the moment generating function of a centred Gaussian, which is the whole family of these calculations in a single expression:

MX(t)  =  E ⁣[etX]  =  eσ2t2/2.M_X(t) \;=\; \mathbb{E}\!\left[e^{tX}\right] \;=\; e^{\sigma^{2} t^{2}/2}.
(5)

Setting t=1t = 1 recovers the result. Setting t=2t = 2 at σ=1\sigma = 1 gives e2e^{2}, which is also the average of eYe^{Y} for YY of spread two, so the two dials are interchangeable in the way the formula suggests. For a normal variable with a non-zero mean the statement becomes E[eX]=eμ+σ2/2\mathbb{E}[e^{X}] = e^{\mu + \sigma^{2}/2}, and the ratio between two spreads is e(b2a2)/2e^{(b^{2}-a^{2})/2}, which is a sharper thing to verify numerically than any single value.

The direction was settled before the integral

Jensen's inequality — strict form

If gg is strictly convex and XX is not almost surely constant, then E[g(X)]>g(E[X])\mathbb{E}[g(X)] > g(\mathbb{E}[X]) whenever both sides are finite. With g=expg = \exp this says the average of eXe^{X} strictly exceeds eE[X]e^{\mathbb{E}[X]}, so the correction to the reflex answer is always an addition and can never be a subtraction.

You can see the mechanism without the Gaussian. Replace XX by a coin flip that pays +1+1 or 1-1. Its average is still zero, and the average of eXe^{X} is (e+e1)/2=1.5431(e + e^{-1})/2 = 1.5431, already above one. Stepping up multiplies by 2.71832.7183; stepping down multiplies by 0.36790.3679. Those two moves do not cancel, and there is a one-line reason why: the arithmetic mean of a positive number and its reciprocal is at least their geometric mean, which is exactly 11, with equality only at t=1t = 1.

Fig. 1 — Convexity in one picture. The chord through the two ends sits above the curve, so the average of the endpoints exceeds the value at the average.

Why one is such a durable wrong answer

The reflex answer is not noise. It is the exact median of eXe^{X}, and also its exact geometric mean. Half the mass of a centred normal sits below zero, and the exponential is increasing, so half the mass of eXe^{X} sits below e0=1e^{0} = 1 for every value of σ\sigma whatsoever. The geometric mean is exp(E[logeX])=exp(E[X])=1\exp(\mathbb{E}[\log e^{X}]) = \exp(\mathbb{E}[X]) = 1 by the same triviality. So the candidate who answers 11 has computed a real summary of the right distribution and reported it under the wrong name, which is why re-checking the arithmetic never rescues them.

Stated properly, eXe^{X} is log-normal with parameters (0,σ2)(0, \sigma^2). Its mean is eσ2/2e^{\sigma^2/2}, its median is 11, and its mode is eσ2e^{-\sigma^2}, which at σ=1\sigma = 1 is 0.36790.3679. Three separated summaries in that order are the signature of a right-skewed law: the long upper tail drags the mean away while leaving the median where it was.

Fig. 2 — The median never moves; the mean leaves it behind as soon as σ is positive. At σ = 1 the gap is 65 per cent of the median.

This has a consequence anyone modelling prices runs into. If the log-return over some period is normal with mean zero and spread σ\sigma, the simple return has average eσ2/21>0e^{\sigma^2/2} - 1 > 0, which at σ=0.2\sigma = 0.2 is 2.022.02 per cent. A strategy whose log return averages nothing still averages a gain. Turn that around and you get the reason the term σ2/2-\sigma^2/2 appears in the solution of geometric Brownian motion: it is exactly the drift you must subtract from the log to leave the level with no average growth.

Where the average stops existing

Every step above used one property of the normal law that is easy to take for granted. Its density decays like ex2/2σ2e^{-x^{2}/2\sigma^{2}}, which beats exe^{x} at every scale, so the integral converges however large σ\sigma gets. Remove the Gaussian tail and the answer can stop existing altogether.

Let XX follow a Student tt law with any number of degrees of freedom. Its density decays polynomially, exe^{x} grows faster than any polynomial decays, and E[eX]\mathbb{E}[e^{X}] is infinite. The same thing happens for a positive XX that is itself log-normal, which is the standard cautionary example: a log-normal variable has finite moments of every order, and yet its moment generating function fails to exist for any positive tt. Having all moments finite is weaker than having a moment generating function, and the log-normal is the example that separates the two.

At the other extreme the reflex answer becomes correct. Setting σ=0\sigma = 0 makes XXthe constant zero, Jensen's inequality loses its strictness, and both answers equal one. At σ=0.01\sigma = 0.01 the true average is 1.00005000131.0000500013, which is why the habit of pushing the expectation inside can survive years of low-volatility work before it costs anything. The hidden hypothesis is not normality, it is integrability, and integrability is the one thing careful arithmetic on the wrong formula will never reveal.

Sources and further reading

  • Johan Ludwig Jensen, “Sur les fonctions convexes et les inégalités entre les valeurs moyennes”, Acta Mathematica30 (1906), 175–193, where the inequality is proved in the generality used here.
  • C. C. Heyde, “On a Property of the Lognormal Distribution”, Journal of the Royal Statistical Society B25 (1963), 392–393, on the log-normal law not being determined by its sequence of moments.
  • Wikipedia: Log-normal distribution, Jensen's inequality and Moment-generating function.

The value eσ2/2e^{\sigma^2/2}was confirmed two ways before publication: by completing the square symbolically, and by high-order Gauss–Hermite quadrature at five spreads, which agrees to the last digit a double carries.

Commentaires · 0

Sois le premier à commenter.