Fixed a sign error in dihedral_derivs