Time derivative of a function in Phase Space

Consider a function $\mathcal{H}(q_i,p_i;t)$ such that it obeys the equation: $$\frac{d\mathcal{H}}{dt}=\frac{\partial\mathcal{H}}{\partial t}$$ What does this equation imply (read: mean), physically?

Mathematically it leads to: $$\vec{v}(t)\cdot\vec{\nabla}\mathcal{H}=0$$ which is a result that could be arrived at using Hamilton's equations as well. This seems to imply that there is a connection between the two, since Hamilton's equations follow from the definition of the Hamiltonian (please verify).

-
@Timaeus : Here – Prish Chakraborty Jan 24 at 18:42
Do you understand that $$\frac{\mathrm{d}H}{\mathrm{d}t}=\frac{\partial H}{\partial t}+\frac{\partial H}{\partial q_i}\dot q_i+\frac{\partial H}{\partial p_i}\dot p_i$$ – 0celo7 Jan 24 at 18:58
Weird that that didn't show up in my mailbox. – Timaeus Jan 24 at 18:59
@0celo7 : $\vec{v}(t)=(\dot{q_i},\dot{p_i})$ – Prish Chakraborty Jan 24 at 19:02
@Timaeus: you need to participate in the conversation here for it to ping you, otherwise it does nothing. – Kyle Kanos Jan 24 at 19:39

For $\mathcal{H}(q,p,t)$ to have in any meaningful sense a partial derivative $\partial_t$ that is different from the total time derivative, you have to consider it applied to a curve $(q(t),p(t))$ in phase space. The equation $$\frac{\mathrm{d}\mathcal{H}}{\mathrm{d}t} = \partial_t \mathcal{H}\tag{1}$$ then says that $\mathcal{H}$ is "constant" along the curve. Expanding the total derivative, we arrive at $$\frac{\mathrm{d}\mathcal{H}}{\mathrm{d}t} = (\partial_q\mathcal{H})\dot{q}+(\partial_p\mathcal{H})\dot{p} + \partial_t\mathcal{H}$$ leading indeed to the condition that $(\nabla \mathcal{H})\cdot\begin{pmatrix}\dot{q}\\\dot{p}\end{pmatrix} = 0$ for this to hold. Not every such curve is a solution to the equation of motions, but all solutions to the equations of motion fulfill this condition, since they are the integral curves of the Hamiltonian vector field $X_\mathcal{H} = \begin{pmatrix}\partial_p\mathcal{H}\\-\partial_q\mathcal{H}\end{pmatrix}$, i.e. $\begin{pmatrix}\dot{q}\\\dot{p}\end{pmatrix} = X_H$ along them .

To see that not every such curve is a solution, consider $q(t) = t, p(t) = 0$ for the free Hamiltonian $\mathcal{H} = p^2$. Along it, $(1)$ holds because $\partial_q\mathcal{H} = 0$ and $\dot{p}= 0$, but it is not a solution to the equations of motion because $\dot{q} = 1\neq 0 = 2p = \partial_p\mathcal{H}$.

-
Why is $\mathcal{H}$ constant along the curve? Its derivative is not necessarily $0$? – pfnuesel Jan 24 at 19:08
@pfnuesel: That's why I put "constant" in scare quotes. The standard case is $\partial_t\mathcal{H} = 0$, a typical Hamiltonian of a mechanical system will not be time-dependent, so this is the proper intuition for what this equation says, even if $\mathcal{H}$ is not actually constant along the curve in the general case. – ACuriousMind Jan 24 at 19:11
For a free particle isn't it true that $p=\dot{q}$? Doesn't that contradict the definition of $q$? Also what do you mean by "applied to a curve"? – Prish Chakraborty Jan 24 at 19:19
@PrishChakraborty: $p=\dot{q}$ holds true on a curve that is a solution to the equations of motion. It is not true for general curve in phase space (such as the one I gave). Applying $\mathcal{H}$ to a curve merely means to pick a curve $(q(t),p(t))$ and then write $\mathcal{H}(q(t),p(t),t)$. On its own, $\mathcal{H}$ is just a function of the phase space and time, and the coordinates of the phase space itself don't depend on time. – ACuriousMind Jan 24 at 19:23
@ACuriousMind : As I understand it, the equations of motion imply the time derivative condition, but not necessarily the other way around. Is that correct? – Prish Chakraborty Jan 24 at 19:34

It implies that total energy is conserved along the paths specified by the trajectories, except for whatever explicit changes are written in the Hamiltonian. It is not sufficient to get the rest of the physics because there may be many energy-conserving paths. For example, for the free-particle Hamiltonian, the energy is the kinetic energy and the predicted paths are constant, uniform motions in a straight line. A constant, uniform motion in a circle will also preserve kinetic energy: but it is not a valid path.

