File: libvdwxc-example.py

package info (click to toggle)
gpaw 21.1.0-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 14,492 kB
  • sloc: python: 121,997; ansic: 14,138; sh: 1,125; csh: 139; makefile: 43
file content (9 lines) | stat: -rw-r--r-- 217 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
from ase.build import molecule
from gpaw import GPAW
from gpaw.xc.libvdwxc import vdw_df_cx

atoms = molecule('H2O')
atoms.center(vacuum=3.0)
calc = GPAW(xc=vdw_df_cx())
atoms.calc = calc
atoms.get_potential_energy()