mirror of
https://github.com/QuantumPackage/qp2.git
synced 2025-01-09 11:43:55 +01:00
minor fix in scf
This commit is contained in:
parent
c48654f550
commit
40abfb368a
@ -234,7 +234,7 @@ END_DOC
|
|||||||
endif
|
endif
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
|
deallocate(scratch)
|
||||||
! Pad B matrix and build the X matrix
|
! Pad B matrix and build the X matrix
|
||||||
|
|
||||||
do i=1,dim_DIIS
|
do i=1,dim_DIIS
|
||||||
@ -254,8 +254,8 @@ END_DOC
|
|||||||
ipiv(dim_DIIS+1) &
|
ipiv(dim_DIIS+1) &
|
||||||
)
|
)
|
||||||
|
|
||||||
double precision, allocatable :: AF(:,:)
|
double precision, allocatable :: AF(:,:),scratch_d1(:)
|
||||||
allocate (AF(dim_DIIS+1,dim_DIIS+1))
|
allocate (AF(dim_DIIS+1,dim_DIIS+1),scratch_d1(1))
|
||||||
double precision :: rcond, ferr, berr
|
double precision :: rcond, ferr, berr
|
||||||
integer :: iwork(dim_DIIS+1), lwork
|
integer :: iwork(dim_DIIS+1), lwork
|
||||||
|
|
||||||
@ -268,13 +268,13 @@ END_DOC
|
|||||||
rcond, &
|
rcond, &
|
||||||
ferr, &
|
ferr, &
|
||||||
berr, &
|
berr, &
|
||||||
scratch,-1, &
|
scratch_d1,-1, &
|
||||||
iwork, &
|
iwork, &
|
||||||
info &
|
info &
|
||||||
)
|
)
|
||||||
lwork = int(scratch(1,1))
|
lwork = int(scratch_d1(1))
|
||||||
deallocate(scratch)
|
deallocate(scratch_d1)
|
||||||
allocate(scratch(lwork,1))
|
allocate(scratch_d1(lwork))
|
||||||
|
|
||||||
call dsysvx('N','U',dim_DIIS+1,1, &
|
call dsysvx('N','U',dim_DIIS+1,1, &
|
||||||
B_matrix_DIIS,size(B_matrix_DIIS,1), &
|
B_matrix_DIIS,size(B_matrix_DIIS,1), &
|
||||||
@ -285,11 +285,11 @@ END_DOC
|
|||||||
rcond, &
|
rcond, &
|
||||||
ferr, &
|
ferr, &
|
||||||
berr, &
|
berr, &
|
||||||
scratch,size(scratch), &
|
scratch_d1,size(scratch_d1), &
|
||||||
iwork, &
|
iwork, &
|
||||||
info &
|
info &
|
||||||
)
|
)
|
||||||
deallocate(scratch,ipiv)
|
deallocate(scratch_d1,ipiv)
|
||||||
|
|
||||||
if(info < 0) then
|
if(info < 0) then
|
||||||
stop 'bug in DIIS'
|
stop 'bug in DIIS'
|
||||||
|
Loading…
Reference in New Issue
Block a user