# Business Applications of Marginals and Differentials

##### 844 words — categories: calculus

In this post, we look at some business applications of marginals and differentials. To begin with, let’s make a recap of the topic.

- If \(C(x)\) represents the cost of producing \(x\) items, then
*marginal cost*\(C^\prime(x)\) is its derivative, and \(C^\prime(x) \approx C(x + 1) - C(x)\). Thus, the cost to produce the \((x + 1)\)st item can be approximated by \(C(x + 1) \approx C(x) + C^\prime(x)\). - If \(R(x)\) represents the revenue from selling \(x\) items, then
*marginal revenue*\(R^\prime(x)\) is its derivative, and \(R^\prime(x) \approx R(x + 1) - R(x)\). Thus, the revenue from the \((x + 1)\)st item can be approximated by \(R(x + 1) \approx R(x) + R^\prime(x)\). - If \(P(x)\) represents the profit from selling \(x\) items, then
*marginal profit*\(P^\prime(x)\) is its derivative, and \(P^\prime(x) \approx P(x + 1) - P(x)\). Thus, the profit from the \((x + 1)\)st item can be approximated by \(P(x + 1) \approx P(x) + P^\prime(x)\). - Generally, \(P(x) = R(x) - C(x)\).
- In
*delta notation*, \(\Delta x = (x + h) - x = h\), and \(\Delta y = f(x + h) - f(x)\). For small values of \(\Delta x\), we have \(\frac{\Delta y}{\Delta x} \approx f^\prime(x)\), which is equivalent to \(\Delta y \approx f^\prime(x) \Delta x\). - The
*differential*of \(x\) is \(dx\). Since, in*differential notation*, \(\frac{dy}{dx} = f^\prime(x)\), we have \(dy = f^\prime(x) dx\). In general, \(dy \approx \Delta y\), and the approximation can be very close for sufficiently small \(dx\).

## Marginal Revenue, Cost, and Profit

Let \(R(x)\), \(C(x)\), and \(P(x)\) represent revenue, cost, and profit from the production and sale of \(x\) items. If \(R(x) = 50x - 0.5x^2\) and \(C(x) = 4x + 10\), find

- \(P(x)\)
- \(R(20)\), \(C(20)\), and \(P(20)\)
- \(R^\prime(x)\), \(C^\prime(x)\), and \(P^\prime(x)\)
- \(R^\prime(20)\), \(C^\prime(20)\), and \(P^\prime(20)\)

```
from sympy import *
import numpy as np
import matplotlib.pyplot as plt
x = symbols("x")
revenue = 50 * x - 0.5 * x ** 2
cost = 4 * x + 10
profit = simplify(revenue - cost)
profit
```

`## -0.5*x**2 + 46*x - 10`

`revenue.subs({x:20}).n()`

`## 800.000000000000`

`cost.subs({x:20}).n()`

`## 90.0000000000000`

`profit.subs({x:20}).n()`

`## 710.000000000000`

```
marginal_revenue = diff(revenue, x)
marginal_cost = diff(cost, x)
marginal_profit = diff(profit, x)
marginal_revenue
```

`## 50 - 1.0*x`

`marginal_cost`

`## 4`

`marginal_profit`

`## 46 - 1.0*x`

`marginal_revenue.subs({x:20}).n()`

`## 30.0000000000000`

`marginal_cost.subs({x:20}).n()`

`## 4.00000000000000`

`marginal_profit.subs({x:20}).n()`

`## 26.0000000000000`

## Sales

Let \(N(x)\) be the number of computers sold annually when the price is \(x\) dollars per computer. Explain in words what occurs if \(N(1000) = 500 000\) and \(N^\prime(1000) = -100\). Then estimate the number of computers sold if the price is raised to $1025.

When the price is $1000 then sales equal 500,000 computers per year. However, the *marginal sales* (the sales from additional computers at that price point) are decreasing.

We can use the fact that \(\Delta y = f^\prime(x) \Delta x\) to see that the company will incur in even less sales if it raises its prices. That’s because the rate of change is negative.

```
y = 500000
dx = symbols("dx")
dy = -100 * dx
differential = dy.evalf(subs={dx:25})
differential
```

`## -2500.00000000000`

`y + differential`

`## 497500.000000000`

## Major League Ticket Prices

The average ticket price of a major league game can be modeled by the function \(p(x) = 0.09x^2 - 0.19x + 9.41\), where \(x\) is the number in years after 1990. Use differentials to predict whether ticket prices will increase more between 2010 and 2012 or between 2030 and 2031.

```
p = 0.09 * x**2 - 0.19*x + 9.41
x1 = 2010 - 1990
x2 = 2012 - 1990
dx1 = x2 - x1
x3 = 2030 - 1990
x4 = 2031 - 1990
dx2 = x4 - x3
dx = symbols("dx")
dy = simplify(diff(p, x)) * dx
dy
```

`## dx*(0.18*x - 0.19)`

`dy.evalf(subs={x:x1, dx:dx1})`

`## 6.82000000000000`

`dy.evalf(subs={x:x3, dx:dx2})`

`## 7.01000000000000`

```
x_values = np.linspace(0, 50)
func = lambdify(x, p, "numpy")
y_values = func(x_values)
plt.plot(x_values, y_values)
plt.fill_betweenx(y_values, 20, 22, alpha=0.5, color="gray")
plt.fill_betweenx(y_values, 40, 41, alpha=0.5, color="gray")
plt.title("prices since 1990; steeper increase between 2030-2031")
```

## Marginal Productivity

An employee’s monthly productivity, \(M\), in number of units produced, is found to be a function of the number of years at service, \(t\). For a certain product, the productivity function is given by \(M(t) = -2t^2 + 100t + 180\). (a) find the productivity or an employee after 5 yr, 10 yr, 25 yr, and 45 yr of service (b) find the marginal productivity (c) find the margina productivity at the same thresholds of years of service (d) explain how marginal productivity is related to age.

```
t = symbols("t")
m = -2*t**2 + 100 * t + 180
func = lambdify(t, m, "numpy")
x_values = np.linspace(0, 50)
y_values = func(x_values)
plt.plot(x_values, y_values)
plt.title("monthly units given years of service")
```

```
prod = [func(x) for x in [5, 10, 25, 45]]
prod
```

`## [630, 980, 1430, 630]`

```
mprime = diff(m, t)
mprime
```

`## 100 - 4*t`

```
marginal = lambdify(t, mprime, "numpy")
mprod = [marginal(x) for x in [5, 10, 25, 45]]
mprod
```

`## [80, 60, 0, -80]`

Productivity increases and reaches a peak at 25 yr of service after which it starts to slow down and decline.