3
0
mirror of https://github.com/triqs/dft_tools synced 2024-11-07 06:33:48 +01:00
Commit Graph

407 Commits

Author SHA1 Message Date
Oleg E. Peil
3478db8a90 Modified main routine to make it importable
It is now possible to import a function
'generate_and_output_as_text()' from another Python script
to process VASP data.
2015-12-16 16:02:12 +01:00
Priyanka Seth
8652660115 [tests] Use new testing API 2015-12-12 14:30:45 +01:00
Priyanka Seth
90dafa478a Adapt to complex g(tau)
* Fix sumk to work with pos and neg imfreqs mesh
* Checked that GF.data is only used and modified for GfReFreq quantities
2015-12-12 14:30:06 +01:00
Oleg E. Peil
fe88b37515 Fixed a bug in determining dimensions in converter
Since 'n_orbitals' can be a 2D array in case of spin-polarized
calculations, one should use 'numpy.max' instead of 'max' to
extract the maximum number of bands.
2015-12-11 10:57:48 +01:00
Oleg E. Peil
41b3b63744 Modified input of eigenvalues and Fermi weights
In the new version of VASP LOCPROJ contains the eigenvalues and
Fermi weights. Also, during a charge self-consistency calculation
the file EIGENVAL is not written at intermediate iterations. It is,
thus, preferential to use LOCPROJ to get the named data.
At the moment, EIGENVAL will still be used if it is complete but
in the future this dependence should be removed completely.
2015-12-11 10:54:51 +01:00
Oleg E. Peil
3e63c0f0f5 Improved output of the density matrix 2015-12-09 11:55:29 +01:00
Oleg E. Peil
b02d13ebd8 Fixed the output of band indices to vasp.pgX
The band indices should be converted to Fortran convention,
i.e. starting from 1, in the output files because the are
used in the density matrix file which is read by a Fortran code.
2015-12-04 19:55:37 +01:00
Oleg E. Peil
85a83db1cb Added writing of 'band_window' to 'dft_misc_input'
In VASP implementation of charge self-consistency we need
band indices to construct the density matrix correction.
2015-12-04 15:29:19 +01:00
Oleg E. Peil
34bc2b6225 Modified LOCPROJ parser to conform to new format
The format of LOCPROJ has been modified again (in VASP 5.4.2
build from Dec 02, 2015).
Now, there is an additional line before each projector block
providing the spin, k-, and band indices, as well as
eigenvalues and Fermi weights.
2015-12-04 12:08:33 +01:00
Oleg E. Peil
1bfacd3883 Fixed the input of f-state projectors from LOCPROJ 2015-12-03 14:19:08 +01:00
Priyanka Seth
cbcb4c929f Switch to a new CMake macro triqs_prepare_local_pytriqs() 2015-12-02 17:00:08 +01:00
Oleg E. Peil
3e19c3d7bb Added storing of Fermi weights to 'dft_misc_input' 2015-12-02 12:23:23 +01:00
Oleg E. Peil
e35c6fd5c0 Fixed some files in examples
Scripts 'run_plovasp.sh' have been replaced by a template in which
the path must be set by the user.
Also, .gitignore has been added to example 'lunio3'.
2015-12-01 13:24:58 +01:00
Oleg E. Peil
22da0dae4a Added example on SrVO3 2015-12-01 13:19:24 +01:00
Oleg E. Peil
921bba0c1a Added a spin factor to density matrix in 'elstruct.py' 2015-12-01 11:18:44 +01:00
Oleg E. Peil
3620784798 Replaced R- and C-TRANSFORM with TRANSFORM option
Also, some tests were modified accordingly.
2015-11-30 20:24:34 +01:00
Oleg E. Peil
f0fae2b10a Fixed tests to pass with new LOCPROJ 2015-11-30 20:18:17 +01:00
Oleg E. Peil
3ccb047329 Fixed example 'simple' and corresponding tests
The calculation of the example was redone to generate LOCPROJ
in a new format (valid starting from VASP 5.4.2).
2015-11-30 19:52:38 +01:00
pdelange
b3e62640da [PATCH] fixed a missing mpi.reduce_all in spaghetti function from sumk_dft_tools 2015-11-30 17:19:36 +01:00
Priyanka Seth
cff294e1b2 Added shell info to filename for spaghetti. 2015-11-30 17:19:04 +01:00
Oleg E. Peil
1fd2a1af6a Added a parser for the new LOCPROJ (VASP >= 5.4.2) 2015-11-27 15:38:51 +01:00
Oleg E. Peil
fccb5cb2cf Added C-module for reading LOCPROJ (not implemente) 2015-11-27 15:23:09 +01:00
Oleg E. Peil
a93549e3ab Merge branch 'vasp' of ssh://github.com/TRIQS/dft_tools into vasp 2015-11-27 10:53:24 +01:00
Oleg E. Peil
46b3dd0667 Renamed module 'c/vasp' to 'c/plovasp' 2015-11-27 10:52:07 +01:00
Oleg E. Peil
0d65f38a61 Moved PLOVasp files to converters/plovasp 2015-11-27 10:48:15 +01:00
aichhorn
d9da33b6fe changed version to 1.4 2015-11-25 11:53:44 +01:00
Oleg E. Peil
7db721c8d1 Optimized slightly orthogonalization routine
At one step of the orthogonaliztion procedure two matrix multiplications
have been replaced with one matrix multiplication and a element-wise
multiplication of a vector and a matrix.
2015-11-21 14:23:30 +01:00
Oleg E. Peil
b2b25a9fd0 Fixed tests that because of the new default NORMION value 2015-11-20 18:59:46 +01:00
Oleg E. Peil
183c115870 Added docstrings to modules 2015-11-20 18:54:51 +01:00
Oleg E. Peil
0d53712761 Changed the default behavior of NORMION option
Now, NORMION is True by default, in accordance with the documentation.
2015-11-20 18:10:14 +01:00
Oleg E. Peil
9258054057 Added an example on LuNiO3
The example allows one to get an idea of how to define projectors
in case of a complex system with several atoms per unit cell.
2015-11-20 18:08:14 +01:00
Oleg E. Peil
770e9f5afc Added transformation of projectors
Now the matrices read from the input files are actually applied
to projectors.
Also, improved the debug output in 'plotools.py'.
2015-11-20 16:58:36 +01:00
Oleg E. Peil
ccc07537ce Updated documentation
Added a brief description of the purpose of PLOVasp to the User's
Guide.
Fixed autodocumenation by correcting module imports.
2015-11-20 12:24:32 +01:00
Oleg E. Peil
bdb94c2402 Modified documentation following the recent changes
Some options in the input file have been renamed. The description
of the input file in the documentation has been modified accordingly.
2015-11-19 17:45:31 +01:00
Oleg E. Peil
63de4f68a8 Added input of Fermi weights, cleaned-up the code 2015-11-19 16:32:50 +01:00
Oleg E. Peil
f544825684 Added output of Fermi weights to output files
Fermi weights are output next to eigenvalues. They will be needed
for the calculation of the KS density matrix in the charge
self-consistency implementation.
2015-11-19 16:06:25 +01:00
Oleg E. Peil
b85b62d693 Removed a redundant dependency of ProjectorGroup on 'ferw' 2015-11-19 16:01:05 +01:00
Oleg E. Peil
5585e81f7d Added two tests for 'get_block_matrix_map()'
Two tests have been added for testing the basic functionality with
NORMION being either False or True.
2015-11-19 15:56:30 +01:00
Oleg E. Peil
81825fcdf2 Fixed some errors introduced in the previous commit 2015-11-19 14:56:34 +01:00
Oleg E. Peil
72d030c5c5 Restructured 'orthogonalization()'
The part responsible for generating a mapping between the shell/ions
and block projector matrices has now been relocated to a separate
method 'get_block_matrix_map()'. This simplifies the source code
and makes testing easier.
2015-11-19 14:48:45 +01:00
Oleg E. Peil
c426946803 Added implementation for NORMION = True
The mapping for NORMION = True has been implemented.
Also, the orthogonalization loop has been fixed. First of all,
orthogonalization should be done separately for each block map 'bl_map'.
Second, one has to take into account that the orbital dimensions of the
block matrix can vary from block to block. To make that the overlap
matrix is non-singular one, thus, has to pass to
'orthogonalize_projector_matrix()' only a view of a submatrix of 'pmat'
corresponding to the current block.

