# When is the Hamiltonian a function of momenta alone?

In my statistical mechanics course, I'm deriving the entropy for an ideal gas and I've come across a statement in the book by Pathria where it states that in the case of an ideal gas, the Hamiltonian is strictly a function of the momenta ($p_{i}$).

Are there general conditions that hold for this to be true? Or is this just a result of the particular system being considered?

I don't know what is the general conditions for only a momentum dependence. But an example of only momentum dependence is the case of non-interacting particles. Consider the case where the only energy a particle has is its kinetic energy, and it does not interact with anything, not gravity, not a container, not other particles, not anything. In that case you just get $\frac{1}{2} \frac{p^2}{m}$ per particle.