mstk.topology.Dihedral

class mstk.topology.Dihedral(atom1, atom2, atom3, atom4)

A dihedral between four atoms.

Parameters:
atom1
Type:

Atom

atom2
Type:

Atom

atom3
Type:

Atom

atom4
Type:

Atom

override_atom_types

When matching dihedral terms from FF, the type attributes of the four atoms will be overridden with these specified types. Each element can be a string or None. If None, the type attribute of the corresponding atom will be used, and not get overridden.

Type:

list of str

Methods

__init__(atom1, atom2, atom3, atom4)

equals(other)

Check if two dihedrals represent the same connectivity.

evaluate([cell])

Evaluate the value of this dihedral in unit of radian

Attributes

angles

The two angles in this dihedral

atoms

The atoms forming this dihedral

bonds

The three bonds in this dihedral

name

Name of this dihedral

equals(other)

Check if two dihedrals represent the same connectivity. Dihedrals with reversed sequence are considered as equal. E.g., i-j-k-l and l-k-j-i are the same.

Parameters:

other (Dihedral) –

Returns:

equal

Return type:

bool

property name: str

Name of this dihedral

Returns:

name

Return type:

str

property atoms

The atoms forming this dihedral

Returns:

atoms

Return type:

tuple of Atom

property bonds

The three bonds in this dihedral

Returns:

bonds

Return type:

tuple of Bond

property angles

The two angles in this dihedral

Returns:

angles

Return type:

tuple of Angle

evaluate(cell=None)

Evaluate the value of this dihedral in unit of radian

Parameters:

cell (UnitCell, Optional) –

Returns:

value

Return type:

float