jaxdem.forces.lennardjones#
Finite-range Lennard-Jones interactions with shifted pair energy.
Classes
|
Lennard-Jones (LJ) 12-6 interaction with a per-pair cutoff and energy shift. |
- class jaxdem.forces.lennardjones.LennardJones(laws: tuple[~jaxdem.forces.ForceModel, ...]=(), cutoff_ratio: Array = <factory>)#
Bases:
ForceModelLennard-Jones (LJ) 12-6 interaction with a per-pair cutoff and energy shift.
The model reads the material-pair parameter
epsilon_eff[mi, mj].The model derives the length scale \(\sigma_{ij}\) from the particle radii (as in spring.py):
\[\sigma_{ij} = R_i + R_j\]Potential (for \(r < r_c = c \sigma_{ij}\), with
cutoff_ratio\(c=2.5\) by default):\[U(r) = 4 \epsilon \left[\left(\frac{\sigma}{r}\right)^{12} - \left(\frac{\sigma}{r}\right)^6 \right] - U(r_c)\]else:
\[U(r) = 0\]Force (for \(r < r_c\)):
\[\mathbf{F} = 24 \epsilon \left(2 \left(\frac{\sigma}{r}\right)^{12} - \left(\frac{\sigma}{r}\right)^6\right) \frac{1}{r^2}\, \mathbf{r}_{ij}\]- cutoff_ratio: Array#
Pair cutoff in units of
rad[i] + rad[j]; also sets collider search reach.
- static Create(cutoff_ratio: float = 2.5) LennardJones[source]#
Create an LJ law with a positive finite cutoff measured in pair sigma.
- search_radii(state: State, system: System) jax.Array[source]#
Conservative search extent for this law’s finite interaction range.
- static force(i: int, j: int, pos: jax.Array, state: State, system: System, history: jax.Array, *, advance_history: bool = True, quasistatic: bool = False) tuple[jax.Array, jax.Array, jax.Array][source]#
- static energy(i: int, j: int, pos: jax.Array, state: State, system: System, history: jax.Array) jax.Array[source]#
- property required_material_properties: tuple[str, ...][source]#
Names of the material properties this force model needs.
Each name (for example ‘young_eff’ or ‘restitution’) must be present in
System.mat_table. Used for validation.