Skip to content

Commit b943853

Browse files
authored
Actinides (#31)
Add parameters for all actinides elements + Fr and Ra
1 parent f6d7464 commit b943853

9 files changed

Lines changed: 1944 additions & 821 deletions

File tree

src/tad_dftd3/data.py

Lines changed: 1609 additions & 718 deletions
Large diffs are not rendered by default.

src/tad_dftd3/disp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
>>> energy = d3.disp.dispersion(numbers, positions, param, c6)
5151
>>> torch.set_printoptions(precision=7)
5252
>>> print(torch.sum(energy[0] - energy[1] - energy[2])) # energy in Hartree
53-
tensor(-0.0003964)
53+
tensor(-0.0003964, dtype=torch.float64)
5454
"""
5555
import torch
5656

src/tad_dftd3/model.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@
3535
>>> c6 = d3.model.atomic_c6(numbers, weights, ref)
3636
>>> torch.set_printoptions(precision=7)
3737
>>> print(c6)
38-
tensor([[10.4130478, 5.4368815, 5.4368815],
39-
[ 5.4368811, 3.0930152, 3.0930152],
40-
[ 5.4368811, 3.0930152, 3.0930152]])
38+
tensor([[10.4130471, 5.4368822, 5.4368822],
39+
[ 5.4368822, 3.0930154, 3.0930154],
40+
[ 5.4368822, 3.0930154, 3.0930154]], dtype=torch.float64)
4141
"""
4242
import torch
4343

src/tad_dftd3/reference-c6.npy

1.15 MB
Binary file not shown.

src/tad_dftd3/reference.py

Lines changed: 104 additions & 95 deletions
Original file line numberDiff line numberDiff line change
@@ -31,101 +31,110 @@ def _load_cn(
3131
) -> Tensor:
3232
return torch.tensor(
3333
[
34-
[-1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # None
35-
[+0.9118, +0.0000, -1.0000, -1.0000, -1.0000], # H
36-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # He
37-
[+0.0000, +0.9865, -1.0000, -1.0000, -1.0000], # Li
38-
[+0.0000, +0.9808, +1.9697, -1.0000, -1.0000], # Be
39-
[+0.0000, +0.9706, +1.9441, +2.9128, +4.5856], # B
40-
[+0.0000, +0.9868, +1.9985, +2.9987, +3.9844], # C
41-
[+0.0000, +0.9944, +2.0143, +2.9903, -1.0000], # N
42-
[+0.0000, +0.9925, +1.9887, -1.0000, -1.0000], # O
43-
[+0.0000, +0.9982, -1.0000, -1.0000, -1.0000], # F
44-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ne
45-
[+0.0000, +0.9684, -1.0000, -1.0000, -1.0000], # Na
46-
[+0.0000, +0.9628, +1.9496, -1.0000, -1.0000], # Mg
47-
[+0.0000, +0.9648, +1.9311, +2.9146, -1.0000], # Al
48-
[+0.0000, +0.9507, +1.9435, +2.9407, +3.8677], # Si
49-
[+0.0000, +0.9947, +2.0102, +2.9859, -1.0000], # P
50-
[+0.0000, +0.9948, +1.9903, -1.0000, -1.0000], # S
51-
[+0.0000, +0.9972, -1.0000, -1.0000, -1.0000], # Cl
52-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ar
53-
[+0.0000, +0.9767, -1.0000, -1.0000, -1.0000], # K
54-
[+0.0000, +0.9831, +1.9349, -1.0000, -1.0000], # Ca
55-
[+0.0000, +1.8627, +2.8999, -1.0000, -1.0000], # Sc
56-
[+0.0000, +1.8299, +3.8675, -1.0000, -1.0000], # Ti
57-
[+0.0000, +1.9138, +2.9110, -1.0000, -1.0000], # V
58-
[+0.0000, +1.8269, 10.6191, -1.0000, -1.0000], # Cr
59-
[+0.0000, +1.6406, +9.8849, -1.0000, -1.0000], # Mn
60-
[+0.0000, +1.6483, +9.1376, -1.0000, -1.0000], # Fe
61-
[+0.0000, +1.7149, +2.9263, +7.7785, -1.0000], # Co
62-
[+0.0000, +1.7937, +6.5458, +6.2918, -1.0000], # Ni
63-
[+0.0000, +0.9576, -1.0000, -1.0000, -1.0000], # Cu
64-
[+0.0000, +1.9419, -1.0000, -1.0000, -1.0000], # Zn
65-
[+0.0000, +0.9601, +1.9315, +2.9233, -1.0000], # Ga
66-
[+0.0000, +0.9434, +1.9447, +2.9186, +3.8972], # Ge
67-
[+0.0000, +0.9889, +1.9793, +2.9709, -1.0000], # As
68-
[+0.0000, +0.9901, +1.9812, -1.0000, -1.0000], # Se
69-
[+0.0000, +0.9974, -1.0000, -1.0000, -1.0000], # Br
70-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Kr
71-
[+0.0000, +0.9738, -1.0000, -1.0000, -1.0000], # Rb
72-
[+0.0000, +0.9801, +1.9143, -1.0000, -1.0000], # Sr
73-
[+0.0000, +1.9153, +2.8903, -1.0000, -1.0000], # Y
74-
[+0.0000, +1.9355, +3.9106, -1.0000, -1.0000], # Zr
75-
[+0.0000, +1.9545, +2.9225, -1.0000, -1.0000], # Nb
76-
[+0.0000, +1.9420, 11.0556, -1.0000, -1.0000], # Mo
77-
[+0.0000, +1.6682, +9.5402, -1.0000, -1.0000], # Tc
78-
[+0.0000, +1.8584, +8.8895, -1.0000, -1.0000], # Ru
79-
[+0.0000, +1.9003, +2.9696, -1.0000, -1.0000], # Rh
80-
[+0.0000, +1.8630, +5.7095, -1.0000, -1.0000], # Pd
81-
[+0.0000, +0.9679, -1.0000, -1.0000, -1.0000], # Ag
82-
[+0.0000, +1.9539, -1.0000, -1.0000, -1.0000], # Cd
83-
[+0.0000, +0.9633, +1.9378, +2.9353, -1.0000], # In
84-
[+0.0000, +0.9514, +1.9505, +2.9259, +3.9123], # Sn
85-
[+0.0000, +0.9749, +1.9523, +2.9315, -1.0000], # Sb
86-
[+0.0000, +0.9811, +1.9639, -1.0000, -1.0000], # Te
87-
[+0.0000, +0.9968, -1.0000, -1.0000, -1.0000], # I
88-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Xe
89-
[+0.0000, +0.9909, -1.0000, -1.0000, -1.0000], # Cs
90-
[+0.0000, +0.9797, +1.8467, -1.0000, -1.0000], # Ba
91-
[+0.0000, +1.9373, +2.9175, -1.0000, -1.0000], # La
92-
[+2.7991, -1.0000, -1.0000, -1.0000, -1.0000], # Ce
93-
[+0.0000, +2.9425, -1.0000, -1.0000, -1.0000], # Pr
94-
[+0.0000, +2.9455, -1.0000, -1.0000, -1.0000], # Nd
95-
[+0.0000, +2.9413, -1.0000, -1.0000, -1.0000], # Pm
96-
[+0.0000, +2.9300, -1.0000, -1.0000, -1.0000], # Sm
97-
[+0.0000, +1.8286, -1.0000, -1.0000, -1.0000], # Eu
98-
[+0.0000, +2.8732, -1.0000, -1.0000, -1.0000], # Gd
99-
[+0.0000, +2.9086, -1.0000, -1.0000, -1.0000], # Tb
100-
[+0.0000, +2.8965, -1.0000, -1.0000, -1.0000], # Dy
101-
[+0.0000, +2.9242, -1.0000, -1.0000, -1.0000], # Ho
102-
[+0.0000, +2.9282, -1.0000, -1.0000, -1.0000], # Er
103-
[+0.0000, +2.9246, -1.0000, -1.0000, -1.0000], # Tm
104-
[+0.0000, +2.8482, -1.0000, -1.0000, -1.0000], # Yb
105-
[+0.0000, +2.9219, -1.0000, -1.0000, -1.0000], # Lu
106-
[+0.0000, +1.9254, +3.8840, -1.0000, -1.0000], # Hf
107-
[+0.0000, +1.9459, +2.8988, -1.0000, -1.0000], # Ta
108-
[+0.0000, +1.9292, 10.9153, -1.0000, -1.0000], # W
109-
[+0.0000, +1.8104, +9.8054, -1.0000, -1.0000], # Re
110-
[+0.0000, +1.8858, +9.1527, -1.0000, -1.0000], # Os
111-
[+0.0000, +1.8648, +2.9424, -1.0000, -1.0000], # Ir
112-
[+0.0000, +1.9188, +6.6669, -1.0000, -1.0000], # Pt
113-
[+0.0000, +0.9846, -1.0000, -1.0000, -1.0000], # Au
114-
[+0.0000, +1.9896, -1.0000, -1.0000, -1.0000], # Hg
115-
[+0.0000, +0.9267, +1.9302, +2.9420, -1.0000], # Tl
116-
[+0.0000, +0.9383, +1.9356, +2.9081, +3.9098], # Pb
117-
[+0.0000, +0.9820, +1.9655, +2.9500, -1.0000], # Bi
118-
[+0.0000, +0.9815, +1.9639, -1.0000, -1.0000], # Po
119-
[+0.0000, +0.9954, -1.0000, -1.0000, -1.0000], # At
120-
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Rn
121-
[+0.0000, +0.9705, -1.0000, -1.0000, -1.0000], # Fr
122-
[+0.0000, +0.9662, +1.8075, -1.0000, -1.0000], # Ra
123-
[+0.0000, +2.9070, -1.0000, -1.0000, -1.0000], # Ac
124-
[+0.0000, +2.8844, -1.0000, -1.0000, -1.0000], # Th
125-
[+0.0000, +2.8738, -1.0000, -1.0000, -1.0000], # Pa
126-
[+0.0000, +2.8878, -1.0000, -1.0000, -1.0000], # U
127-
[+0.0000, +2.9095, -1.0000, -1.0000, -1.0000], # Np
128-
[+0.0000, +1.9209, -1.0000, -1.0000, -1.0000], # Pu
34+
[-1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # None
35+
[+0.9118, +0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # H
36+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # He
37+
[+0.0000, +0.9865, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Li
38+
[+0.0000, +0.9808, +1.9697, -1.0000, -1.0000, -1.0000, -1.0000], # Be
39+
[+0.0000, +0.9706, +1.9441, +2.9128, +4.5856, -1.0000, -1.0000], # B
40+
[+0.0000, +0.9868, +1.9985, +2.9987, +3.9844, -1.0000, -1.0000], # C
41+
[+0.0000, +0.9944, +2.0143, +2.9903, -1.0000, -1.0000, -1.0000], # N
42+
[+0.0000, +0.9925, +1.9887, -1.0000, -1.0000, -1.0000, -1.0000], # O
43+
[+0.0000, +0.9982, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # F
44+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ne
45+
[+0.0000, +0.9684, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Na
46+
[+0.0000, +0.9628, +1.9496, -1.0000, -1.0000, -1.0000, -1.0000], # Mg
47+
[+0.0000, +0.9648, +1.9311, +2.9146, -1.0000, -1.0000, -1.0000], # Al
48+
[+0.0000, +0.9507, +1.9435, +2.9407, +3.8677, -1.0000, -1.0000], # Si
49+
[+0.0000, +0.9947, +2.0102, +2.9859, -1.0000, -1.0000, -1.0000], # P
50+
[+0.0000, +0.9948, +1.9903, -1.0000, -1.0000, -1.0000, -1.0000], # S
51+
[+0.0000, +0.9972, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Cl
52+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ar
53+
[+0.0000, +0.9767, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # K
54+
[+0.0000, +0.9831, +1.9349, -1.0000, -1.0000, -1.0000, -1.0000], # Ca
55+
[+0.0000, +1.8627, +2.8999, -1.0000, -1.0000, -1.0000, -1.0000], # Sc
56+
[+0.0000, +1.8299, +3.8675, -1.0000, -1.0000, -1.0000, -1.0000], # Ti
57+
[+0.0000, +1.9138, +2.9110, -1.0000, -1.0000, -1.0000, -1.0000], # V
58+
[+0.0000, +1.8269, 10.6191, -1.0000, -1.0000, -1.0000, -1.0000], # Cr
59+
[+0.0000, +1.6406, +9.8849, -1.0000, -1.0000, -1.0000, -1.0000], # Mn
60+
[+0.0000, +1.6483, +9.1376, -1.0000, -1.0000, -1.0000, -1.0000], # Fe
61+
[+0.0000, +1.7149, +2.9263, +7.7785, -1.0000, -1.0000, -1.0000], # Co
62+
[+0.0000, +1.7937, +6.5458, +6.2918, -1.0000, -1.0000, -1.0000], # Ni
63+
[+0.0000, +0.9576, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Cu
64+
[+0.0000, +1.9419, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Zn
65+
[+0.0000, +0.9601, +1.9315, +2.9233, -1.0000, -1.0000, -1.0000], # Ga
66+
[+0.0000, +0.9434, +1.9447, +2.9186, +3.8972, -1.0000, -1.0000], # Ge
67+
[+0.0000, +0.9889, +1.9793, +2.9709, -1.0000, -1.0000, -1.0000], # As
68+
[+0.0000, +0.9901, +1.9812, -1.0000, -1.0000, -1.0000, -1.0000], # Se
69+
[+0.0000, +0.9974, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Br
70+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Kr
71+
[+0.0000, +0.9738, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Rb
72+
[+0.0000, +0.9801, +1.9143, -1.0000, -1.0000, -1.0000, -1.0000], # Sr
73+
[+0.0000, +1.9153, +2.8903, -1.0000, -1.0000, -1.0000, -1.0000], # Y
74+
[+0.0000, +1.9355, +3.9106, -1.0000, -1.0000, -1.0000, -1.0000], # Zr
75+
[+0.0000, +1.9545, +2.9225, -1.0000, -1.0000, -1.0000, -1.0000], # Nb
76+
[+0.0000, +1.9420, 11.0556, -1.0000, -1.0000, -1.0000, -1.0000], # Mo
77+
[+0.0000, +1.6682, +9.5402, -1.0000, -1.0000, -1.0000, -1.0000], # Tc
78+
[+0.0000, +1.8584, +8.8895, -1.0000, -1.0000, -1.0000, -1.0000], # Ru
79+
[+0.0000, +1.9003, +2.9696, -1.0000, -1.0000, -1.0000, -1.0000], # Rh
80+
[+0.0000, +1.8630, +5.7095, -1.0000, -1.0000, -1.0000, -1.0000], # Pd
81+
[+0.0000, +0.9679, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ag
82+
[+0.0000, +1.9539, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Cd
83+
[+0.0000, +0.9633, +1.9378, +2.9353, -1.0000, -1.0000, -1.0000], # In
84+
[+0.0000, +0.9514, +1.9505, +2.9259, +3.9123, -1.0000, -1.0000], # Sn
85+
[+0.0000, +0.9749, +1.9523, +2.9315, -1.0000, -1.0000, -1.0000], # Sb
86+
[+0.0000, +0.9811, +1.9639, -1.0000, -1.0000, -1.0000, -1.0000], # Te
87+
[+0.0000, +0.9968, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # I
88+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Xe
89+
[+0.0000, +0.9909, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Cs
90+
[+0.0000, +0.9797, +1.8467, -1.0000, -1.0000, -1.0000, -1.0000], # Ba
91+
[+0.0000, +1.9373, +2.9175, -1.0000, -1.0000, -1.0000, -1.0000], # La
92+
[+2.7991, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ce
93+
[+0.0000, +2.9425, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Pr
94+
[+0.0000, +2.9455, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Nd
95+
[+0.0000, +2.9413, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Pm
96+
[+0.0000, +2.9300, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Sm
97+
[+0.0000, +1.8286, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Eu
98+
[+0.0000, +2.8732, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Gd
99+
[+0.0000, +2.9086, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Tb
100+
[+0.0000, +2.8965, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Dy
101+
[+0.0000, +2.9242, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Ho
102+
[+0.0000, +2.9282, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Er
103+
[+0.0000, +2.9246, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Tm
104+
[+0.0000, +2.8482, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Yb
105+
[+0.0000, +2.9219, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Lu
106+
[+0.0000, +1.9254, +3.8840, -1.0000, -1.0000, -1.0000, -1.0000], # Hf
107+
[+0.0000, +1.9459, +2.8988, -1.0000, -1.0000, -1.0000, -1.0000], # Ta
108+
[+0.0000, +1.9292, 10.9153, -1.0000, -1.0000, -1.0000, -1.0000], # W
109+
[+0.0000, +1.8104, +9.8054, -1.0000, -1.0000, -1.0000, -1.0000], # Re
110+
[+0.0000, +1.8858, +9.1527, -1.0000, -1.0000, -1.0000, -1.0000], # Os
111+
[+0.0000, +1.8648, +2.9424, -1.0000, -1.0000, -1.0000, -1.0000], # Ir
112+
[+0.0000, +1.9188, +6.6669, -1.0000, -1.0000, -1.0000, -1.0000], # Pt
113+
[+0.0000, +0.9846, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Au
114+
[+0.0000, +1.9896, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Hg
115+
[+0.0000, +0.9267, +1.9302, +2.9420, -1.0000, -1.0000, -1.0000], # Tl
116+
[+0.0000, +0.9383, +1.9356, +2.9081, +3.9098, -1.0000, -1.0000], # Pb
117+
[+0.0000, +0.9820, +1.9655, +2.9500, -1.0000, -1.0000, -1.0000], # Bi
118+
[+0.0000, +0.9815, +1.9639, -1.0000, -1.0000, -1.0000, -1.0000], # Po
119+
[+0.0000, +0.9954, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # At
120+
[+0.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Rn
121+
[+0.0000, +0.9705, -1.0000, -1.0000, -1.0000, -1.0000, -1.0000], # Fr
122+
[+0.0000, +0.9661, +1.9251, -1.0000, -1.0000, -1.0000, -1.0000], # Ra
123+
[+0.0000, +0.9802, +1.9445, +2.9070, +3.8174, +4.6723, +5.5599], # Ac
124+
[+0.0000, +0.9847, +1.9560, +2.9302, +3.8997, -1.0000, -1.0000], # Th
125+
[+0.0000, +0.9647, +1.9079, +2.9037, +3.8711, +4.9094, +4.5318], # Pa
126+
[+0.0000, +0.9766, +2.8888, +3.9129, +4.1181, +5.9187, -1.0000], # U
127+
[+0.0000, +0.9838, +1.9499, +2.9159, +3.9358, +4.9069, +5.9005], # Np
128+
[+0.0000, +0.9537, +1.9439, +2.9323, +3.9441, +4.9192, +5.8888], # Pu
129+
[+0.0000, +0.9163, +1.8563, +2.8823, +4.8005, +5.7794, -1.0000], # Am
130+
[+0.0000, +0.9762, +1.9288, +2.8929, +3.8167, +4.7478, +5.6866], # Cm
131+
[+0.0000, +0.9705, +1.9511, +2.9262, +3.9342, -1.0000, -1.0000], # Bk
132+
[+0.0000, +0.9581, +1.9123, +2.9327, +3.9105, +5.8285, -1.0000], # Cf
133+
[+0.0000, +0.9346, +1.8816, +2.9075, +3.8705, +4.8131, +5.7244], # Es
134+
[+0.0000, +0.9500, +1.9165, +2.9377, +3.8956, +4.8540, +5.8160], # Fm
135+
[+0.0000, +0.9710, +1.9564, +2.9515, +3.9353, -1.0000, -1.0000], # Md
136+
[+0.0000, +0.9722, +1.9605, +2.9452, +3.9296, +4.2582, +4.5511], # No
137+
[+0.0000, +0.9569, +1.9215, +2.8958, +3.7644, +4.6808, +5.5939], # Lr
129138
],
130139
device=device,
131140
dtype=dtype,

tests/molecules.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,4 +130,16 @@
130130
dtype=torch.float64,
131131
),
132132
},
133+
"AmF3": {
134+
"numbers": to_number("Am F F F".split()),
135+
"positions": torch.tensor(
136+
[
137+
[-1.13163973200000, -2.17446990100000, +1.10012477100000],
138+
[-4.66377948900000, -3.12947883400000, -0.36987606800000],
139+
[-0.19032564300000, +1.36339950600000, -0.36521789300000],
140+
[+1.46283310800000, -4.75734549200000, -0.36503081000000],
141+
],
142+
dtype=torch.float64,
143+
),
144+
},
133145
}

0 commit comments

Comments
 (0)