Documented MOs

This commit is contained in:
Anthony Scemama 2014-04-10 22:26:42 +02:00
parent fa9984c495
commit 65cef0f6e6
4 changed files with 25 additions and 31 deletions

View File

@ -7,7 +7,7 @@ the constants that will be used to define on which kind of integer the bitmasks
will be defined.
In the program, when an integer ``X`` is used to represent a bit string (like a determinant
for example), it should be defined as, for example::
for example), it should be defined as, for example:
.. code-block:: fortran

View File

@ -2,6 +2,19 @@
MOs Module
==========
Molecular orbitals are expressed as
.. math::
\phi_k({\bf r}) = \sum_i C_{ik} \chi_k({\bf r})
The current set of molecular orbitals has a label ``mo_label``.
When the orbitals are modified, the label should also be updated to keep
everything consistent.
When saving the MOs, the ``mo_basis`` directory of the EZFIO file is copied
in the ``save`` directory, named by the current ``mo_label``.
Needed Modules
==============

View File

@ -1,8 +1,5 @@
mo_basis
mo_tot_num integer
mo_coef double precision (ao_basis_ao_num,mo_basis_mo_tot_num)
mo_energy double precision (mo_basis_mo_tot_num)
mo_occ double precision (mo_basis_mo_tot_num)
mo_symmetry character*(8) (mo_basis_mo_tot_num)
mo_label character*(64)

View File

@ -19,13 +19,21 @@ BEGIN_PROVIDER [ integer, mo_tot_num_align ]
END_PROVIDER
BEGIN_PROVIDER [ character*(64), mo_label ]
BEGIN_PROVIDER [ double precision, mo_coef, (ao_num_align,mo_tot_num) ]
&BEGIN_PROVIDER [ character*(64), mo_label ]
implicit none
BEGIN_DOC
! Label characterizing the MOS (local, canonical, natural, etc)
! Molecular orbital coefficients on AO basis set
! mo_coef(i,j) = coefficient of the ith ao on the jth mo
! mo_label : Label characterizing the MOS (local, canonical, natural, etc)
END_DOC
integer :: i, j
double precision, allocatable :: buffer(:,:)
!DIR$ ATTRIBUTES ALIGN : $IRP_ALIGN :: buffer
logical :: exists
PROVIDE ezfio_filename
!Label
call ezfio_has_mo_basis_mo_label(exists)
if (exists) then
call ezfio_get_mo_basis_mo_label(mo_label)
@ -33,32 +41,8 @@ BEGIN_PROVIDER [ character*(64), mo_label ]
mo_label = 'no_label'
call ezfio_set_mo_basis_mo_label(mo_label)
endif
END_PROVIDER
BEGIN_PROVIDER [ double precision, mo_energy, (mo_tot_num) ]
implicit none
BEGIN_DOC
! Fock diagonal elements
END_DOC
PROVIDE ezfio_filename
mo_energy = 0.d0
call ezfio_get_mo_basis_mo_energy(mo_energy)
END_PROVIDER
BEGIN_PROVIDER [ double precision, mo_coef, (ao_num_align,mo_tot_num) ]
implicit none
BEGIN_DOC
! Molecular orbital coefficients on AO basis set
! mo_coef(i,j) = coefficient of the ith ao on the jth mo
END_DOC
integer :: i, j
double precision, allocatable :: buffer(:,:)
!DIR$ ATTRIBUTES ALIGN : $IRP_ALIGN :: buffer
PROVIDE ezfio_filename
! Coefs
allocate(buffer(ao_num,mo_tot_num))
buffer = 0.d0
call ezfio_get_mo_basis_mo_coef(buffer)