OESetTorsion

bool OESetTorsion(OEMolBase &mol, OEAtomBase *a, OEAtomBase *b, OEAtomBase *c,
                  OEAtomBase *d, double ang)
bool OESetTorsion(OEConfBase &conf, OEAtomBase *a, OEAtomBase *b,
                  OEAtomBase *c, OEAtomBase *d, double ang)

Sets torsion angle defined by atoms a, b, c and d to the angle in the argument radians. It is presumed that each of these atoms are members of the molecules passed to the function. All atoms which are attached to ‘c’ (excluding ‘b’) are rotated. If the bond defined by atoms ‘b’ and ‘c’ are in a ring, no change to the torsion will occur. However, an overall rotation of the molecule may be a side effect. The functions return true if completes successfully. The functions return false if the central bond is part of a ring, or if the atoms are on top of each other.

mol

The molecule that the atoms belong to.

conf

The conformer that the atoms belong to.

a

One of the end atoms in the torsion.

b

Atom that is connected to a in the torsion.

c

Atom that is connected to d in the torsion.

d

The other end atom in the torsion.

ang

The angle in radians.