Two tests to check the simplest cases have been added.
2015-11-19 12:11:55 +01:00
Oleg E. Peil
b3e1dd915a Refactored mapping onto block matrix in 'orthogonalize()'
The implementation of the mapping of a set of projectors (belonging
to different shells and ions) onto a block matrix in the
orthogonalization routine has been generalized. Now, an implementation
of the choice between the full orthogoanlization and per-site one
is straightforward: it is just a matter of defining a proper mapping.
The mapping scheme itself is described in the doc-string of method
'ProjectorGroup.orthogonalize()'
2015-11-19 11:47:59 +01:00
Oleg E. Peil
79f4c33458 Removed files accidentally added in the previous commit 2015-11-18 19:05:48 +01:00
Oleg E. Peil
61cb087561 Added a test to '_proj_group' test suite
Added a test comparing two-site density and overlap matrices.
2015-11-18 19:02:21 +01:00
Oleg E. Peil
4af8406b4c Fixed tests for ProjectorGroup
The tests have been modified to conform to the recent input and code
changes.
2015-11-18 15:46:58 +01:00
Oleg E. Peil
c1b3000c00 Fixed a bug in the orthogonalization routine
There was a very nasty bug in the preparation of the block matrix
'p_mat'. The point is that this matrix is created once for all k-points
with the band dimension being the maximum possible. However, only
a part of the matrix is used at every k-point but the orthogonalization
is done for the whole matrix. The problem was that if the number of
bands for a given k-point was smaller than that for the next k-point
them for the next k-point some part of 'p_mat' still contained data from
the previous step, which messed up the orthonormalization. Now, 'p_mat'
is set to zero at each step of the loop.
Also, property 'nion' was added to ProjectorShell since it is used
very often.
2015-11-18 15:17:51 +01:00
Oleg E. Peil
f994b82704 Rearranged and fixed some tests
First of all, suite '_plotools' is now split into three separate suites
'_plotools', '_proj_shell', '_proj_group', following the changes made
into the structure of the code.
Second, the two tests in 'test_projshells.py' have been fixed to conform
to the recent modifications in the code and input files.
2015-11-18 12:38:04 +01:00
Oleg E. Peil
401d416d4d Fixed 'plotools.py' and restructured 'proj_group.py'
Added missing import of ProjectorGroup and ProjectorShell to
'plotools.py'.
Moved separate routines 'orthogonalize_projector_matrix()'
and 'select_bands()' into class ProjectorGroup because these
routines are anyway not used elsewhere outside this class.
2015-11-13 19:09:25 +01:00
Oleg E. Peil
61395b12fa Restructured the source files
The classes ProjectorShell and ProjectorGroup are now defined in
different source files. This makes 'plotools.py' only contain
routines that control the data flows, including consistency checks
and output.
2015-11-13 18:15:21 +01:00
Oleg E. Peil
b285f37eca Added some new tests
New tests for the recently implemented parsers (for DOSMESH, EWINDOW,
and TRANSFILE) have been added.
2015-11-13 14:38:20 +01:00