Calculating second partial derivate of a multivariable function. I have a doubt resolving Apostol Vol.2, sec 22, prob 4:

The equations $u =f(x, y), x = X(s, t), y = Y(s, t)$ define $u$ as a function of $s$ and $t$, say $u = F(s, t).$ Find formulas for the partial derivatives $\frac{\partial^2F}{\partial s\partial t}$ and $\frac{\partial^2F}{\partial t^2}$

I was able to get the formula for $\frac{\partial^2F}{\partial t^2}$, but for $\frac{\partial^2F}{\partial s\partial t}$ I seem to have troubles, here's my solution:

$\frac{\partial^2F}{\partial s\partial t}=\frac{\partial f}{\partial x}\frac{\partial^2X}{\partial s\partial t}+\frac{\partial^2f}{\partial x^2}\frac{\partial X}{\partial t}\frac{\partial X}{\partial s}+\frac{\partial^2f}{\partial y\partial x}\frac{\partial Y}{\partial s}\frac{\partial X}{\partial t}+\frac{\partial f}{\partial y}\frac{\partial^2Y}{\partial s\partial t}+\frac{\partial^2f}{\partial x\partial y}\frac{\partial X}{\partial s}\frac{\partial Y}{\partial t}+\frac{\partial^2f}{\partial y^2}\frac{\partial Y}{\partial s}\frac{\partial Y}{\partial t}$

But I think this is wrong given a solution I found on the internet, is my solution right or where could I have gone wrong?
Thanks.
 A: The derivation of $\frac{\partial^2 F}{\partial  s\partial t}$ is  sound.

We obtain
  \begin{align*}
\color{blue}{\frac{\partial^2 F}{\partial  s\partial t}}
&=\frac{\partial}{\partial  s}\left(\frac{\partial   F}{\partial t}\right)\\
&=\frac{\partial}{\partial  s}\left(\frac{\partial  f}{\partial    x}\,\frac{\partial X}{\partial   t}
+\frac{\partial   f}{\partial  y}\,\frac{\partial  Y}{\partial t}\right)\\
&=\left(\frac{\partial}{\partial s}\left(\frac{\partial f}{\partial x}\right)\right)\,\frac{\partial X}{\partial t}
+\left(\frac{\partial  f}{\partial   x}\right)\,\frac{\partial ^2 X}{\partial s\partial t}\\
&\qquad+\left(\frac{\partial}{\partial s}\left(\frac{\partial f}{\partial y}\right)\right)\,\frac{\partial Y}{\partial t}
+\left(\frac{\partial  f}{\partial   y}\right)\,\frac{\partial ^2 Y}{\partial s\partial t}\\
&=\left(\frac{\partial^2 f}{\partial x^2}\,\frac{\partial X}{\partial s}
+\frac{\partial^2 f}{\partial y\partial x}\,\frac{\partial Y}{\partial s}\right)\,\frac{\partial x}{\partial t}
+\left(\frac{\partial f}{\partial x}\right)\,\frac{\partial^2 X}{\partial s\partial t}\\
&\qquad+\left(\frac{\partial^2 f}{\partial x\partial y}\,\frac{\partial X}{\partial s}
+\frac{\partial^2 f}{\partial y^2}\,\frac{\partial Y}{\partial s}\right)\,\frac{\partial Y}{\partial t}
+\left(\frac{\partial f}{\partial y}\right)\,\frac{\partial^2 Y}{\partial s\partial t}\\
&\,\,\color{blue}{=\frac{\partial^2 f}{\partial x^2}\,\frac{\partial X}{\partial s}\,\frac{\partial X}{\partial t}
+\frac{\partial ^2f}{\partial y\partial x}\,\frac{\partial Y}{\partial s}\,\frac{\partial X}{\partial t}+\frac{\partial^2 f}{\partial x\partial y}\,\frac{\partial X}{\partial s}\,\frac{\partial Y}{\partial t}
+\frac{\partial^2 f}{\partial y^2}\,\frac{\partial Y}{\partial s}\,\frac{\partial Y}{\partial t}}\\
&\qquad \,\,\color{blue}{+\frac{\partial f}{\partial x}\,\frac{\partial^2 X}{\partial s\partial t}
+\frac{\partial f}{\partial y}\,\frac{\partial^2 Y}{\partial s\partial t}}\tag{1}
\end{align*}
  in accordance with OPs derivation.

It is also convenient to make a plausibility check by calculating a specific example in two ways. We consider
\begin{align*}
u=f(x,y)=x^2+2y&\qquad  x=X(s,t)=4s+3t\\
&\qquad y=Y(s,t)=2st
\end{align*}
We have according  to (1)
\begin{align*}
&\left(\frac{\partial^2 }{\partial X^2}(x^2+2y)\right)\left(\frac{\partial }{\partial s}(4s+3t)\right)\left(\frac{\partial }{\partial t}(4s+3t)\right)\\
&\qquad+\left(\frac{\partial ^2}{\partial Y\partial X}(x^2+2y)\right)\left(\frac{\partial }{\partial s}(2st)\right)\left(\frac{\partial }{\partial t}(4s+3t)\right)\\
&\qquad+\left(\frac{\partial^2 }{\partial X\partial Y}(x^2+2y)\right)\left(\frac{\partial }{\partial s}(4s+3t)\right)\left(\frac{\partial }{\partial t}(2st)\right)\\
&\qquad+\left(\frac{\partial^2 }{\partial Y^2}(x^2+2y)\right)\left(\frac{\partial }{\partial s}(2st)\right)\left(\frac{\partial }{\partial t}(2st)\right)\\
&\qquad+\left(\frac{\partial }{\partial X}(x^2+2y)\right)\left(\frac{\partial^2 }{\partial s\partial t}(4s+3t)\right)\\
&\qquad+\left(\frac{\partial }{\partial Y}(x^2+2y)\right)\left(\frac{\partial^2 }{\partial s\partial t}(2st)\right)\\
&=(2)(4)(3)+(0)(2t)(3)+(0)(4)(2s)+(0)(2t)(2s)+(2x)(0)+(2)(2)\\
&=24+4\\
&\,\,\color{blue}{=28}\tag{2}
\end{align*}
On the other hand we obtain
\begin{align*}
u=F(s,t)&=(4s+3t)^2+2(2st)\\
&=16s^2+28st+9t^2\\
\\
\frac{\partial^2  F}{\partial s\partial t}&=\frac{\partial ^2 }{\partial   s\partial  t}\left(16s^2+28st+9t^2\right)\\
&=\frac{\partial  }{\partial s}\left(\frac{\partial  }{\partial t}\left(16s^2+28st+9t^2\right)\right)\\
&=\frac{\partial  }{\partial s}\left(28s+18t\right)\\
&\,\,\color{blue}{=28}
\end{align*}
in accordance with (2).
