# Upper bound for $e^x$

How do I prove that $$e^x \leq x + e^{x^2}$$ for all $$x\in\mathbb R$$?

My probability book (Grimmett and Stirzaker) says that it's a simple exercise but I don't see it. For $$x\leq 0$$, we have $$e^x = \sum_{k=0}^\infty \frac{x^{2k}}{(2k)!} + x + \sum_{k=1}^\infty \frac{x^{2k+1}}{(2k+1)!} \leq \sum_{k=0}^\infty \frac{x^{2k}}{k!} + x = e^{x^2} + x.$$ How do I show it for $$x>0$$?

• Specifically what are you confused about here? Are you confused about how they do it for $x\le0$, or do you understand that and want to know how to proceed for the case where $x > 0$? – Decaf-Math Sep 28 '18 at 22:21
• @Decaf-Math I want to know how to proceed for $x>0$ – Alain Sep 28 '18 at 22:22
• also easy for $x \geq 1$ – Will Jagy Sep 28 '18 at 22:24
• A different approach is to consider the function that is the difference between the left hand side and the right hand side of your inequality. This is equal at x equals 0 and then you can just compute the derivative to complete the proof. – ericf Sep 28 '18 at 22:30
• @ericf I thought about that too. Say $f(x) = x + e^{x^2} - e^x$. Then $f'(x) = 1 + 2x e^{x^2} - e^x$. How to show that $f'(x)>0$ for $x>0$? – Alain Sep 28 '18 at 22:34

For $$x\geq 0$$, we have $$x e^{-x}+e^{x^2-x}\geq x(1-x)+1+x^2-x=1$$ where we used the inequality $$e^{u} \geq 1+u$$ for all $$u$$. Multiplying on both sides by $$e^x$$, we find $$x+e^{x^2}\geq e^x$$ For $$x<0$$, note that $$e^{x^2}\geq 1+x^2$$, then $$x+e^{x^2}\geq1+x+x^2=3/4+(x+1/2)^2>0$$ Consequently, we also have $$\left(x+e^{x^2}\right)e^{-x}\geq(x+1+x^2)(1-x)=1-x^3,$$ which implies that $$x+e^{x^2}\geq(1-x^3)e^x>e^x$$

• Thanks for pointing that out. I think corrected this problem now. – minmax Sep 30 '18 at 21:33

The function $$f(x):=e^{x^2}-e^x$$ has $$f(0)=0$$, $$f'(0)=-1$$ and $$f''(x)=(4x^2+2)e^{x^2}-e^x\ .$$ Obviously $$f''(x)>0$$ when $$x\leq0$$ or $$x\geq1$$. For $$0\leq x\leq1$$ note that $$4x^2+2=\left(2x-{1\over2}\right)^2+{7\over4}+2x>1+(e-1)x\geq e^x\ ,$$ since $$e-1<2$$ and $$\exp$$ is convex. It follows that $$f$$ is convex, and this implies that the line $$y=-x$$ supports the graph of $$f$$ at $$(0,0)$$, i.e. $$-x\leq e^{x^2}-e^x\qquad(-\infty

• nice use of convexity! should have thought about it when considering $0<x<1$. – Alain Sep 30 '18 at 16:43

The case $$x\ge1$$ is trivial. For $$0, we have $$\frac{e^x-e^{x^2}}{x-x^2}\le e^x\le\frac1{1-x}.$$ The first inequality is true because the LHS, by mean value theorem, is $$e^a$$ for some $$a\in(x^2,x)$$. For the second one, note that $$f(x):=(1-x)e^x\le1=f(0^+)$$ because $$f$$ is decreasing ($$f'(x)=-xe^x<0$$) on $$(0,1)$$.

• why is LHS equal to $e^a$? – Alain Sep 30 '18 at 16:44
• @Alain Mean value theorem. – user1551 Sep 30 '18 at 17:55

We have that

• for $$x\ge1$$

$$x\le x^2 \implies e^x\le e^{x^2}\le x+ e^{x^2}$$

• for $$0

$$e^{x^2}+x\ge 1+x+x^2 \stackrel{?}\ge e^x =1+x+\frac12x^2+\frac16x^3+\ldots$$

and

$$1+x+x^2 \stackrel{?}\ge 1+x+\frac12x^2+\frac16x^3+\ldots \iff \frac12x^2 \stackrel{?}\ge \frac16x^3+\frac1{24}x^4+\ldots \iff \frac12 \stackrel{?}\ge \frac16x+\frac1{24}x^2+\ldots$$

then to prove $$e^x\le x+ e^{x^2}$$ it suffices to show that the latter holds for $$x=1$$ that is

$$\frac12 \ge \frac16+\frac1{24}+\ldots \ge \frac16x+\frac1{24}x^2+\ldots$$

$$\iff 1 \ge \frac13+\frac1{12}+\frac1{60}\ldots=2\sum_{k=3}^\infty \frac{1}{k!}=2e-5$$

• The first $\iff$ should be $\impliedby$ – ℋolo Sep 29 '18 at 2:07
• @Holo Yes of course, I fix that typo. Thanks – user Sep 29 '18 at 3:06