File: script.py

package info (click to toggle)
python-ase 3.26.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 15,484 kB
  • sloc: python: 148,112; xml: 2,728; makefile: 110; javascript: 47
file content (26 lines) | stat: -rw-r--r-- 625 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# fmt: off
from ase import Atoms
from ase.calculators.siesta import Siesta
from ase.calculators.siesta.parameters import PAOBasisBlock, Species
from ase.optimize import QuasiNewton

atoms = Atoms(
    '3H',
    [(0.0, 0.0, 0.0),
     (0.0, 0.0, 0.5),
     (0.0, 0.0, 1.0)],
    cell=[10, 10, 10])

basis_set = PAOBasisBlock(
    """1
0  2 S 0.2
0.0 0.0""")
atoms.set_tags([0, 1, 0])
siesta = Siesta(
    species=[
        Species(symbol='H', tag=None, basis_set='SZ'),
        Species(symbol='H', tag=1, basis_set=basis_set, ghost=True)])

atoms.calc = siesta
dyn = QuasiNewton(atoms, trajectory='h.traj')
dyn.run(fmax=0.02)