Function symmetry::symm_rotate

Function Documentation

void symmetry::symm_rotate(int natoms, const std::vector<int> &nat, const std::vector<std::vector<double>> &coord, const std::array<double, 3> &axis, double sina, double cosa, double delta, int &nc, std::vector<int> &ntrans, double &delta3)

Performs a proper rotation around an axis.

This function applies a rotation transformation to the molecule around the specified axis by the given angle and checks which atoms are mapped to equivalent positions.

Parameters:
  • natoms – Number of atoms in the molecule

  • nat – Vector of atomic numbers for each atom

  • coord – 3D coordinates of atoms (vector of vectors, size 3 x natoms)

  • axis – Unit vector defining the rotation axis

  • sina – Sine of the rotation angle

  • cosa – Cosine of the rotation angle

  • delta – Tolerance for symmetry detection (distance threshold)

  • nc – Output: Number of atoms that are properly mapped by this rotation

  • ntrans – Output: Permutation array showing atom mappings (size natoms)

  • delta3 – Output: Maximum deviation from perfect symmetry