# In an $n$ particle system, why is the Hamiltonian summed over $n$?

Suppose I am working in a system consisting of $$n$$ particles. Thus the phase space will be $$\mathbb{R}^{6n}$$, and both the momentum and position space will be $$\mathbb{R}^{3n}$$ each.

Then, for some potential function $$V$$, the Hamiltonian is given by $$H(q, p) = \sum_{i=1}^n \frac{p_i^2}{2m_i} + V(q),\tag{1.2.1}$$ cf. e.g. Glimm & Jaffe p.4.

My question is why exactly are we summing $$n$$ terms? I thought each $$p \in P = \mathbb{R}^{3n}$$, so it seems we are off by a factor of 3.

The only thing I can think of is that each momentum component is summed separately, but nothing in the notation suggests this and I always believed the Hamiltonian to be a scalar.

EDIT: After reading a few answers, it seems that $$p_i^2$$ is to be interpreted as a scalar (i.e. the magnitude of the momentum vector).

As a follow up, suppose I have an observable $$f = f(q(t), p(t))$$. Some notes I am following claims that $$\frac{\partial f}{\partial t} = \sum_1^n \Big(\frac{p_i}{m_i} \cdot \nabla_{q_i} + F_i(q) \cdot \nabla_{p_i}\Big)f.$$

Clearly this was obtained via the chain rule. However, if each generalized coordinate or momenta is to be indeed viewed as a scalar, how come there is a gradient vector in this expression? When do we view these generalized momenta/coordinates as vectors and when do we view them as scalars? I assume each gradient vector here is in $$\mathbb{R}^3$$?

• Which notes? Which references? Which page? Jun 17 at 6:22
• @Qmechanic Perhaps it might be more useful if I outline how I obtained it. A few texts (as well as Wikipedia: en.wikipedia.org/wiki/Hamiltonian_(quantum_mechanics)) show that the summation should be over $n$. From there I just used the Hamiltonian $H = T + V$ where $T = 1/2mv^2$, but I have rewritten it in terms of momentum. Jun 17 at 6:28

The hamiltonian is a scalar quantity as it represents total energy of a system. Each particle momenta in your equation $$(1)$$ is the magnitude of said particle's momenta $$p_i = \sqrt{\sum\limits_i^d \mathbf{p_i}^2}$$ where $$d$$ is the number of dimensions.

Also, in your equation $$(1)$$ the summation should also cover that particles' positions in the potential term (Assuming this is an external potential and not an interacting potential), otherwise each interacting pair should also be considered, but that besides the point.

$$H(q,p) = \sum\limits_{i=1}^{n} \frac{p_i^2}{2m} + V(q_i)$$

In parctice you're summing $$n$$ terms, each is a sum of $$d$$ (dimensions) other terms. So you could think of it as $$d\cdot n$$ sums

• Thank you, I am still a little confused on when we use the magnitude of the momenta and when do we use the vector. I have updated my original post with an example to illustrate this confusion. Jun 17 at 6:47
• Good question. Yes, the fact that the hamiltonian is calculated using scalar quantities but those quantities encompass vector quantities, and when you wish to differentiate w.r.t a certain coordinated (using Hamilton's equations or what not), the coordinate dependence is relevant. It still doesn't mean that is should be taken into consideration when calculating the total energy of the system.
– Ben
Jun 17 at 6:53
• I suppose then whether quantities are scalars or vectors relies heavily on the context, this seems very ambiguous and prone to interpretation errors. Is there some general rule or whatnot one needs to follow when telling the difference? Jun 17 at 6:58
• Just being careful, when differentiating scalar quantities as they can contain underlying vector ones. And remembering, as @Qmechanic noted in his answer, that $p_i^2=\mathbf{p}_i\cdot \mathbf{p}_i$. When considering the magnitude of the momentum in this form, it is clear why we only sum over the number of particles, and it is also clear that there are vector components to this scalar quantity
– Ben
Jun 17 at 7:03
• As another follow up, this would imply that, in terms of dimensions of domains/codomains, $f: \mathbb{R}^{3n} \times \mathbb{R}^{3n} \rightarrow \mathbb{R}^3$. However, I have read that the observed quantity need not be a vector. For example, an observable can also be a scalar, such as kinetic energy, but this is not compatible with the codomain of $f$. Is there some other restriction on what is considered an observable? Jun 17 at 7:17
1. The index $$i=1,\ldots n$$ is a particle index; not a coordinate index. The $$i$$th particle carries a 3-momentum $$p_i\in\mathbb{R}^3$$.

2. In the Hamiltonian $$p_i^2=p_i\cdot p_i$$ is a dot/scalar product.

3. Note that many authors instead use boldface $${\bf p}_i$$ for vectors.

• I see, so in the summation each $p_i$ is just the magnitude of the momentum vector? Jun 17 at 6:38
• As a follow up I have included a second part to my original question. Since the $i$th particle contains a 3-momentum $p_i \in \mathbb{R}^3$, does that mean when we take a time derivative each gradient vector is in $\mathbb{R}^3$? Jun 17 at 6:48