-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME
45 lines (30 loc) · 2.07 KB
/
README
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
##############
## libBCS ##
##############
A library to find the ground state of the non-particle conserving hermitian BCS Hamiltonian in the site basis. The latex formula would be:
\begin{equation}
\hat{H} = \sum\limits_{ij\sigma} t^{\sigma}_{ij} \hat{a}_{i \sigma}^{\dagger} \hat{a}_{j \sigma} + \sum\limits_{i} U_i \hat{n}_{i \uparrow} \hat{n}_{i \downarrow} - \mu_{\uparrow} \sum\limits_{i} \hat{n}_{i \uparrow} - \mu_{\downarrow} \sum\limits_{i} \hat{n}_{i \downarrow} + \sum\limits_{ij} \Delta_{ij} \left( \hat{a}_{i \uparrow}^{\dagger} \hat{a}_{j \downarrow}^{\dagger} + \hat{a}_{j \downarrow} \hat{a}_{i \uparrow} \right)
\end{equation}
where the latin letters denote site-indices and the greek letters spin projections. All Hamiltonian parameters should be real. Hermiticity requires the two t-matrices to be symmetric. There are no requirements on the $\Delta$-matrix. This Hamiltonian preserves spin projection, but not particle number. The ground state is calculated by exact diagonalization, more specifically the Lanczos method as implemented in ARPACK.
1. Building the library
Edit the makefile. Normally only LIBS, CC, CXX, CFLAGS and LDFLAGS have to be set.
Arpack is needed by the libBCS. For Ubuntu, you can find it in the package repository.
Run the makefile:
make -f makefile
2. Generating documentation
There is a file .doc-config in ./ for doxygen.
The manual can be generated in two ways:
make -f makefile doc
or
doxygen .doc-config
A folder ./latex-docs/ is created. Go to that folder and build the manual:
cd latex-docs
make -f Makefile
A file refman.pdf should have been compiled. It contains information on the use of libBCS.
3. Using libBCS
Two python files should allow for easy use of libBCS.
PyBCS.py contains the Python class PyBCS, which handles the interface with the C++ library.
example.py contains two examples showing the usage of the PyBCS class:
The Hubbard model and the single-particle BCS Hamiltonian.
Have fun!
Sebastian <sebastianwouters@ugent.be>