mirror of
https://github.com/QuantumPackage/qp2.git
synced 2024-11-07 05:53:37 +01:00
Merge branch 'master' into dev
This commit is contained in:
commit
4fd0626557
@ -749,7 +749,7 @@ subroutine fill_buffer_double(i_generator, sp, h1, h2, bannedOrb, banned, fock_d
|
|||||||
|
|
||||||
double precision :: eigvalues(N_states+1)
|
double precision :: eigvalues(N_states+1)
|
||||||
double precision :: work(1+6*(N_states+1)+2*(N_states+1)**2)
|
double precision :: work(1+6*(N_states+1)+2*(N_states+1)**2)
|
||||||
integer :: iwork(3+5*(N_states+1)), info, k
|
integer :: info, k , iwork(N_states+1)
|
||||||
|
|
||||||
if (do_diag) then
|
if (do_diag) then
|
||||||
double precision :: pt2_matrix(N_states+1,N_states+1)
|
double precision :: pt2_matrix(N_states+1,N_states+1)
|
||||||
@ -761,8 +761,8 @@ subroutine fill_buffer_double(i_generator, sp, h1, h2, bannedOrb, banned, fock_d
|
|||||||
pt2_matrix(N_states+1,istate) = mat(istate,p1,p2)
|
pt2_matrix(N_states+1,istate) = mat(istate,p1,p2)
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
call DSYEVD( 'V', 'U', N_states+1, pt2_matrix, N_states+1, eigvalues, &
|
call DSYEV( 'V', 'U', N_states+1, pt2_matrix, N_states+1, eigvalues, &
|
||||||
work, size(work), iwork, size(iwork), info )
|
work, size(work), info )
|
||||||
if (info /= 0) then
|
if (info /= 0) then
|
||||||
print *, 'error in '//irp_here
|
print *, 'error in '//irp_here
|
||||||
stop -1
|
stop -1
|
||||||
@ -770,7 +770,7 @@ subroutine fill_buffer_double(i_generator, sp, h1, h2, bannedOrb, banned, fock_d
|
|||||||
pt2_matrix = dabs(pt2_matrix)
|
pt2_matrix = dabs(pt2_matrix)
|
||||||
iwork(1:N_states+1) = maxloc(pt2_matrix,DIM=1)
|
iwork(1:N_states+1) = maxloc(pt2_matrix,DIM=1)
|
||||||
do k=1,N_states
|
do k=1,N_states
|
||||||
e_pert(iwork(k)) = eigvalues(k) - E0(iwork(k))
|
e_pert(k) = eigvalues(iwork(k)) - E0(k)
|
||||||
enddo
|
enddo
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user