2009-05-14 17:48:27 +02:00
|
|
|
BEGIN_PROVIDER [ integer, mo_closed_num ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Number of closed shell Molecular orbitals
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_num_closed(mo_closed_num)
|
|
|
|
!$OMP END CRITICAL (qcio_critical)
|
|
|
|
ASSERT (mo_closed_num >= 0)
|
|
|
|
ASSERT (mo_closed_num <= elec_alpha_num)
|
|
|
|
ASSERT (mo_closed_num <= elec_beta_num)
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ integer, mo_active_num ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Number of active Molecular orbitals
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_num_active(mo_active_num)
|
|
|
|
!$OMP END CRITICAL (qcio_critical)
|
|
|
|
ASSERT (mo_active_num >= 0)
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
2009-05-18 15:00:54 +02:00
|
|
|
BEGIN_PROVIDER [ real, mo_occ, (mo_num) ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Occupation numbers of molecular orbitals
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
double precision, allocatable :: buffer(:)
|
|
|
|
allocate ( buffer(mo_tot_num) )
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_occupation(buffer)
|
|
|
|
!$OMP END CRITICAL (qcio_critical)
|
|
|
|
integer :: i
|
|
|
|
do i=1,mo_num
|
|
|
|
mo_occ(i) = buffer(i)
|
|
|
|
enddo
|
|
|
|
deallocate(buffer)
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
2009-05-14 17:48:27 +02:00
|
|
|
BEGIN_PROVIDER [ integer, mo_num ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Number of Molecular orbitals
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
mo_num = mo_closed_num + mo_active_num
|
|
|
|
ASSERT(mo_num > 0)
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ real, mo_coef, (ao_num,mo_num) ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Molecular orbital coefficients
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
integer :: i, j
|
2009-05-18 15:00:54 +02:00
|
|
|
double precision, allocatable :: buffer(:,:)
|
|
|
|
allocate (buffer(ao_num,mo_tot_num))
|
2009-05-14 17:48:27 +02:00
|
|
|
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_matrix(buffer)
|
|
|
|
!$OMP END CRITICAL (qcio_critical)
|
|
|
|
do j=1,mo_num
|
|
|
|
do i=1,ao_num
|
|
|
|
mo_coef(i,j) = buffer(i,j)
|
|
|
|
enddo
|
|
|
|
enddo
|
2009-05-18 15:00:54 +02:00
|
|
|
deallocate (buffer)
|
2009-05-14 17:48:27 +02:00
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ logical, mo_non_zero, (mo_num,ao_num) ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Values where the mo coefficients are /= 0.
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
integer :: i, j, k
|
|
|
|
|
|
|
|
do j=1,ao_num
|
|
|
|
do k=1,mo_num
|
|
|
|
mo_non_zero(k,j) = mo_coef_transp(j,k) /= 0.
|
|
|
|
enddo
|
|
|
|
enddo
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ real, mo_coef_transp, (mo_num,ao_num) ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Transposed array of mo coefficients
|
|
|
|
END_DOC
|
|
|
|
|
|
|
|
integer :: i, j, k
|
|
|
|
|
|
|
|
do j=1,ao_num
|
|
|
|
do k=1,mo_num
|
|
|
|
mo_coef_transp(k,j) = mo_coef(j,k)
|
|
|
|
enddo
|
|
|
|
enddo
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ logical, mo_is_closed, (mo_num) ]
|
|
|
|
&BEGIN_PROVIDER [ logical, mo_is_active, (mo_num) ]
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! mo_is_closed : True if mo(i) is a closed-shell
|
|
|
|
! mo_is_active : True if mo(i) is an active orbital
|
|
|
|
END_DOC
|
|
|
|
|
2009-05-18 15:00:54 +02:00
|
|
|
character, allocatable :: buffer(:)
|
|
|
|
allocate (buffer(mo_num))
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_classif(buffer)
|
|
|
|
!$OMP END CRITICAL
|
2009-05-14 17:48:27 +02:00
|
|
|
|
|
|
|
integer :: i
|
|
|
|
do i=1,mo_num
|
|
|
|
if ( buffer(i) == 'c' ) then
|
|
|
|
mo_is_closed(i) = .True.
|
|
|
|
mo_is_active(i) = .False.
|
|
|
|
else if ( buffer(i) == 'a' ) then
|
|
|
|
mo_is_closed(i) = .False.
|
|
|
|
mo_is_active(i) = .True.
|
|
|
|
else
|
|
|
|
mo_is_closed(i) = .False.
|
|
|
|
mo_is_active(i) = .False.
|
|
|
|
endif
|
|
|
|
enddo
|
2009-05-18 15:00:54 +02:00
|
|
|
deallocate (buffer)
|
2009-05-14 17:48:27 +02:00
|
|
|
END_PROVIDER
|
|
|
|
|
|
|
|
BEGIN_PROVIDER [ integer, mo_tot_num ]
|
|
|
|
|
|
|
|
BEGIN_DOC
|
|
|
|
! Total number of MOs in the QCIO file
|
|
|
|
END_DOC
|
|
|
|
!$OMP CRITICAL (qcio_critical)
|
|
|
|
call qcio_get_mo_num_orb_tot(mo_tot_num)
|
|
|
|
!$OMP END CRITICAL (qcio_critical)
|
|
|
|
ASSERT (mo_tot_num > 0)
|
|
|
|
|
|
|
|
END_PROVIDER
|
|
|
|
|