Consider a function $f(x, t)$ where $x = x(t)$.
(i) In this case, can you interchange the partial derivatives of $f$ with $t$ and $x$. That is, can you write
$$ \dfrac{\partial^2 f}{\partial x \partial t} = \dfrac{\partial^2 f}{\partial t \partial x} $$ I know that if $x$ and $t$ are independent variables, the result hold due to Clairauts theorem. Is it also true in above case?
(ii) Similarly, can you interchange a partial derivative with respect to x and total derivative with respect to t as $$ \dfrac{d}{dt} \left( \dfrac{\partial f}{\partial x} \right) = \dfrac{\partial }{\partial x} \left( \dfrac{d f}{dt} \right) $$
This question is motivated from mechanics and is used in the derivation of Lagrange's equation from d'Alembert's principle. There $f$ plays the role of position (vector) of particle and $x$ is the generalized coordinate and $t$ is the time.
(iii) Any tip on how I can derive these rules, when a different situation arises.