forked from pyscf/pyscf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
__init__.py
108 lines (95 loc) · 3.04 KB
/
__init__.py
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
'''
**************************************
A Python package for quantum chemistry
**************************************
Features
--------
1. Common quantum chemistry methods
* Non-relativistic and relativistic Hartree-Fock
* Non-relativistic DFT
* CASSCF and FCI
* MP2
* CCSD
* General non-relativistic integral transformation
* Non-relativistic DFT
* Hartree-Fock Gradient
* Hartree-Fock NMR
2. Interface to integral package `Libcint <https://github.com/sunqm/libcint>`_
3. Interface to DMRG `CheMPS2 <https://github.com/SebWouters/CheMPS2>`_
4. Interface to DMRG `Block <https://github.com/sanshar/Block>`_
5. Interface to FCIQMC `NECI <https://github.com/ghb24/NECI_STABLE>`_
How to use
----------
There are two ways to access the documentation: the docstrings come with
the code, and an online program reference, available from
http://www.sunqm.net/pyscf/index.html
We recommend the enhanced Python interpreter `IPython <http://ipython.org>`_
and the web-based Python IDE `Ipython notebook <http://ipython.org/notebook.html>`_
to try out the package::
>>> from pyscf import gto, scf
>>> mol = gto.Mole()
>>> mol.build(atom='H 0 0 0; H 0 0 1.2', basis='cc-pvdz')
>>> m = scf.RHF(mol)
>>> m.scf()
converged SCF energy = -1.06111199785749
-1.06111199786
Submodules
----------
In pyscf, most submodules requires explict import::
>>> from pyscf import gto, scf
:mod:`gto`
Molecular structure and basis sets.
scf
Non-relativistic and relativistic SCF.
mcscf
CASCI, 1-step and 2-step CASSCF
ao2mo
General 2-electron AO to MO integral transformation
dft
Non-relativistic RKS
df
Density fitting
fci
Full CI
cc
Coupled Cluster
dmrgscf
2-step DMRG-CASSCF
fciqmcscf
2-step FCIQMC-CASSCF
grad
Gradients
lo
Localization and orbital orthogonalization
lib
Basic functions and C extension
nmr
NMR
mp
Moller-Plesset perturbation theory
symm
Symmetry
tools
Convert pyscf data to the data format for other packages
Pure function and Class
-----------------------
The class in each method are designed to hold only the final results and the
control parameters such as maximum number of iterations, convergence
threshold, etc. The intermediate status are not saved in the class. If the
class.kernel() function is finished without any errors, the solution will be
saved in the class (see documentation for each class).
Most useful functions are implemented at module level, and can be accessed in
both class or module, e.g. ``scf.hf.get_jk(mol, dm)`` and
``SCF(mol).get_jk(mol, dm)`` have the same functionality. As a result, most
functions and class are **pure**, i.e. no status are saved, and the argument
are not changed inplace. Exception to this rule is suffixed with underscore
in the function name.
'''
import os
from pyscf import gto
from pyscf import lib
from pyscf import scf
from pyscf import ao2mo
# modules in ./future are in test
__path__.append(os.path.join(os.path.dirname(__file__), 'future'))
__path__.append(os.path.join(os.path.dirname(__file__), 'tools'))