  Determining whether two particle systems are similar is a common problem in
particle simulations. When the comparison should be invariant under
permutations, orthogonal transformations, and translations of the systems,
special techniques are needed. We present an algorithm that can test particle
systems of finite size for similarity and, if they are similar, can find the
optimal alignment between them. Our approach is based on an invariant version
of the root mean square deviation (RMSD) measure and is capable of finding the
globally optimal solution in $O(n^3)$ operations where $n$ is the number of
three-dimensional particles.
