Does anyone have any general rules of thumb for when to use $e^x$ vs $2^x$ (or any other non-special exponential) during modeling?

81 Views Asked by At

Recently, I picked up a book about statistics and probability. I know $e^x$ is special because of its derivative and corresponding growth rate. However, I have a hard time connecting this academic factoid to real-life examples. Everything I can think of (e.g., investments doubling each cycle or the growth of bacteria dividing) all seems to work fine with $2^x$.

Can someone here who is experienced with statistics and probability give some examples of $e^x$ in real life and also offer some general pointers on when you should use it vs other non-special exponential bases?

P.S. Please be advised that I am a layman - and not a professional mathematician.

5

There are 5 best solutions below

0
On BEST ANSWER

To summarize the discussion in the comments...

We can easily convert between bases, using the fact that $$b^x=e^{x\ln b}$$ so long as $b>0$.

Mathematically, therefore, there really isn't much to distinguish the various bases, as we can easily switch between them. In practice, sticking to base $e$ has the advantage of making it somewhat easier to differentiate or integrate. On the other hand, for discussions involving doubling time or half life, base $2$ might be more natural.

2
On

On the contrary, in most real real-life examples, as opposed to ones made up for pedagogical purposes, you're unlikely to have powers of $2$ (or of any other positive integer). Investments, for example, don't double in a given period, they might earn $4.27 \%$ a year or whatever the current rate is. This can be dealt with by functions of the form $e^{r t}$ where $t$ is time and $r$ is a constant.

0
On

It's rare that any real life process is exactly modeled by the function $f$ with $f(x)=e^x$. And for good reason: In real life applications, quantities have units, but exponents have to be unitless. The quantity $e^{3 \mathrm{seconds}}$ makes no sense. But neither does $2^{3\mathrm{seconds}}$. So the function $2^x$ also rarely models a real life process exactly. The exponent always needs an additional factor to cancel any units. So taking your example of bacterial growth, let's say with bacteria doubling every minute, then the actual function modeling the bacterial growth is $f(t)=2^{1~\mathrm{min}^{-1}\cdot t}$. So, for instance, $f(4~\mathrm{min})=2^{1~\mathrm{min}^{-1}\cdot 4~\mathrm{min}}=2^4=16$. The factor $1~\mathrm{min}^{-1}$ is needed to keep the units in check. But with this in mind, note that even if the base is simple, the function modeling our process looks like $f(t)=a^{bt}$. The $b$ is always there, telling us, for instance, how often $f$ grows by a factor of $a$ in a given time. In our bacterial example, it tells us that the bacteria double once every minute.

But then note that $a=e^{\ln a}$, so $a^{bt}=(e^{\ln(a)})^{bt}=e^{b\ln(a)t}$. So we can just as well express our function in base $e$, and the structure doesn't change one bit. It's still some number to the power of a product. The factors are now $b\ln(a)$ and $t$ instead of $b$ and $t$, but what does it matter? It's still a constant times a variable $t$. But the version with base $e$ has the humongous advantage that it allows us to use all the theoretical knowledge about the natural exponential function, especially about its derivatives. So this is often the preferred way to express the function.

An example: You are probably familiar with the half life of radioactive matter. When starting with 1000000 atoms, and their half life $T_{1/2}$ is known, then after a time $t$, we have $1000000\cdot2^{-t/T_{1/2}}$ atoms left. But this is not how a theoretical physicist would express it. A theoretical physicist would use the mean lifetime $\tau=\frac{T_{1/2}}{\ln 2}$ instead of the half life $T_{1/2}$ and express the whole thing as $1000000\cdot e^{-t/\tau}$. Same structure, just different base and factor in the exponent, and the results are equal. But they can now examine the behavior of the decaying matter with the full power of the exponential function. For instance, it is quickly visible that the function follows the differential equation $f'(t)=-\frac{f(t)}{\tau}$, which could allow for the theoretical derivation of how large $\tau$ is.

To summarize, every exponential function can be expressed in any base you want. Base $e$ is the best base to do theoretical work.

0
On

As mentioned elsewhere, $2^x=e^{x\cdot \ln 2}$. Further, $e^x$ is its own derivative. This latter point has some important implications though.

Since $e^x$ is its own derivative and many important differential equations are linear, this allows using principles of linear algebra to solve differential equations. Because of the equivalence above, $2^x$ could also work, but would introduce a $\ln 2$ all over the place.

