Can I use Root-Mean-Square Speed to measure the average speed of particles in solids and liquids? Can I use the equation $v_{rms}= \sqrt{\frac{3RT}{M}}$ of Root Mean Square Speed to measure speed of particles in liquids and solids as well? I am doing a Javascript animation about molecular motion of solids, liquids and gases and I can't find anywhere how to measure speeds of particles of solids and liquids and it's getting really frustating. 
I will really appreciate any help and if I can't use the equation for Root Mean Square Speed of gases, I will be thankful for suggestions how to measure speed of liquids and solids in other ways with other equations and formulas. 
 A: Due to equipartition theorem, average kinetic energy of particles in a system of classical particles is
$$\langle K\rangle=\frac32k_BT=\frac{m\langle v\rangle^2}2.$$
This is true even if there are some interactions: for derivation see this answer. Thus we have
$$\langle v\rangle^2=\frac1m 3k_BT=\frac{N_A}M 3k_BT=\frac{3RT}M,$$
and after taking square root we get your formula.
Now, as I mentioned, this only applies to classical systems of particles. In actual liquids and solids there're electrons in each atom, and these electrons are in a highly quantum regime. But if you restrict your attention to motion of atoms themselves, rather than taking into account motion of electrons, then you can safely use the classical formula. Atomic nuclei are quite heavy, so at typical energies their motion in liquids and even in solids can be considered classical (i.e. their energy spectrum is very dense).
So to summarize, the answer is yes: for motion of atoms in liquids and solids at not too low temperatures you can safely use your formula.
