![](../icons/dot_clear.gif) |
Examples for the use of diagonalize:
- Download and install diagonalize.
- Download the Hermitean 1377x1377 sample matrix
sample-matrix.gz.
Note:
This is on purpose a rather ill-conditioned problem, with extremal
eigenvalues 18J and 26.202624952J.
- To get all eigenvalues, no eigenvectors, try
./diagonalize -z -all -iJ:=1 sample-matrix eigenvals
The option `-z should be omitted if you have already
unpacked the sample-matrix.
The option -all requests
all eigenvalues (no eigenvectors). `-iJ:=1' specifies that
J=1 should be substituted in the input matrix. `eigenvals'
is the name of the file in which the result for the 1377 eigenvalues
are stored.
Note: You may find that in order to obtain stable results you
have to use a version which binds to
LaPack.
- If you want `just' the 100 lowest eigenvalues (and -vectors), you can
proceed as follows:
./diagonalize -z -le=800 -n150 -b -t -iJ:=1 sample-matrix eigenvals
./diagonalize -z -a1e-16 -n100+50 -f -s23.4 -iJ:=1 sample-matrix eigenvals
The first command performs a Lanczos' diagonalization in a Krylov
subspace of dimension 800 (option -le=800), without
reorthogonalization (option -b) and writes the resulting
estimates for the lowest 150 eigenvectors in a file `vi_vecs.dmp'
(option -t).
These 150 vectors are not fully converged. Therefore we need the second
command, which also eliminates so-called `ghosts'.
This command reads the vectors from the file `vi_vecs.dmp'
(option -f) and produces 100 converged eigenvectors
(option -n=100+50 - 50 auxiliary vectors included).
The other options perform a spectral shift by 23.4 for stabilization
purposes (option -s23.4) and request an accuracy for the
square of 10-16, i.e. at least 8 converged digits
(option -a1e-16).
Of course, one really wishes to apply this strategy only to (much) bigger
problems, i.e. dimensions (much) beyond 10 000.
Note: You have stored an intermediate estimate for the vectors
in the file `vi_vecs.dmp' (binary format). You may wish to
remove this file once you have finished your computation.
|
|