Differential Question

35 Views Asked by At

I am trying to differentiate:

$p_2(u-\ln(\frac{p_2}{p_1}) +1)$ with respect to $p_2$

expanding the brackets I get $p_2u-p_2\ln(p_2)-p_2\ln(p_1)+p_2$

the answer I should be getting is $u-\ln(p_2)-\ln(p_1)$, however I am getting $u-\ln(p_2)-\ln(p_1)+1$, can someone show me where I'm going wrong please? I confirmed the result using wolframalpha too.

Kind Regards

2

There are 2 best solutions below

0
On

We get

$$\frac{\partial}{\partial p_2}p_2\left(\left(u-\ln\left(\frac{p_2}{p_1}\right)+1\right)\right) $$ $$= \frac{\partial}{\partial p_2}(p_2u-p_2\ln(p_2)-p_2\ln(p_1)+p_2) $$ $$=u -(\ln(p_2)+1)+\ln(p_1)+1$$ $$=u-\ln(p_2)+\ln(p_1)$$

Since

$$\frac{\partial}{\partial p_2}p_2\ln(p_2) = 1 \cdot \ln(p_2)+\frac{p_2}{p_2}=\ln(p_2)+1$$ by product rule.

0
On

When you differentiate the product of two functions you should remember that: $$\frac{d}{dx}(f(x).g(x))=f'(x)g(x)+f(x)g'(x)$$

In your case $f(p_2)=p_2$ and $g(p_2)=ln(p_2)$. So $$\frac{d}{dp_2}(p_2.ln(p_2))=ln(p_2)+ \frac{p_2}{p_2}=ln(p_2)+1$$

You should then get the answer as expected.

EDIT: there's also a problem with your expansion, maybe a typo. $$-ln(\frac{p_2}{p_1})=-(ln(p_2)-ln(p_1))=ln(p_1)-ln(p_2)$$