# 12.3 Finding the Profit Maximizing Quantity to Produce

## Total revenue, cost, and profit

Having defined a firm’s costs in chapter 13, and a firm’s revenues in the previous section, we can now combine these to define its profit function, $\pi(q)$: \(\overbrace{\pi(q)}^\text{PROFIT} = \overbrace{r(q)}^\text{REVENUE} - \overbrace{c(q)}^\text{COST}\)

For example, let’s combine the cost function from Chapter 13 \(c(q) = 64 + \tfrac{1}{4}q^2\) with the revenue function from the last section \(r(q) = 20q - q^2\) For such a firm, their total profit would be \(\pi(q) = r(q) - c(q) = 20q - q^2 - [64 + \tfrac{1}{4}q^2] = -64 + 20q - \tfrac{5}{4}q^2\) If we plot the firm’s total revenue, total cost, and total profit curves, we can see that the total profit is the vertical distance between the total revenue and total cost curves. Where $TR > TC$, the firm is running a profit; where $TR < TC$, the firm is running a loss:

## Marginal revenue, cost, and profit

The marginal profit from the $q^\text{th}$ unit produced is the derivative of this function with respect to $q$: \(\pi^\prime(q) = \overbrace{r^\prime(q)}^{MR} - \overbrace{c^\prime(q)}^{MC}\) The firm’s version of a “gravitational pull” argument is by now familiar to us: if producing another unit increases a firm’s profit ($\pi^\prime(q) > 0$, or $MR > MC$) then the firm will expand its output, while if its marginal profit is negative ($\pi^\prime(q) < 0$, or $MR < MC$) then a firm will cut back on production; and as long as things are “well behaved,” the firm’s profit-maximizing quantity will occur at the point where $MR = MC$.

For the specific example above, the marginal profit of the firm would be \(\pi^\prime(q) = r^\prime(q) - c^\prime(q) = \overbrace{20 - 2q}^{MR} - \overbrace{\tfrac{1}{2}q}^{MC}\) Setting this equal to zero gives us \(\begin{aligned} MR &= MC\\ 20 - 2q &= \tfrac{1}{2}q\\ q^\star &= 8 \end{aligned}\)

Visually, we can see that this occurs at the point where the slopes of the TR and TC curves are the same:

To see why this is the profit-maximizing point, try dragging $q$ so it’s a little less than 8 — say, $q = 6$. Notice that in this range, $MR > MC$, so the distance representing profit is increasing as you move to the right. Conversely, if you move $q$ to be a little more than 8 (for example $q = 10$), you can see the opposite is true: increasing production in this range narrows the distance between revenues and cost, decreasing the firm’s profits.

## Unit cost and revenue analysis

Let’s now turn to analyzing the profit maximization problem in a unit cost and revenue diagram. The following diagram shows the firm’s average revenue and cost, and its marginal revenue and cost:

Notice that the area between AR and AC, up to the quantity $q$, is shaded in. This represents the profit or loss of the firm. Why? Look what happens if we multiply the profit function for the firm by $q/q$:
\(\text{Profit} = TR - TC = \left[{TR \over q} - {TC \over q}\right] \times q = [AR - AC] \times q\)
In other words, the firm’s *total profit* is its *average profit* (that is, $AR - AC$) times the number of units it sells. Visually, this is the area with height $AR - AC$ and width $q$.

Finally, notice that (although we haven’t said it explicitly) the price the firm charges is found by plugging the optimal quantity back into the inverse demand curve. In this case, the firm maximizes its profit by producing $q^\star = 8$, so the price it charges is $p(8) = 20 - 8 = 12$.