# N-body units

Length (R) ${\displaystyle {\frac {1}{R}}={\frac {2}{M^{2}}}\sum _{i,j\neq i}^{N}{\frac {m_{i}m_{j}}{\left|{\vec {r_{j}}}-{\vec {r_{i}}}\right|}}}$
Mass (M) ${\displaystyle M=\sum _{i=1}^{N}m_{i}}$
N-body units are a completely self-contained system of units used for N-body simulations of self gravitating systems in astrophysics. In this system, the base physical units are chosen so that the total mass, M, the gravitational constant, G, and the virial radius, R, are normalised. The underlying assumption is that the system of N objects (stars) satisfies the virial theorem. The consequence of standard N-body units is that the velocity dispersion of the system is ${\displaystyle \scriptstyle v=1/{\sqrt {2}}}$ and that the dynamical -crossing- time scales as ${\displaystyle \scriptstyle t=2{\sqrt {2}}}$. The first mention of standard N-body units was by Michel Hénon (1971).[1] They were taken up by Haldan Cohn (1979)[2] and later widely advertised and generalized by Douglas Heggie and Robert Mathieu (1986).[3]