get_lj_scaling_factors¶
- mdhelper.openmm.unit.get_lj_scaling_factors(bases: dict[str, Quantity], other: dict[str, list] = {}) dict[str, Quantity] [source]¶
Computes scaling factors for Lennard-Jones reduced units.
By default, the following scaling factors are calculated:
"molar_energy"
: \(N_\mathrm{A}\epsilon\)"time"
: \(\sqrt{m\sigma^2/\epsilon}\)"velocity"
: \(\sigma/\tau\)"force"
: \(\epsilon/\sigma\)"temperature"
: \(\epsilon/k_\mathrm{B}T\)"pressure"
: \(\epsilon/\sigma^3\)"dynamic_viscosity"
: \(\epsilon\tau/\sigma^3\)"charge"
: \(\sqrt{4\pi\varepsilon_0\sigma\epsilon}\)"dipole"
: \(\sqrt{4\pi\varepsilon_0\sigma^3\epsilon}\)"electric_field"
: \(\sqrt{\epsilon/(4\pi\varepsilon_0\sigma^3)}\)"mass_density"
: \(m/\sigma^3\)
- Parameters:
- basesdict
Fundamental quantities: molar mass (\(m\)), length (\(\sigma\)), and energy (\(\epsilon\)).
Format:
{"mass": <openmm.unit.Quantity>, "length": <openmm.unit.Quantity>, "energy": <openmm.unit.Quantity>}
.Reference units: \(\mathrm{g/mol}\), \(\mathrm{nm}\), and \(\mathrm{kJ/mol}\).
- otherdict, optional
Other scaling factors to compute. The key should be the name of the scaling factor, and the value should contain tuple objects with the names of bases or default scaling factors and their powers.
Example:
{"diffusivity": (("length", 2), ("time", -1))}
.
- Returns:
- scalesdict
Scaling factors.