In thermodynamics one works with state functions, e.g., the energy function $U(Y_1,\dotsc,Y_n)$, where $Y_i>0$ are the so called extensive variables. This function is $1$st order homogeneous. Sometimes one uses the specific energy function $$u(y_1,\dots,y_{n-1})=U(y_1,\dots,y_{n-1},1),$$ where $y_i=\frac{Y_i}{Y_n}$. The relation between $u$ and $U$ is $$Y_n\cdot u(y_1,\dotsc,y_n)=U(Y_1,\dots,Y_n).$$ I want to understand how to express second order partial derivatives $\frac{\partial^2u}{\partial y_i\partial y_j}$ in terms of $\frac{\partial^2U}{\partial Y_i\partial Y_j}$ and $Y_i$.
Let's start with the first order derivatives. Using the chain rule we can write $$\frac{\partial u}{\partial y_i}=\sum_{k=1}^n \frac{\partial U}{\partial Y_k}\frac{\partial Y_k}{\partial y_i}.$$ But now I get stuck. What is $\frac{\partial Y_k}{\partial y_i}$? Can we simply write it as $\frac{\partial Y_k}{\partial y_i}=1/\frac{\partial y_i}{\partial Y_k}$? Apparently not as otherwise, e.g., $\frac{\partial y_1}{\partial Y_2}=0$ and $\frac{\partial Y_2}{\partial y_1}=\infty$. How can we deal with that?
Technically, it must hold that $\frac{\partial U}{\partial Y_i}=\frac{\partial u}{\partial y_i}$ because the first order partial derivatives of a $1$st order homogeneous function are $0$th order homogeneous. But I do not see how to show that formally using mathematical arguments.