As others have mentioned, the notion of a "partial derivative" of a function $\mathbb R^n\to\mathbb R$ just asks "how does this function vary with respect to its $n^\text{th}$ argument, holding the rest constant?" -- and there are no "total derivatives" to speak of. To have "total derivatives" we need to tie this together with a function $\mathbb R \to \mathbb R^n,$ saying how all of these arguments covary with the parameter which we're taking the "total" derivative with respect to.

The natural choice in Hamiltonian mechanics is to implicitly substitute any of a class of functions $t \mapsto (q_i(t), p_i(t), t)$ which describes the actual physical trajectories of the system; this equation then says "the only allowed physical trajectories must all conserve energy (except for the ways in which the Hamiltonian explicitly doesn't)." So essentially there is a subset $\mathcal T\subset (\mathbb R \to \mathbb R^n)$ of physical trajectories, and this is identifying one of the characteristics of the functions in $\mathcal T$ which make them acceptable trajectories for the system, as distinct from all of these general functions $\mathbb R \to \mathbb R^n.$

-

$$\frac{d\mathcal{H}}{dt}= \dot{q_i}\frac{\partial\mathcal{H}}{\partial q_i}+\dot{p_i}\frac{\partial\mathcal{H}}{\partial p_i}+\frac{\partial\mathcal{H}}{\partial t}$$

And physically this is related to how the Hamiltonian experienced, $\mathcal{H}(t)=\mathcal{H}(q_i(t),p_i(t),t),$ changes as you move around in phase space, compared to how the Hamiltonian field $$(q_i,p_i)\mapsto \mathcal{H}(q_i,p_i,t)$$ changes in time.

And as you pointed out $\frac{d\mathcal{H}}{dt}= \frac{\partial\mathcal{H}}{\partial t}$ means $\dot{q_i}\frac{\partial\mathcal{H}}{\partial q_i}+\dot{p_i}\frac{\partial\mathcal{H}}{\partial p_i}=0.$

Which means the flow in phase space is orthogonal to the gradient of the Hamiltonian. That the Hamiltonian experienced isn't changed by the flow in phase space, but solely by the change of the Hamiltonian field in time.

This is not the same as Hamilton's equations. Because it does not, for instance, imply Hamilton's equations. It is a consequence of Hamilton's equations.

I did not here say that this implies Hamilton's equations and did say that it is a consequence of those equations. What I did ask here is whether there is a connection between the principles that are used to derive Hamilton's equations and the equality of the total and partial derivatives of the Hamiltonian.

Let's step way way back. You can have fields like $$(q_i,p_i)\mapsto \mathcal{H}_1(q_i,p_i)$$ and $$(q_i,p_i)\mapsto \mathcal{H}_2(q_i,p_i)$$ and $$(q_i,p_i)\mapsto \mathcal{H}_3(q_i,p_i).$$

Or even continuum many such fields parameterized by time. In other words for each time, $t,$ you get a field $$(q_i,p_i)\mapsto \mathcal{H}(q_i,p_i,t).$$

So a single function of $2n+1$ variables can be a time varying scalar field. Great, fields have partials. There are partials for each of the $2n+1$ variables:

$$\frac{\partial\mathcal{H}}{\partial q_1} ,\dots,\frac{\partial\mathcal{H}}{\partial q_n}, \frac{\partial\mathcal{H}}{\partial p_i},\dots, \frac{\partial\mathcal{H}}{\partial p_n},\frac{\partial\mathcal{H}}{\partial t}.$$

And fields only have partials, not total derivatives. How do you get a total derivative? You need a function of a single variable. You don't have one. You need one to be able to take a total derivative. If, in addition to this time changing field $(q_i,p_i,t)\mapsto\mathcal{H}(q_i,p_i,t)$ you had a curve $$t\mapsto (q_i(t),p_i(t))$$ then you can make a new function of a single variable $$\mathcal{H}(t)=\mathcal{H}(q_i(t),p_i(t),t).$$

This function could have a derivative (and it does if the field is smooth and the curve is differentiable). And since the field also has a partial derivative in time you can ask whether the total derivative (of the Hamiltonian experienced, which depends on the Hamiltonian and the curve) equals the partial time derivative when the latter (which is a field) is evaluated at the corresponding point on the curve.

So the property of the total derivative equaling the partial derivative is not a property of the field. And the field is the Hamiltonian, so it is not a property of the Hamiltonian.

Hamiltonian's equations give you some curves. And the curves they give you can be used to make single variable functions. Those single variable functions can satisfy the equation you provided if you evaluate the field on the right hand side at the appropriate place.

But the equation you started with began by assuming a curve of some kind. And some of the curves that satisfy the equation you started with do not satisfy Hamiltonian's equations.

