Lets' say I have a solid system made with N atoms in a box with a volume of V as shown below. In this case, the number density of my system is simply $\frac{N}{Volume\; of \; occupied\;3D\; space}$.

Solid Sphere

but what if I have a system with $N$ atoms in the same box, but $N_{1}$ atoms are in the solid phase and $N_{2}$ atoms are in the gas phase $\left( N_{1} + N_{2} = N \right)$.

enter image description here

How should I calculate the number density in this case? Do I consider the whole box volume $V$?

  • 1
    $\begingroup$ This seems to be a question of what definition you choose for number density. $\endgroup$ Commented Oct 10, 2022 at 14:29
  • 2
    $\begingroup$ You come up with a criteria to distinguish solid from vapor, which is a pretty standard thing in MD. Matter Modeling SE might be a better place to ask since they have experience over there. $\endgroup$
    – Jon Custer
    Commented Oct 10, 2022 at 15:08

1 Answer 1


Yes, you take the whole volume. That is the definition of density $\rho = N/V$. I guess what you are thinking of is in fact local density $\rho(r) = \delta N(r) / \delta V$ where $\delta N(r)$ is the number of particles in the immediate vicinity $(x\pm 0.5dx, y\pm 0.5dy, z\pm 0.5dz)$ of the point $\vec{r} = (x,y,z)$, $\delta V = dx\, dy\, dz$.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.