# Integral solution (or a simpler) to consumer surplus - What is wrong?

Problem

Given demand $$D(p)=A-ap$$, and $$A,a>0$$ and a fixed price $$0 by some company.

Calculate the consumer surplus and its derivative with respect to $$p$$. What is this number?

My solution so far

I could not find a simple way to do it since quantity is not known, $$q_0$$. I calculated the consumer surplus as

$$CS=\int_{p}^{A/a}D(p)dp=\int_{p}^{A/a}(A-ap)dp=\frac{1}{2a}(A-ap)^2=\frac{(A-ap)^2}{2a}$$

and its derivative as

$$\frac{\partial CS}{\partial p}=\left ( \frac{(A-ap)^2}{2a} \right )=2(A-ap) \left ( \frac{\partial }{\partial p} (A-ap) \right )\frac{1}{2a}=-(A-ap)\left ( \frac{\partial }{\partial p} p \right )=-A+ap$$

Which I am almost certain is incorrect. I am not sure on how to approach this without a equalibrium or am I missing it?

• It seems you deleted your last post where you had used $0$ as the lower limit. Please edit the same question rather than deleting that and asking a new one. Dec 2, 2020 at 3:22
• The demand curve is linear so you don't even need to use integration and can just simply calculate the area of the triangle (as a function of the price $p$).
– user18
Dec 2, 2020 at 4:35

Your calculation is correct. We can doublecheck your work with a graphical approach.

As shown in the figure below, $$CS$$ at some arbitrary and not necessarily equilibrium price $$p_0$$ is the gray-shaded area. If we take the non-integral approach, we get $$\begin{equation} CS=\frac12\left(\frac{A}a-p_0\right)D(p_0)=\frac12\left(\frac{A}a-p_0\right)(A-ap_0)=\frac{(A-ap_0)^2}{2a}. \end{equation}$$ Differentiating with respect to $$p_0$$, we get $$\begin{equation} CS'=-A+ap_0. \end{equation}$$ • But if the supplied quantity at that price is $S(p_0)=q_0<D(p_0)$, the CS would not simply be this triangle, but a smaller triangle $(A/a−D^{−1}(q_0))q_0/2$ plus a rectangle $q_0∗(D^{−1}(q_0)−S(p_0)$. Dec 2, 2020 at 12:08
• @Bayesian: Good point. I guess we will also have to assume sufficient supply to meet the quantity demanded at $p_0$. Dec 2, 2020 at 15:19
• @HerrK. Thanks a lot for the help. I am having trouble on how to intepret the derivative. It is the demand at $p_1$ but with reversed sign. What does that mean.
– user31331
Dec 2, 2020 at 18:29
• @bymathformath: The interpretation of the derivative should be standard: If price is increased by $\$1$, then consumer surplus will decrease by (approximately)$\$D(p_0+1)$. This decrease in $CS$ can be visualized as the area of a rectangle at the bottom of the gray shaded area Dec 2, 2020 at 22:19
• @bymathformath: The change in CS is correct, but DWL is not. DWL has to include reduction in producer surplus and exclude tax revenue. Dec 10, 2020 at 0:01

Although your question is already answered, I am just adding a small interesting detail that might help from doing some math (especially if the demand function is rather complex):

See that (for any constant $$a$$):

$$f(x) = \frac{d}{dx}\int_a^x f(x)$$

Now just looking at the definition of CS, we have that $$CS'=-D(p)$$

• Ah okay I see so in this case $CS'=-D(p_{1})$.
– user31331
Dec 2, 2020 at 16:08
• What does this actually mean, though. That the derivative of the consumer surplus is the opposite sign of the demand function at that point? That explanation I gave can't be useful.
– user31331
Dec 2, 2020 at 18:21
• I think the interpretation given by @HerrK. is sufficient. Think of the CS as area under inverse demand curve less the rectangle $pQ$. A unit increase in price decreases this by approximately $Q$. Dec 3, 2020 at 2:08
• May I ask one more thing; would the change in consumer surplusbecause of a tax just be $- \Delta CS=-(CS-CS_{tax})$ and the DWL just be with reversed sign i.e $DWL= \Delta CS=CS-CS_{tax}$ ?
– user31331
Dec 9, 2020 at 17:51
• @bymathformath afaik, DWL also includes loss due to change in producer surplus. As per your calculation, the lower triangle in DWL will be missed Dec 10, 2020 at 4:50