Atomic theory of gas dynamics