I am struggling for hours on a fairly simple problem. I have the following set of parametric equations:
$$i = I (q_1^2 + q_1 - q_2^2 - q_2)$$ $$v = V (2(q_1 - 1) + \log q_1 - 2(q_2 - 1) - \log q_2)$$
Now I would like to calculate $\frac{di}{dv}$. The canonical way would be to solve the second equation for $q$, plug it into the first and find the derivative. But the second equation is not easily invertible.
So I treat the $q$ as a function of $v$ and take the derivative of the first equation.
Then I take the derivative of the second w.r.t. $q_1$ and $q_2$ and obtain the expressions for $\frac{d v}{d q_1}$ and $\frac{d v}{d q_2}$. Taking the reciprocal value and inserting them into the derivative of the first equation results in:
$$\frac{d i}{d v} = \frac{I}{V}(q_1 + q_2)$$
However, from a paper (and from physical results) I know that the solution must be
$$\frac{d i}{d v} = 2 \frac{I}{V} \frac{q_1 q_2}{q_1 + q_2}$$
I went over it tens of times, tried with Mathematica but the result is always wrong.
Is this approach fundamentally wrong?
You’re running into trouble because for partial derivatives, which is what you’re really working with here, it’s not generally true that $\frac{\partial x}{\partial y}=\left. 1 \middle/ \right. {\frac{\partial y}{\partial x}}$.
One way to attack this problem is to compute $di$ and $dv$, divide one by the other, and try to eliminate the $\mathrm dq$’s:$$ \mathrm di = I((2q_1+1)\;\mathrm dq_1 - (2q_2+1)\;\mathrm dq_2) \\ \mathrm dv = V((2+\left. 1 \middle/ \right. q_1)\;\mathrm dq_1 - (2+\left. 1 \middle/ \right. q_2)\;\mathrm dq_2) $$ It might make the algebraic manipulations easier by defining $$ \alpha(q_1) = q_1^2+q_1 \\ \beta(q_2) = q_2^2+q_2 $$ so that $$ \mathrm di = I(\mathrm d\alpha - \mathrm d\beta) \\ \mathrm dv = V\left(\frac 1{q_1}\mathrm d\alpha - \frac 1{q_2}\mathrm d\beta\right) \\ \frac{\mathrm di}{\mathrm dv} = \frac I V \frac{\mathrm d\alpha - \mathrm d\beta}{\frac 1{q_1}\mathrm d\alpha - \frac 1{q_2}\mathrm d\beta} $$ This seems promising. It might also be of use to note that $$\frac{q_1 q_2}{q_1+q_2}=\frac 1{\frac 1 {q_1}+\frac 1 {q_2}}$$