Skip to content

Commit c711593

Browse files
committed
up
1 parent 6bbe517 commit c711593

File tree

2 files changed

+11
-17
lines changed

2 files changed

+11
-17
lines changed

docs/src/examples/aluminium_dftk.md

+7-12
Original file line numberDiff line numberDiff line change
@@ -15,27 +15,22 @@ system = rattle!(bulk(:Al; cubic=true), 0.2u"Å")
1515
Next we create a calculator employing the
1616
[density-functional toolkit](https://dftk.org/)
1717
to compute energies and forces at using the LDA density functional.
18+
As pseudopotentials we use the [PseudoDojo](http://pseudo-dojo.org) as available
19+
in the [PseudoPotentialData](https://github.com/JuliaMolSim/PseudoPotentialData.jl/)
20+
package.
1821
```@example dftk-aluminium
1922
using DFTK
23+
using PseudoPotentialData
2024
21-
model_kwargs = (; functionals=[:lda_x, :lda_c_pw], temperature=1e-3)
25+
pseudopotentials = PseudoFamily("dojo.nc.sr.lda.v0_4_1.oncvpsp3.standard.upf")
26+
model_kwargs = (; functionals=LDA(), temperature=1e-3, pseudopotentials)
2227
basis_kwargs = (; kgrid=(3, 3, 3), Ecut=10.0)
2328
scf_kwargs = (; mixing=KerkerMixing())
2429
calc = DFTKCalculator(; model_kwargs, basis_kwargs, scf_kwargs)
25-
nothing
26-
```
27-
28-
We attach pseudopotentials to the aluminium system,
29-
i.e. we tell DFTK, that each aluminium atom should be modelled using
30-
a pseudopotential rather than the full Coulomb potential.
31-
32-
```@example dftk-aluminium
33-
system = attach_psp(system; Al="hgh/lda/al-q3")
34-
nothing
3530
```
3631

3732
!!! info "Crude computational parameters"
38-
Note, that these numerical parameters are chosen rather crudely in order
33+
Note, that the numerical parameters above are chosen rather crudely in order
3934
to give a fast runtime on CI systems. For production calculations one would
4035
require larger computational parameters.
4136

docs/src/examples/other_solvers.md

+4-5
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ to compute energies and forces at using the LDA density functional.
1111

1212
```@example other-solvers
1313
using DFTK
14+
using PseudoPotentialData
1415
15-
model_kwargs = (; functionals=[:lda_x, :lda_c_pw])
16+
pseudopotentials = PseudoFamily("dojo.nc.sr.lda.v0_4_1.oncvpsp3.standard.upf")
17+
model_kwargs = (; functionals=LDA(), pseudopotentials)
1618
basis_kwargs = (; kgrid=(1, 1, 1), Ecut=20.0)
17-
scf_kwargs = (; tol=1e-6)
18-
calc = DFTKCalculator(; model_kwargs, basis_kwargs, scf_kwargs)
19-
nothing
19+
calc = DFTKCalculator(; model_kwargs, basis_kwargs)
2020
```
2121

2222
and we build the hydrogen molecular system,
@@ -31,7 +31,6 @@ bounding_box = [[10.0, 0.0, 0.0], [0.0, 10.0, 0.0], [0.0, 0.0, 10.0]]u"Å"
3131
system = periodic_system([:H => [0, 0, 1.]u"bohr",
3232
:H => [0, 0, 3.]u"bohr"],
3333
bounding_box)
34-
system = attach_psp(system; H="hgh/lda/h-q1")
3534
nothing
3635
```
3736

0 commit comments

Comments
 (0)