We go over some textbook exercises for exponential functions.

Franchise Expansion

A franchise business is selling franchises for pizza shops throughout the country. The marketing manager estimates that the number of franchises, \(N\), will increase at the rate of 10% per year, that is,

\[\frac{dN}{dt} = 0.10N\]

  1. Find the function that satisfies this equation, assuming that the number of franchises at \(t = 0\) is 50.
  2. How many franchises will be there in 20 years?
  3. In what period of time will the initial number of 50 franchises double?
from sympy import *
from math import e
from sympy.abc import N, t

N = Function("N")(t)
dNdt = Eq(N.diff(t), 0.10 * N)
f = dsolve(dNdt, N)
f
## Eq(N(t), C1*exp(0.1*t))
def f(t, c):
  return c * e**(0.1 * t)


f(20, 50)
## 369.45280494653247
solve(50 * e**(0.1 * t) - 100, t)
## [6.93147180559944]

Compound Interest

Suppose that \(P_0\) is invested in a fund for which interest is compounded continuously at 5.9% per year. That is, the balance \(P\) grows at the rate given by

\[\frac{dP}{dt} = 0.059P\]

  1. Find the function that satisfies the equation.
  2. Suppose that $1000 is invested, what is the balance after 1 year and 2 years?
  3. When will a $1000 investment double itself?
from sympy.abc import P

P = Function("P")(t)
dPdt = Eq(P.diff(t), 0.059 * P)
dPdt
## Eq(Derivative(P(t), t), 0.059*P(t))
dsolve(dPdt, P)
## Eq(P(t), C1*exp(0.059*t))
def f(t, c):
  return c * e**(0.059 * t)

f(1, 1000)
## 1060.775240740159
f(2, 1000)
## 1125.2441113673424
solve(1000 * e**(0.059 * t) - 2000, t)
## [11.7482572976262]

Value of Manhattan Island

Peter Minuit o the Dutch West India Company purchased Manhattan Island from the natives living there in 1626 for $24 worth of merchandise. Assuming an exponential rate of inflation of 5%, how much will Manhattan be worth in 2020?

Let’s assume the growth model for the value of the island is given by

\[\frac{dV}{dt} = 0.05V\]

The function that satisfies this rate of change is

\[V(t) = ce^{0.05t}\]

from sympy.abc import V

V = Function("V")(t)

dVdt = Eq(V.diff(t), 0.05 * V)
dVdt
## Eq(Derivative(V(t), t), 0.05*V(t))
f = dsolve(dVdt, V)
f
## Eq(V(t), C1*exp(0.05*t))
years = 2020 - 1626

def f(t, c):
  return c * e**(0.05*t)

f(years, 24)
## 8626061203.204306

Cost of Hershey Bar

The cost of a Hershey bar was $0.05 in 1962 and $0.75 in 2010.

  1. Find an exponential function that fits the data.
  2. Predict the cost of a Hershey bar in 2015 and 2025.

The assumtion is that the value of a bar has grown exponentially

\[\frac{dV}{dt} = kV\]

Because the value at \(t = 0\) is $0.05, we can say that the exponential function is

\[V(t) = 0.05e^{kt}\]

We know that 48 years after 1962, the value is $0.75, therefire

\[0.75 = 0.05e^{k(48)}\]

and we need to find \(k\).

from sympy.abc import k

years = 2010 - 1962
equation = Eq(0.75, 0.05 * e**(k*years))
k = solve(equation, k)[0]
k
## 0.0564177125229626
def f(t, c):
  return 0.05 * e**(c*t)

  
f(2015 - 1962, k)
## 0.994422104712232
f(2025 - 1962, k)
## 1.74819462993714

Diffusion of Information

Pharmaceutical firms invest significantly in testing new medications. After a drug is approved by the FDA, it still takes time for physicians to fully accept and start prescribing the medication. The acceptance by physicians approaches a limit value of 100%, or 1, after time \(t\), in months. Suppose that the percentage \(P\) of physicians prescribing a new cancer medication after \(t\) months is approximated by

\[P(t) = 100(1 - e^{-0.4t})\]

  1. What percentage of doctors are prescribing the medication after 0, 1, 2, 3, 5, 12, and 16 months?
  2. Find \(P^\prime(7)\) and interpret its meaning.
  3. Sketch a graph of the function.
def p(t):
  return 100 * (1 - e**(-0.4 *t))
  
percentages = [round(p(t), 2) for t in [1, 2, 3, 5, 12, 16]]
percentages
## [32.97, 55.07, 69.88, 86.47, 99.18, 99.83]
expr = 100 * (1 - e**(-0.4 *t))
expr.diff()
## 40.0*2.71828182845905**(-0.4*t)

The equation

\[p^\prime(t) = 40e^{-0.4t}\] tells us the rate of change of the percentage of phyicians that accept the new medication at any given time (in months).

import numpy as np
import matplotlib.pyplot as plt

x_values = np.linspace(0, 20)

plt.plot(x_values, p(x_values))
plt.title("% physicians accepting and prescribing new medication")

Hullian Learning Model

The Hullian learning model asserts that the probability \(p\) of mastering a task after \(t\) learning trials is approximated by

\[p(t) = 1 - e^{-kt}\]

where \(k\) is a constant that depends on the task to be learned. Suppose a new dance is taught to an aerobics class. For this particular dance, the constant \(k = 0.28\).

  1. What is the probability of mastering the dance’s steps in 1, 2, 5, 11, 16, 20 and trials?
  2. Find the rate of change, \(p^\prime(t)\).
  3. Sketch a graph of the function.
def p(t, k):
  return 1 - e**(-k*t)
  
constant = 0.28

probabilities = [round(p(t, constant), 2) for t in [1, 2, 5, 11, 16, 20]]
probabilities
## [0.24, 0.43, 0.75, 0.95, 0.99, 1.0]
expr = 1 - e**(-k*t)
expr.diff()
## 0.0564177125229626*2.71828182845905**(-0.0564177125229626*t)
x_values = np.linspace(0, 25)

plt.plot(x_values, p(x_values, constant))
plt.title("$p(t)$ of mastering dance steps after $t$ trials")