-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Description
Empirical potentials does not seem to work with isolated systems. Here is a reproducer. The first example work the second errors out with an InexactError Int(NaN).
using AtomsBase
using AtomsCalculators
using EmpiricalPotentials
using Unitful
using UnitfulAtomic
zH = 1
emins = Dict((zH, zH) => -1.17u"hartree", )
rmins = Dict((zH, zH) => 0.743u"Å", )
calc = LennardJones(emins, rmins, 5.0u"Å")
let
cell_vectors = ([10.0, 0.0, 0.0]u"Å", [0.0, 10.0, 0.0]u"Å", [0.0, 0.0, 10.0]u"Å")
periodic = periodic_system([:H => [0, 0, 1.]u"bohr",
:H => [0, 0, 3.]u"bohr"],
cell_vectors)
AtomsCalculators.potential_energy(periodic, calc)
end
println("--- ok ---")
let
isolated = isolated_system([:H => [0, 0, 0.0]u"bohr",
:H => [0, 0, 1.9]u"bohr"])
AtomsCalculators.potential_energy(isolated, calc) # issue
end
println("--- this will not be reached ---")Metadata
Metadata
Assignees
Labels
No labels