mindspore.ops.LJForce
- class mindspore.ops.LJForce(atom_numbers, cutoff_square)[source]
Calculate the Van der Waals interaction force described by Lennard-Jones potential energy for each atom.
Because there is a large amount of inputs and each of them are related, there is no way to construct Examples using random methods. For details, refer the webpage SPONGE in MindSpore.
\[dr = (x_a-x_b, y_a-y_b, z_a-z_b)\]\[F = (-12*A/|dr|^{14} + 6*B/|dr|^{8}) * dr\]- Parameters
atom_numbers (int32) – the number of atoms, n.
cutoff_square (float32) – the square value of cutoff.
- Inputs:
uint_crd (Tensor) - The unsigned int coordinates value of each atom. The data type is uint32 and the shape is \((n, 3)\)
- LJtype (Tensor) - The Lennard-Jones type of each atom.
The data type is int32 and the shape is \((n,)\)
- charge (Tensor) - The charge carried by each atom.
The data type is float32 and the shape is \((n,)\)
scaler (Tensor) - The scale factor between real space coordinates and its unsigned int value. The data type is float32 and the shape is \((3,)\)
nl_numbers - (Tensor) - The each atom. The data type is int32 and the shape is \((n,)\)
nl_serial - (Tensor) - The neighbor list of each atom, the max number is 800. The data type is int32 and the shape is \((n, 800)\).
d_LJ_A (Tensor) - The Lennard-Jones A coefficient of each kind of atom pair. q is the number of atom pair. The data type is float32 and the shape is \((q,)\).
d_LJ_B (Tensor) - The Lennard-Jones B coefficient of each kind of atom pair. q is the number of atom pair. The data type is float32 and the shape is \((q,)\).
- outputs:
frc (Tensor) - The force felt by each atom. The data type is float32 and the shape is \((n, 3)\).
- Supported Platforms:
GPU