I am following this derivation or proof (which one would I call it?). Most of it is straight forward but there is a jump on a specific line that I do not understand. I am going to draw it out here.
Take the following as given: \begin{align} x &= r\cos\theta;\qquad y = r\sin\theta;\qquad u=u(x,y);\\\\ \frac{\partial u}{\partial r}&=\frac{\partial u}{\partial x}\frac{\partial x}{\partial r} + \frac{\partial u}{\partial y}\frac{\partial y}{\partial r}=\cos\theta\frac{\partial u}{\partial x} + \sin\theta\frac{\partial u}{\partial y}. \tag{1}\label{main} \end{align}
I am attempting to convert the Laplace equation to polar. The proof that I am following says that $$ \frac{\partial^2 u}{\partial r^2}= \cos\theta\frac{\partial}{\partial r}\frac{\partial u}{\partial x} + \sin\theta\frac{\partial }{\partial r}\frac{\partial u}{\partial y}\label{alien} \tag{2} $$ This makes sense, just taking the partial derivative with respect to $r$ to all of the terms on both sides. The following, I do not understand and would appreciate explanation:
$$ \begin{align} \frac{\partial^2 u}{\partial r^2}= \cos\theta \left( \frac{\partial}{\partial x}\frac{\partial u}{\partial x}\frac{\partial x}{\partial r} + \frac{\partial }{\partial y}\frac{\partial u}{\partial y}\frac{\partial y}{\partial r} \right) + \sin\theta\left( \frac{\partial}{\partial x}\frac{\partial u}{\partial x}\frac{\partial x}{\partial r} + \frac{\partial }{\partial y}\frac{\partial u}{\partial y}\frac{\partial y}{\partial r}\right ).\tag{3} \label{marsh} \end{align}$$
If I assumed that this could happen, then next line is a bit intuitive, but also odd: \begin{align} \frac{\partial^2 u}{\partial r^2}= \cos^2\theta\frac{\partial^2 u}{\partial x ^2} + \sin^2\theta\frac{\partial u^2}{\partial y^2} + 2\cos\theta\sin\theta\frac{\partial^2 u}{\partial x \partial y}.\label{dobop} \tag{4} \end{align} This seems a bit intuitive because of $\ref{main}$ has the equality: \begin{align} \frac{\partial u}{\partial x}\frac{\partial x}{\partial r} + \frac{\partial u}{\partial y}\frac{\partial y}{\partial r}=\cos\theta\frac{\partial u}{\partial x} + \sin\theta\frac{\partial u}{\partial y}. \end{align} Just looking at it I could be convinced that: \begin{align} \frac{\partial x}{\partial r} = \cos \theta \qquad \frac{\partial y}{\partial r} = \sin \theta. \end{align}
Here are my main questions:
- What is going on between $\ref{alien}$ and $\ref{marsh}$?
- What is going on between $\ref{marsh}$ and $\ref{dobop}$?
Side question:
- Any good books that would help me learn about partial derivatives and what is right and wrong to do?