jax_md_mod.custom_quantity.init_rmsd#
- init_rmsd(reference_positions, displacement_fn, reference_box, idx=None, weights=None)[source]#
Initializes the root mean squared distance from a reference structure.
The RMSD is a common measure in the analysis of macrostructures [1]. The weighted RMSD between a current positions $p$ and reference positions $q$ is defined as
\[\mathrm{RMSD} = \sqrt{\frac{\sum_{i=1}^n w_i || (Rp + t )- q||^2}{\sum_{i=1}^n w_i}},\]where $R$ and $t$ define a rigid body motion that minimizes the RMSD [2].
- Parameters:
reference_positions – Reference positions including all atoms.
displacement_fn – Function to compute displacement between particles.
reference_box – Reference box of the reference structure.
idx – Indices selecting only the structure of interest, e.g. for a protein in a solvent.
weights – Weight the rmsd, e.g., with masses of the particles.
References