chemcoord.Cartesian.align

Cartesian.align(other, mass_weight=False)

Align two Cartesians.

Minimize the RMSD (root mean squared deviation) between self and other. Returns a tuple of copies of self and other where both are centered around their centroid and other is rotated unto self. The rotation minimises the distances between the atom pairs of same label. Uses the Kabsch algorithm implemented within get_kabsch_rotation()

Parameters:
  • other (Cartesian) –
  • mass_weight (bool) – Do a mass weighting to find the best rotation
Returns:

Return type:

tuple