enerzyme.models.layers.zbl.ZBLRepulsionEnergyLayer#

class enerzyme.models.layers.zbl.ZBLRepulsionEnergyLayer(Bohr_in_R: float = 0.5291772105638411, Hartree_in_E: float = 1, cutoff_sr: float | None = None, cutoff_fn: Literal['polynomial', 'bump', 'smooth'] = None)[source]#

Bases: BaseFFLayer

Short-range repulsive potential with learnable parameters inspired by the Ziegler-Biersack-Littmark (ZBL) potential described in Ziegler, J.F., Biersack, J.P., and Littmark, U., “The stopping and range of ions in solids”.

Arguments:
a0 (float):

Bohr radius in chosen length units (default value corresponds to lengths in Angstrom).

ke (float):

Coulomb constant in chosen unit system (default value corresponds to lengths in Angstrom and energy in electronvolt).

__init__(Bohr_in_R: float = 0.5291772105638411, Hartree_in_E: float = 1, cutoff_sr: float | None = None, cutoff_fn: Literal['polynomial', 'bump', 'smooth'] = None) None[source]#

Initializes the ZBLRepulsionEnergy class.

get_E_zbl_a(Za: Tensor, Dij_sr: Tensor, idx_i_sr: Tensor, idx_j_sr: Tensor, cutoff_values_sr: Tensor | None = None) Tensor[source]#

Evaluate the short-range repulsive potential. P: Number of atom pairs.

Arguments:
N (int):

Number of atoms.

Zf (FloatTensor [N]):

Nuclear charges of atoms (as floating point values).

rij (FloatTensor [P]):

Pairwise interatomic distances.

cutoff_values (FloatTensor [P]):

Values of a cutoff function for the distances rij.

idx_i (LongTensor [P]):

Index of atom i for all atomic pairs ij. Each pair must be specified as both ij and ji.

idx_j (LongTensor [P]):

Same as idx_i, but for atom j.

Returns:
e (FloatTensor [N]):

Atomic contributions to the total repulsive energy.

reset_parameters() None[source]#

Initialize parameters to the default ZBL potential.