molsysmt.structure.get_principal_axes#

molsysmt.structure.get_principal_axes(molecular_system, selection='all', structure_indices='all', weights=None, principal_axes_type='inertia', syntax='MolSysMT', engine='MolSysMT')[source]#

Computing principal axes for a selection of atoms.

Parameters:
  • molecular_system (molecular system) – Input system.

  • selection (str, list, tuple or numpy.ndarray, default 'all') – Atoms used for axis computation.

  • structure_indices ('all' or array-like, default 'all') – Structures/frames to evaluate.

  • weights (array-like, optional) – Weights per atom.

  • principal_axes_type ({'inertia', 'geometric'}, default 'inertia') – Kind of principal axes to compute.

  • syntax (str, default 'MolSysMT') – Selection syntax when using strings.

  • engine ({'MolSysMT'}, default 'MolSysMT') – Backend.

Returns:

(axes, moments) where axes has shape (n_structures, 3, 3) and moments are variances or inertia moments.

Return type:

tuple

Raises: