xnn.ffnn.models.amoeba_ewald.switching#

xnn.ffnn.models.amoeba_ewald.switching(R, taper, cutoff)[source]#

The C2 switch S(R): one below taper, zero beyond cutoff, 1 - 10 x^3 + 15 x^4 - 6 x^5 with x = (R - taper) / (cutoff - taper) in between (unit value and zero first and second derivatives at the taper, zero value and derivatives at the cutoff).

Parameters:
  • R (Tensor) – Distances (M,).

  • taper (float) – The switching window in Angstrom (taper < cutoff).

  • cutoff (float) – The switching window in Angstrom (taper < cutoff).

Returns:

S(R) (M,).

Return type:

Tensor