Regarding statistics, the bulk of my experience comes from statistical mechanics in which solutions to various problems often take the form of $\frac{\zeta(x) }{e^x-1}$.

In Quantum Mechanics, which relies heavily on statistical principles, solutions are often of the form $e^{-px}$ or $e^{-\alpha x^2}$ where $p$ and $\alpha$ are typically the ratio of physically meaningful ratios. In the case of the Quantum Harmonic Oscillator, $\alpha = \frac{m\omega}{2\hbar}$. The $2$ vanishes when calculating expectation values, so the coefficient is exclusively in terms of physically meaningful quantities in practice. Were the base $2$ instead, then we'd have $\alpha = \frac{m \omega}{2\hbar \ln 2}$. A slightly more complicated expression with $\ln2$ having no clear physical significance.

Whatever base you use, unless $x$ is an integer, base $2$ offers nothing over base $e$.

0
On

When first introducing students to the idea of what a function is, I try to emphasize certain geometric aspects of those functions. For example if $f$ is a function which "eats" real numbers and "poops out" other real numbers, then the graph of $f$ can be transformed in a number of ways. For example, we can define a new function $g$ which scales the graph of $f$ horizontally by a factor of $a$ via the formula $$ g(x) = f\!\left( \frac{1}{a} x \right).$$ In this framework, it is often desirable to demonstrate that certain kinds of functions are all transformations of a single primitive function—if you can understand the properties of the primitive function, then you understand the entire class.

My goto first example is quadratic functions: every parabola can be understood as a transformation of the primitive quadratic function $p$, defined by the formula $p(x) = x^2$. If $q$ is a quadratic function, i.e. if $$ q(x) = ax^2 + bx + c$$ for some real numbers $a$, $b$, and $c$, then $$ q(x) = A(x-h)^2 + k, $$ where $$ A = a, \qquad h = -\frac{b}{2a}, \qquad \text{and}\qquad k = c - \frac{b^2}{4a}. $$ Here, $A$ corresponds to a vertical scaling by a factor of $A$, $h$ corresponds to a horizontal translation of $h$ units to the right, and $k$ corresponds to a vertical translation of $k$ units.

In short, every quadratic function is a transformation of the primitive function.

Something similar is true for exponential functions: there is a primitive exponential function (i.e. the natural exponential function), which is defined by the formula $$ \exp(x) = \mathrm{e}^x. $$ For any positive real number $b$, observe that $$ b = \mathrm{e}^{\log(b)}, $$ where $\log$ represents the natural logarithm. Hence $$ b^x = \left( \mathrm{e}^{\log(b)} \right)^x = \mathrm{e}^{\log(b) x} = \exp(\log(b)x). $$ As noted above, if $g(x) = f(x/a)$, then $g$ is a "copy" of $f$, after a horizontal scaling. Hence the graph of $$ g(x) = \exp(\log(b)x) $$ is the same as the graph of $\exp(x)$ after being scaled horizontally by a factor of $1/\log(b)$. That is, both $b^x$ and $\mathrm{e}^x$ have the same graph (after a bit of stretching or compression). I've tried to illustrate this in a GeoGebra plot—I've highlighted a couple of points to demonstrate the action of the horizontal scaling as $b$ varies.

All of this implies that, from a mathematical perspective, there is no real reason to care about the base of an exponential function. Any problem which can be solved with a base of $10$ can just as easily be solved with a base of $2$, or $\mathrm{e}$, or $47$—it just doesn't matter.

In the real world, the particular problem being solved will sometimes dictate a choice of base. For example, when dealing with the rate at which chemicals are eliminated by the body (the "biological half-life" of a substance), it is perhaps convenient to work with functions of the form $$ A(t) = A_0 \left( \frac{1}{2} \right)^{t/k}, $$ where $A(t)$ denotes the amount of the substance in the bloodstream at time $t$, $A_0$ is the initial dose, and $k$ is the biological half-life of the substance.

However, most of the time, you are going to eventually have to feed your work into a calculator or computer. I don't know about you, but my calculator only has two buttons for logarithms: LN for the natural logarithm, and LOG for the base-10 logarithm. Since any problem involving exponentials is probably eventually going to require logarithms, I probably want to work with exponential functions with one of those bases. Because the natural exponential has some other nice properties (e.g. it is its own derivative), mathematicians typically choose to work with the exponential function with base $\mathrm{e}$.