mirror of
https://github.com/QuantumPackage/qp2.git
synced 2024-12-25 04:53:32 +01:00
Moved allocations from declaration.
This commit is contained in:
parent
6486c89583
commit
49e5d57c40
@ -872,19 +872,16 @@ subroutine calculate_sigma_vector_cfg_nst_naive_store(psi_out, psi_in, n_st, sze
|
||||
real*8,intent(out) :: psi_out(sze,n_st)
|
||||
integer(bit_kind) :: Icfg(N_INT,2)
|
||||
integer :: i,j,k,l,p,q,noccp,noccq, ii, jj, m, n, idxI, kk, nocck,orbk
|
||||
integer(bit_kind) :: alphas_Icfg(N_INT,2,max(sze,100))
|
||||
integer(bit_kind) :: singlesI(N_INT,2,max(sze,100))
|
||||
integer(bit_kind) :: connectedI_alpha(N_INT,2,max(sze,100))
|
||||
integer :: idxs_singlesI(max(sze,100))
|
||||
integer :: idxs_connectedI_alpha(max(sze,100))
|
||||
integer(bit_kind) :: psi_configuration_out(N_INT,2,max(sze,100))
|
||||
real*8 :: psi_coef_out(n_CSF)
|
||||
logical :: psi_coef_out_init(n_CSF)
|
||||
integer :: excitationIds_single(2,max(sze,100))
|
||||
integer :: excitationTypes_single(max(sze,100))
|
||||
integer :: excitationIds(2,max(sze,100))
|
||||
integer :: excitationTypes(max(sze,100))
|
||||
real*8 :: diagfactors(max(sze,100))
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: alphas_Icfg
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: singlesI
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: connectedI_alpha
|
||||
integer,dimension(:),allocatable :: idxs_singlesI
|
||||
integer,dimension(:),allocatable :: idxs_connectedI_alpha
|
||||
integer,dimension(:,:),allocatable :: excitationIds_single
|
||||
integer,dimension(:),allocatable :: excitationTypes_single
|
||||
integer,dimension(:,:),allocatable :: excitationIds
|
||||
integer,dimension(:),allocatable :: excitationTypes
|
||||
real*8,dimension(:),allocatable :: diagfactors
|
||||
integer :: nholes
|
||||
integer :: nvmos
|
||||
integer :: listvmos(mo_num)
|
||||
@ -909,7 +906,18 @@ subroutine calculate_sigma_vector_cfg_nst_naive_store(psi_out, psi_in, n_st, sze
|
||||
real*8, external :: mo_two_e_integral
|
||||
real*8, external :: get_two_e_integral
|
||||
real*8 :: diag_energies(n_CSF)
|
||||
!PROVIDE mo_two_e_integrals_in_map mo_integrals_map big_array_exchange_integrals
|
||||
|
||||
! allocate
|
||||
allocate(alphas_Icfg(N_INT,2,max(sze,100)))
|
||||
allocate(singlesI(N_INT,2,max(sze,100)))
|
||||
allocate(connectedI_alpha(N_INT,2,max(sze,100)))
|
||||
allocate(idxs_singlesI(max(sze,100)))
|
||||
allocate(idxs_connectedI_alpha(max(sze,100)))
|
||||
allocate(excitationIds_single(2,max(sze,100)))
|
||||
allocate(excitationTypes_single(max(sze,100)))
|
||||
allocate(excitationIds(2,max(sze,100)))
|
||||
allocate(excitationTypes(max(sze,100)))
|
||||
allocate(diagfactors(max(sze,100)))
|
||||
|
||||
!print *," sze = ",sze
|
||||
call calculate_preconditioner_cfg(diag_energies)
|
||||
@ -918,7 +926,6 @@ subroutine calculate_sigma_vector_cfg_nst_naive_store(psi_out, psi_in, n_st, sze
|
||||
norm_coef_cfg=0.d0
|
||||
|
||||
psi_out=0.d0
|
||||
psi_coef_out_init = .False.
|
||||
|
||||
istart_cfg = psi_csf_to_config_data(istart)
|
||||
iend_cfg = psi_csf_to_config_data(iend)
|
||||
@ -1026,7 +1033,6 @@ subroutine calculate_sigma_vector_cfg_nst_naive_store(psi_out, psi_in, n_st, sze
|
||||
cntj += 1
|
||||
meCC1 = AIJpqContainer(NSOMOI,NSOMOJ,extype,pmodel,qmodel,cnti,cntj)
|
||||
psi_out(jj,kk) += meCC1 * psi_in(ii,kk) * h_core_ri(p,q)
|
||||
psi_coef_out_init(jj) = .True.
|
||||
enddo
|
||||
enddo
|
||||
enddo
|
||||
@ -1185,7 +1191,6 @@ subroutine calculate_sigma_vector_cfg_nst_naive_store(psi_out, psi_in, n_st, sze
|
||||
do m = 1,colsikpq
|
||||
do l = 1,rowsTKI
|
||||
psi_out(idxs_connectedI_alpha(j)+m-1,kk) += AIJpqContainer(NSOMOalpha,NSOMOI,extype,pmodel,qmodel,l,m) * TKIGIJ(l,kk,j)
|
||||
psi_coef_out_init(idxs_connectedI_alpha(j)+m-1) = .True.
|
||||
enddo
|
||||
enddo
|
||||
enddo
|
||||
@ -1234,19 +1239,16 @@ subroutine calculate_sigma_vector_cfg_nst(psi_out, psi_in, n_st, sze, istart, ie
|
||||
real*8,intent(out) :: psi_out(sze,n_st)
|
||||
integer(bit_kind) :: Icfg(N_INT,2)
|
||||
integer :: i,j,k,l,p,q,noccp,noccq, ii, jj, m, n, idxI, kk, nocck,orbk
|
||||
integer(bit_kind) :: alphas_Icfg(N_INT,2,max(sze,100))
|
||||
integer(bit_kind) :: singlesI(N_INT,2,max(sze,100))
|
||||
integer(bit_kind) :: connectedI_alpha(N_INT,2,max(sze,100))
|
||||
integer :: idxs_singlesI(max(sze,100))
|
||||
integer :: idxs_connectedI_alpha(max(sze,100))
|
||||
integer(bit_kind) :: psi_configuration_out(N_INT,2,max(sze,100))
|
||||
real*8 :: psi_coef_out(n_CSF)
|
||||
logical :: psi_coef_out_init(n_CSF)
|
||||
integer :: excitationIds_single(2,max(sze,100))
|
||||
integer :: excitationTypes_single(max(sze,100))
|
||||
integer :: excitationIds(2,max(sze,100))
|
||||
integer :: excitationTypes(max(sze,100))
|
||||
real*8 :: diagfactors(max(sze,100))
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: alphas_Icfg
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: singlesI
|
||||
integer(bit_kind),dimension(:,:,:),allocatable :: connectedI_alpha
|
||||
integer,dimension(:),allocatable :: idxs_singlesI
|
||||
integer,dimension(:),allocatable :: idxs_connectedI_alpha
|
||||
integer,dimension(:,:),allocatable :: excitationIds_single
|
||||
integer,dimension(:),allocatable :: excitationTypes_single
|
||||
integer,dimension(:,:),allocatable :: excitationIds
|
||||
integer,dimension(:),allocatable :: excitationTypes
|
||||
real*8,dimension(:),allocatable :: diagfactors
|
||||
integer :: nholes
|
||||
integer :: nvmos
|
||||
integer :: listvmos(mo_num)
|
||||
@ -1271,7 +1273,19 @@ subroutine calculate_sigma_vector_cfg_nst(psi_out, psi_in, n_st, sze, istart, ie
|
||||
real*8, external :: mo_two_e_integral
|
||||
real*8, external :: get_two_e_integral
|
||||
real*8 :: diag_energies(n_CSF)
|
||||
!PROVIDE mo_two_e_integrals_in_map mo_integrals_map big_array_exchange_integrals
|
||||
|
||||
! allocate
|
||||
allocate(alphas_Icfg(N_INT,2,max(sze,100)))
|
||||
allocate(singlesI(N_INT,2,max(sze,100)))
|
||||
allocate(connectedI_alpha(N_INT,2,max(sze,100)))
|
||||
allocate(idxs_singlesI(max(sze,100)))
|
||||
allocate(idxs_connectedI_alpha(max(sze,100)))
|
||||
allocate(excitationIds_single(2,max(sze,100)))
|
||||
allocate(excitationTypes_single(max(sze,100)))
|
||||
allocate(excitationIds(2,max(sze,100)))
|
||||
allocate(excitationTypes(max(sze,100)))
|
||||
allocate(diagfactors(max(sze,100)))
|
||||
|
||||
|
||||
!print *," sze = ",sze
|
||||
call calculate_preconditioner_cfg(diag_energies)
|
||||
@ -1280,7 +1294,6 @@ subroutine calculate_sigma_vector_cfg_nst(psi_out, psi_in, n_st, sze, istart, ie
|
||||
norm_coef_cfg=0.d0
|
||||
|
||||
psi_out=0.d0
|
||||
psi_coef_out_init = .False.
|
||||
|
||||
istart_cfg = psi_csf_to_config_data(istart)
|
||||
iend_cfg = psi_csf_to_config_data(iend)
|
||||
@ -1388,7 +1401,6 @@ subroutine calculate_sigma_vector_cfg_nst(psi_out, psi_in, n_st, sze, istart, ie
|
||||
cntj += 1
|
||||
meCC1 = AIJpqContainer(NSOMOI,NSOMOJ,extype,pmodel,qmodel,cnti,cntj)
|
||||
psi_out(jj,kk) += meCC1 * psi_in(ii,kk) * h_core_ri(p,q)
|
||||
psi_coef_out_init(jj) = .True.
|
||||
enddo
|
||||
enddo
|
||||
enddo
|
||||
@ -1527,7 +1539,6 @@ subroutine calculate_sigma_vector_cfg_nst(psi_out, psi_in, n_st, sze, istart, ie
|
||||
do m = 1,colsikpq
|
||||
do l = 1,rowsTKI
|
||||
psi_out(idxs_connectedI_alpha(j)+m-1,kk) += AIJpqContainer(NSOMOalpha,NSOMOI,extype,pmodel,qmodel,l,m) * TKIGIJ(l,kk,j)
|
||||
psi_coef_out_init(idxs_connectedI_alpha(j)+m-1) = .True.
|
||||
enddo
|
||||
enddo
|
||||
enddo
|
||||
|
Loading…
Reference in New Issue
Block a user