Sub topic 6
Worked example: a per-unit tax in a linear market
This chapter solves one complete tax problem by hand and in code. It assumes you can read supply and demand curves, solve two linear equations, and compute a percentage change. The earlier chapters introduced the tax wedge and the elasticity rule. Here you apply both to concrete numbers and check that they agree.
The market before the tax
Suppose a market has these curves, with quantity as a function of price:
- Demand: Qd = 100 − 2P
- Supply: Qs = 10 + P
The letters in the general form are Qd = a − bP and Qs = c + dP. Here a = 100, b = 2, c = 10, d = 1.
Set Qd = Qs and solve:
100 − 2P = 10 + P, so 90 = 3P, so P0 = 30.
Quantity is Q0 = 100 − 2(30) = 40. Check with supply: 10 + 30 = 40. In general, P0 = (a − c)/(b + d).
Imposing the tax
The government charges sellers a per-unit tax of t = 6. Sellers send 6 to the government for each unit sold.
Two prices now exist:
- Pb is the price the buyer pays.
- Ps is the price the seller keeps. Ps = Pb − t.
Buyers still respond to the price they pay, so the demand curve does not move. Sellers respond to the price they keep, so supply becomes:
Qs = 10 + Ps = 10 + (Pb − 6) = 4 + Pb.
The tax shifts the supply curve up by 6 when you read it as a price for a given quantity. Now solve for the new equilibrium:
100 − 2Pb = 4 + Pb, so 96 = 3Pb, so Pb = 32.
Then:
- Seller price: Ps = 32 − 6 = 26.
- Quantity: Q1 = 100 − 2(32) = 36. Check with supply: 10 + 26 = 36.
Buyers pay 2 more than before (32 versus 30). Sellers keep 4 less (26 versus 30). The two changes add up to the 6 tax.
General formulas
Repeat the same steps with letters. Setting a − bPb = c + d(Pb − t) gives:
- Pb = (a − c + dt)/(b + d) = P0 + t·d/(b + d)
- Ps = Pb − t = P0 − t·b/(b + d)
- Q1 = Q0 − t·bd/(b + d)
The buyer's share of the tax is d/(b + d). The seller's share is b/(b + d). With b = 2 and d = 1, buyers bear 1/3 and sellers bear 2/3.
The slope of each curve explains the split. The coefficient b says how many units demand drops for each one-dollar price rise. The coefficient d says how many units supply drops for each one-dollar price fall. Here b is larger, so buyers are the more price-responsive side. They can walk away more easily, so they absorb less of the tax.
The calculation in code
The function below computes every number above. Run it to confirm the hand calculation.
def incidence(a, b, c, d, t):
"""Linear market: demand Qd = a - b*P, supply Qs = c + d*P, per-unit tax t."""
p0 = (a - c) / (b + d) # pre-tax equilibrium price
q0 = a - b * p0 # pre-tax quantity
p_buyer = (a - c + d * t) / (b + d) # price buyers pay with the tax
p_seller = p_buyer - t # price sellers keep
q1 = a - b * p_buyer # post-tax quantity
return {
"p0": p0, "q0": q0,
"p_buyer": p_buyer, "p_seller": p_seller, "q1": q1,
"buyer_share": (p_buyer - p0) / t,
"seller_share": (p0 - p_seller) / t,
"deadweight_loss": 0.5 * t * (q0 - q1),
}
result = incidence(a=100, b=2, c=10, d=1, t=6)
for key, value in result.items():
print(key, round(value, 3))
# p0 30.0, q0 40.0, p_buyer 32.0, p_seller 26.0, q1 36.0,
# buyer_share 0.333, seller_share 0.667, deadweight_loss 12.0The two shares always sum to 1. If they do not, there is an algebra error in the price formulas.
Checking with the elasticity rule
The elasticity rule says the buyer share of a small tax is Es / (Es + |Ed|). Compute the elasticities at the pre-tax equilibrium (P = 30, Q = 40):
- Demand: Ed = −b·P/Q = −2(30)/40 = −1.5
- Supply: Es = d·P/Q = 1(30)/40 = 0.75
def buyer_share(elasticity_demand, elasticity_supply):
"""Share of a small tax borne by buyers: Es / (Es + |Ed|)."""
return elasticity_supply / (elasticity_supply + abs(elasticity_demand))
# Elasticities of the linear market at the pre-tax equilibrium (P=30, Q=40):
# Ed = -b*P/Q = -2*30/40 = -1.5, Es = d*P/Q = 1*30/40 = 0.75
print(round(buyer_share(-1.5, 0.75), 3)) # 0.333, the same as the algebraic resultThe result is 0.75 / (0.75 + 1.5) = 1/3, matching the algebra. The two methods agree because P/Q cancels from the ratio, leaving d/(b + d).
A caution about the word "small." Elasticities change along a linear curve, so the elasticity rule is exact only for infinitesimal taxes. Here the algebraic shares happen to equal the rule's result because both curves are straight lines and P/Q appears in both elasticities. If the curves were nonlinear, the rule would be only an approximation for a tax of 6.
Moving the legal obligation to buyers
Now collect the same tax from buyers instead. Buyers pay the seller's price plus 6. Demand becomes Qd = 100 − 2(P + 6), where P is the price sellers receive. Set it equal to 10 + P:
88 − 2P = 10 + P, so P = 26.
Buyers pay 26 + 6 = 32. The result is the same as when sellers were taxed.
def price_buyer_pays_if_buyer_is_taxed(a, b, c, d, t):
"""Tax collected from buyers: they pay P + t, so demand is Qd = a - b*(P + t)."""
p_seller = (a - c - b * t) / (b + d) # price sellers receive
return p_seller + t # total cost to the buyer
print(price_buyer_pays_if_buyer_is_taxed(100, 2, 10, 1, 6)) # 32.0, same as when sellers are taxedThe curves shift differently (demand moves down instead of supply moving up), but the gap between the two prices is 6 either way, and both curves must hold at the new quantity. The legal payer changes which curve you rewrite. It does not change the equilibrium.
Revenue and deadweight loss
Government revenue is the tax times the quantity actually sold: 6 × 36 = 216.
The tax removes 4 units of trade (40 to 36). Each of those units was worth more to buyers than it cost sellers to produce, but the tax wedge stopped the trade. The lost surplus is a triangle with base t = 6 (the wedge) and height Q0 − Q1 = 4:
DWL = 0.5 × 6 × 4 = 12.
For linear curves this triangle is exact for any t, not just small ones. In letters, DWL = 0.5·t²·bd/(b + d). Doubling the tax therefore quadruples the deadweight loss, while revenue grows by less than double because the quantity shrinks.
| Quantity | Value |
|---|---|
| Pre-tax price and quantity | 30 and 40 |
| Buyer price | 32 |
| Seller price | 26 |
| Post-tax quantity | 36 |
| Buyer burden per unit | 2 (one third) |
| Seller burden per unit | 4 (two thirds) |
| Tax revenue | 216 |
| Deadweight loss | 12 |
Common errors
- Forgetting to shift only one curve. Replace P with Pb − t in supply, or replace P with P + t in demand. Do not change both.
- Splitting the tax by the legal payer. The tax was levied on sellers, yet buyers still bear one third.
- Computing the post-tax quantity from the wrong price. Use demand with Pb or supply with Ps. Plugging Ps into demand gives a wrong number.
- Applying the formula for too large a tax. In this example Q1 reaches zero when t = 60. Beyond that the formulas give negative quantities and are meaningless.
- Mixing up which side is "steeper." Larger b or d means more responsive, which means a smaller burden. In price-on-quantity graphs the steepness reads the other way.
Exercise
A market has demand Qd = 80 − P and supply Qs = 2P − 10. The government places a per-unit tax of 3 on buyers. Find the pre-tax price and quantity, the price buyers pay, the price sellers receive, the post-tax quantity, the buyer share of the tax, and the deadweight loss.
Show answer
Here a = 80, b = 1, c = −10, d = 2. Pre-tax: 80 − P = 2P − 10, so P0 = 30 and Q0 = 50. With the tax on buyers, demand is 80 − (P + 3) and the seller price solves 77 − P = 2P − 10, so Ps = 29. Buyers pay 29 + 3 = 32. Post-tax quantity is 2(29) − 10 = 48. The buyer price rose by 2 out of 3, so the buyer share is 2/3, which equals d/(b + d) = 2/3. Deadweight loss = 0.5 × 3 × (50 − 48) = 3.
Exercise
In the chapter's market (Qd = 100 − 2P, Qs = 10 + P), the tax rises from 6 to 12. By what factor does the deadweight loss change, and what is the new quantity?
Show answer
Deadweight loss equals 0.5·t²·bd/(b + d) = 0.5·t²·(2/3) = t²/3. At t = 6 it is 12. At t = 12 it is 48, so it grows by a factor of 4. The new quantity is Q1 = 40 − 12(2/3) = 32.