While self-studying through the textbook Mathematical Methods for Physics and Engineering by Riley et al., I came across the following example:
$x=\rho\cos\phi\\y=\rho\sin\phi$
For a function $f(x,y)$, which can be re-expressed as a function $g(x,y)$, transform the expression $\frac{\partial^2f}{\partial x^2} + \frac{\partial^2f}{\partial y^2}$ into one in $\rho$ and $\phi$.
The authors then proceed do the following:
They state that $\frac{\partial}{\partial x}=\cos\phi\frac{\partial}{\partial \rho}-\frac{\sin\phi}{\rho}\frac{\partial}{\partial \phi}$ (similarly for $\frac{\partial}{\partial y}$).
Then, they re-write $\frac{\partial^2f}{\partial x^2}$ as $\frac{\partial}{\partial x}(\frac{\partial}{\partial x})\,f$ and, consequently, $\frac{\partial}{\partial x}(\frac{\partial}{\partial x})\,g$, where $\frac{\partial}{\partial x}(\frac{\partial}{\partial x})\,g$ = $(\cos\phi\frac{\partial}{\partial \rho}-\frac{\sin\phi}{\rho}\frac{\partial}{\partial \phi})(\cos\phi\frac{\partial g}{\partial \rho}-\frac{\sin\phi}{\rho}\frac{\partial g}{\partial \phi})$
They then proceed to obtain the final result by a way of "multiplicating" the two expressions in the brackets.
My question is: how does that exactly work? Is there a proof behind such a property?
I haven't encountered such an analogous method in single-variable differentiation and found the book's method fascinating and confusing. The way I approached the problem was by partially differentiating twice, which happened to be extremely tedious.
Nonetheless, I was looking for a more analytic/rigorous explanation of the book's method.