Consider the multivariable function $P(x,t) = te^{-x^2}$. I would like to introduce a new variable $z = x-\mu t$, for some $\mu \in \mathbb{R}$. Let $Q(z,t) = P(x,t)$ in the new coordinate system. I am interested in calculating the quantity $\partial Q/\partial t$, but I am having some conflicting results.
In terms of the new coordinates, $Q(z,t) = te^{-(z+\mu t)^2}$, so computing the derivative explicitly gives
$$ \frac{\partial Q}{\partial t} = e^{-(z+\mu t)^2}\bigg[1-2\mu t(z+\mu t)\bigg] $$
However, in my specific application, I would like to able to compute $\partial Q/ \partial t$ using the chain rule. Since $Q = Q(z,t)$, wouldn't the derivative just be
$$ \frac{\partial Q}{\partial t} = \frac{\partial Q}{\partial z}\frac{\partial z}{\partial t} = -\mu\frac{\partial Q}{\partial z} = 2\mu t(z+\mu t)e^{-(z+\mu t)^2} $$
Clearly, the two answers are different, but I can't figure out why the second method with the chain rule doesn't work.