~siesta-ts/siesta/trunk_ts_soc

« back to all changes in this revision

Viewing changes to Src/diagonalizeHk.F90

  • Committer: Nick Papior
  • Date: 2018-10-17 13:07:10 UTC
  • mfrom: (560.1.454 4.1)
  • Revision ID: nickpapior@gmail.com-20181017130710-q5qm3pm5eyokm30h
Merged r1014

Show diffs side-by-side

added added

removed removed

Lines of Context:
84
84
! ------------------------------------------------------------------------------
85
85
! Used module variables
86
86
  use precision,          only: dp           ! Real douple precision type 
 
87
  use densematrix,        only: allocDenseMatrix, resetDenseMatrix
87
88
  use densematrix,        only: Haux         ! Hamiltonian matrix in dense form
88
89
  use densematrix,        only: Saux         ! Overlap matrix in dense form
89
90
  use densematrix,        only: psi          ! Coefficients of the wave function
201
202
! These matrices are defined in the module dense matrix
202
203
  nhs  = 2 * no_u * no_l
203
204
  npsi = 2 * no_u * no_l
204
 
 
205
 
  call re_alloc( Haux,     1, nhs,   name='Haux',    routine='densematrix' )
206
 
  call re_alloc( Saux,     1, nhs,   name='Saux',    routine='densematrix' )
207
 
  call re_alloc( psi,      1, npsi,  name='psi',     routine='densematrix' )
 
205
  call allocDenseMatrix(nhs, nhs, npsi)
208
206
 
209
207
! Allocate memory related with the eigenvalues of the Hamiltonian (epsilon)
210
208
! and with a local variable where the coefficients of the eigenvector at the
298
296
 
299
297
  enddo kpoints
300
298
 
301
 
  call de_alloc( Haux,    name='Haux',    routine='densematrix' )
302
 
  call de_alloc( Saux,    name='Saux',    routine='densematrix' )
303
 
  call de_alloc( psi,     name='psi',     routine='densematrix' )
 
299
  call resetDenseMatrix()
304
300
  call de_alloc( epsilon, name='epsilon', routine='diagonalizeHk' )
305
301
 
306
302
  call timer('diagonalizeHk',2)