jax_md_mod.custom_quantity.dihedral_displacement#
- dihedral_displacement(positions, displacement_fn, dihedral_idxs, degrees=True)[source]#
Computes the dihedral angle for all quadruple of atoms given in idxs.
- Parameters:
positions – Positions of atoms in box
displacement_fn – Displacement function
dihedral_idxs – (n, 4) array defining IDs of quadruple particles
degrees – If False, returns angles in rads. If True, returns angles in degrees.
- Returns:
An array (n,) of the dihedral angles.