# 14.5 Partial Equilibrium

We’re now — finally! — ready to bring market demand and market supply together.

Market equilibrium occurs when the price is such that the market quantity demanded equals the market quantity supplied.

Formally, a price $p^\star$ is an equilibrium price in a market if:

**Consumer optimization**: each consumer $i$ is consuming the quantity $x^i(p^\star)$ that solves their utility maximization problem.**Firm optimization**: each firm $j$ is consuming the quantity $q^j(p^\star)$ that solves its profit maximization problem.**Market clearing**: the total quantity demanded by all consumers equals the total quantity supplied by all firms: $D(p) = S(p)$.

For example, in the past two sections, we derived the supply and demand functions \(\begin{aligned}S(p) &= N_F \times {\overline K p \over 2w}\\ D(p) &= N_C \times {\alpha m \over p}\end{aligned}\) If we set these two equal to one another, we get \(\begin{aligned}S(p) &= D(p)\\ N_F \times {\overline K p \over 2w} &= N_C \times {\alpha m \over p}\\ p^2 &= {N_C \over N_F} \times {2 \alpha m w \over \overline K}\\ p^\star &= \sqrt{\frac{N_C}{N_F} \times {2 \alpha m w \over \overline K}}\end{aligned}\) Plugging this back into either the demand or supply function gives us the quantity in the market will be \(Q^\star = S(p^\star) = D(p^\star) = \sqrt{N_FN_C\overline K \alpha m \over 2w}\) This looks like a lot of variables! But in fact, what we’re seeing is that we can do all our usual Econ 1 comparative statics just from these expressions:

- If more consumers enter the market $(\uparrow N_C)$, or if consumers desire this good more $(\uparrow \alpha)$, or if consumers get more money $(\uparrow m)$ the demand curve shifts to the right; the equilibrium price and quantity both rise.
- If more firms enter the market $(\uparrow N_F)$ or if firms invest more capital in producing this good $(\uparrow \overline K)$, the supply curve shifts to the right; the equilibrium price falls, and the equilibrium quantity rises.
- If the wage rate increases $(\uparrow w)$, the supply curve shifts to the left; the equilibrium price rises, and the equilibrium quantity falls.

You can see how each of these effects (and their opposites) play out in the following diagrams. The middle diagram shows market supply and demand; the left diagram shows individual demand, and the right diagram shows individual supply.

Try changing the parameters, and see what happens to the supply or demand curves.