There is no more connection than that. Physically your equation has the curve be instantaneously orthogonal to the instantaneous gradient of the instantaneous Hamiltonian (the $2n$ dimensional gradient of the field at that instant). Some curves do that without satisfying Hamilton's equations. The curves that satisfy Hamilton's equations do satisfy that.

But the equation presupposed a curve, and it is not a property of the Hamiltonian. And the definition of the Hamiltonian is a field of $2n+1$ variables. And Hamilton's equations relates curves to those fields in a particular way.

Finally, you did ask us to verify that

Hamilton's equations follow from the definition of the Hamiltonian

And they don't, the Hamiltonian is just a field, a function from $2n+1$ variables and doesn't even require any curves at all. So Hamilton's equations do not follow from the definition of a Hamiltonian.

The Hamiltonian by definition follows from the Lagrangian, which does presuppose a curve (that minimizes the action). Isn't the existence of a curve always assumed a priori with the Hamiltonian, in this way?

The Hamiltonian is not defined as the Legendre Transform of the Lagrangian. And the Lagrangian does not presuppose a curve, it also is a field, but it isn't a field on phase space is a field on a combination of position and velocity space. You can start with a $2n+1$ or a $2n$ dimensional manifold and have a symplectic form of the $2n$ part and get a Hamiltonian field without ever having a curve or a Lagrangian. And you can get a Lagrangian by starting with a product of a configuration space and its velocity space. And the velocity space is the space in which the true velocity could lie, so the combination of the configuration and the velocity space is basically a scalar field on the tangent manifold of the configuration manifold with maybe some time too.

Actions are functionals. They are like fields, but instead of taking a point in phase space and giving a number or taking a point on something like the tangent manifold of the configuration space and giving a number the action instead takes a curve and give a number. Sure, terminology is abused and you use the same word action for the number as the function.

Just like I tried to distinguish the Hamilton experienced, $\mathcal{H}(t),$ from the $2n+1$ variable field $$(q_i,p_i,t)\mapsto\mathcal{H}(q_i,p_i,t)$$ or the many instantaneous fields $$(q_i,p_i)\mapsto\mathcal{H}(q_i,p_i,t_1),$$

$$(q_i,p_i)\mapsto\mathcal{H}(q_i,p_i,t_2),$$

$$(q_i,p_i)\mapsto\mathcal{H}(q_i,p_i,t_3).$$

But keep in mind, that just becasue your first introduction to a Hamiltonian or a Hamiltonian field, is via Lagrangian, doesn't mean that is the definition.

And what's tricky is that someone might give you the Lagrangian of a particular system and then define the Hamiltonian for that same system in terms of that specific Lagrangian. But they are just trying to point towards a specific Hamiltonian.

Hamiltonian Mechanics is a very specific subject that stands on its own. And is strongly related to symplectic forms on even dimensional symplectic manifolds (phase space).

Lagrangian mechanics is a very specific subject that also stands on its own. And it is strongly related to tangent manifolds.

Action is a functional and is strongly related to path integrals.

And all the subjects have connections. But a Hamiltonian is a field and so is a Lagrangian. They are defined on different spaces.

And you can use them to do pure field theories which don't have curves.

-
I did not here say that this implies Hamilton's equations and did say that it is a consequence of those equations. What I did ask here is whether there is a connection between the principles that are used to derive Hamilton's equations and the equality of the total and partial derivatives of the Hamiltonian. – Prish Chakraborty Jan 24 at 19:22
The Hamiltonian by definition follows from the Lagrangian, which does presuppose a curve (that minimizes the action). Isn't the existence of a curve always assumed a priori with the Hamiltonian, in this way? – Prish Chakraborty Jan 24 at 19:56
@PrishChakraborty Edited to respond to your comment. – Timaeus Jan 25 at 6:51
Thanks for the help. Please excuse me if I misinterpret certain bits as some parts are new to me. I feel that you're trying to break away the use of a Hamiltonian in the Newtonian regime and focusing on the essentials that allow one to generalise it to field theories as well. I was, however, talking about it exclusively as an application to the dynamics of rigid bodies which is why I intuitively thought that one ought to a priori assume the existence of a curve. – Prish Chakraborty Jan 25 at 12:12
@PrishChakraborty obe of your problems is that you aren't using language properly. You write "Consider a function $\mathcal{H}(q_i,p_i;t)$ such that it obeys the equation" however your function is a field (even for particle theories) and the equation involves a single variable function on the left that requires a curve. Failing to presupposing a curve and balancing the field is an error right out the gate. So the answer requires bringing up the curve. The curve and the field are such that the tangent of the curve is orthogonal to the spatial gradient of the instantaneous field. – Timaeus Jan 25 at 14:13

protected by Qmechanic♦Jan 24 at 19:58

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).