PoreMS 0.3
  • API
  • Molecule
  • Pore
  • Workflow
  • Pore shape examples
  • Site
    • Page
        • Molecule.part_angle
          • Molecule.part_angle()
    • Molecule.part_angle
      • Molecule.part_angle()
    Source

    Molecule.part_angle¶

    Molecule.part_angle(bond_a, bond_b, atoms, angle, zero)¶

    Change the bond angle of two bond vectors. Variable atoms specifies which atoms or rather which part of the molecule needs to be rotated in order to change the specified bond angle. First however the system needs to be set to zero. Therefore, the atom id to define the new coordinate system must be given for the set of specified atoms. Normally this is the atom that touches the angle.

    The rotation axis is determined by creating the cross product of the two bond vectors. Thus, getting the normal vector of a surface that contains both bond vectors.

    Parameters:
    bond_alist

    First bond vector given as a list of two atom ids

    bond_blist

    Second bond vector given as a list of two atom ids

    atomsinteger, list

    List of atoms to be rotated (can also be one id)

    anglefloat

    Rotation angle

    zerointeger

    Atom id to define zero point of the new coordinate system

    Examples

    mol.part_angle([0, 1], [1, 2], [1, 2, 3], 90, 1)
    

    Back to top

    © Copyright 2021, Hamzeh Kraus.
    Created using Sphinx 7.4.6.