TABLE OF CONTENTS


m_abi_linalg/abi_chpev [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_chpev

FUNCTION

INPUTS

PARENTS

SOURCE

232   subroutine abi_chpev(jobz,uplo,n,a,w,z,ldz,work,rwork,info)
233 
234 !This section has been created automatically by the script Abilint (TD).
235 !Do not modify the following lines by hand.
236 #undef ABI_FUNC
237 #define ABI_FUNC 'abi_chpev'
238 !End of the abilint section
239 
240  implicit none
241 
242  !Arguments ------------------------------------
243  character(len=1), intent(in) :: jobz
244  character(len=1), intent(in) :: uplo
245  integer, intent(in) :: n
246  integer, intent(in) :: ldz
247  complex(spc), intent(inout) :: a(:,:)
248  complex(spc), intent(out) :: z(:,:)
249  complex(spc), intent(inout) :: work(:)
250  real(sp), intent(inout) :: rwork(:)
251  real(sp), intent(out) :: w(:)
252  integer, intent(out) :: info
253 
254 ! *********************************************************************
255 
256  call chpev(jobz,uplo,n,a,w,z,ldz,work,rwork,info)
257 
258 end subroutine abi_chpev

m_abi_linalg/abi_chpev_alloc [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_chpev_alloc

FUNCTION

INPUTS

PARENTS

SOURCE

275  subroutine abi_chpev_alloc(jobz,uplo,n,a,w,z)
276 
277 !This section has been created automatically by the script Abilint (TD).
278 !Do not modify the following lines by hand.
279 #undef ABI_FUNC
280 #define ABI_FUNC 'abi_chpev_alloc'
281 
282 !End of the abilint section
283 
284  implicit none
285 
286 !Arguments ------------------------------------
287  character(len=1), intent(in) :: jobz
288  character(len=1), intent(in) :: uplo
289  integer, intent(in) :: n
290  complex(spc), intent(inout) :: a(:,:)
291  complex(spc), intent(out) :: z(:,:)
292  real(sp), intent(out) :: w(n)
293  integer :: info
294 
295 ! *********************************************************************
296 
297  call abi_chpev(jobz,uplo,n,a,w,z,n,eigen_c_work,eigen_c_rwork,info)
298 
299 end subroutine abi_chpev_alloc

m_abi_linalg/abi_dhpev [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_dhpev

FUNCTION

INPUTS

PARENTS

SOURCE

33   subroutine abi_dhpev(jobz,uplo,n,a,w,z,ldz,work,info,rwork,istwf_k)
34 
35 !This section has been created automatically by the script Abilint (TD).
36 !Do not modify the following lines by hand.
37 #undef ABI_FUNC
38 #define ABI_FUNC 'abi_dhpev'
39 !End of the abilint section
40 
41  implicit none
42 
43  !Arguments ------------------------------------
44  character(len=1), intent(in) :: jobz
45  character(len=1), intent(in) :: uplo
46  integer, intent(in) :: n
47  integer, intent(in) :: ldz
48  real(dp) :: a(*)    !vz_d
49  real(dp) :: z(*)    !vz_d
50  real(dp), intent(inout) :: work(*)
51  real(dp),optional, intent(inout) :: rwork(*)
52  real(dp) :: w(*)    !vz_d
53  integer, intent(out) :: info
54  !Optional Arguments ------------------------------------
55  integer, optional, intent(in) :: istwf_k
56 
57 !Local Arguments ------------------------------------
58  integer :: istwf_k_
59 
60  ! *********************************************************************
61 
62  istwf_k_ = 1; if (present(istwf_k)) istwf_k_ = istwf_k
63 
64  ! MG: FIXME: THIS IS BROKEN: rwork and istwfk_k!
65  !if ( present(istwf_k) .and. (istwf_k .ne. 2) .and. present(rwork)) then
66  if (istwf_k_ /= 2) then
67     ABI_CHECK(present(rwork),"rwork must be present")
68     call zhpev(jobz,uplo,n,a,w,z,ldz,work,rwork,info)
69  else
70     call dspev(jobz,uplo,n,a,w,z,ldz,work(1:3*n),info)
71  endif
72 
73 end subroutine abi_dhpev

m_abi_linalg/abi_dhpev_alloc_1d [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_dhpev_alloc_1d

FUNCTION

INPUTS

PARENTS

SOURCE

 90   subroutine abi_dhpev_alloc_1d(jobz,uplo,n,a,w,z,istwf_k,use_slk)
 91 
 92 !This section has been created automatically by the script Abilint (TD).
 93 !Do not modify the following lines by hand.
 94 #undef ABI_FUNC
 95 #define ABI_FUNC 'abi_dhpev_alloc_1d'
 96 
 97 !End of the abilint section
 98 
 99  implicit none
100  !Arguments ------------------------------------
101  character(len=1), intent(in) :: jobz
102  character(len=1), intent(in) :: uplo
103  integer, intent(in) :: n
104  real(dp), intent(inout) :: a(:)
105  real(dp), intent(out) :: w(:)
106  real(dp), intent(out) :: z(:,:)
107  integer, optional, intent(in) :: istwf_k
108  integer, optional, intent(in) :: use_slk
109 
110  !Local Arguments ------------------------------------
111  character(len=500) :: msg
112  integer :: info,use_slk_,istwf_k_
113 #ifdef HAVE_LINALG_SCALAPACK
114  type(matrix_scalapack)    :: sca_a,sca_ev
115  real(dp),allocatable :: tmp_evec(:,:)
116  integer :: dim_evec1,ierr
117 #endif
118 
119 ! *********************************************************************
120  ! write(*,*) "ENTERING abi_dhpev_alloc_1d n=",n
121  if( n > eigen_d_maxsize ) then
122     write(msg,'(a,2i3)')' Eigen size higher than max size set!!',n,eigen_d_maxsize
123     MSG_ERROR(msg)
124  endif
125  info = 0 ! to avoid unwanted warnings but scalapack doesn't check return
126 
127  use_slk_ = 0; if (present(use_slk)) use_slk_ = use_slk
128  istwf_k_ = 1; if (present(istwf_k)) istwf_k_ = istwf_k
129 
130 #ifdef HAVE_LINALG_SCALAPACK
131  if (use_slk_ == 1) then
132    ! if istwfk=1, then dim_evec1=2*n and if istwfk=2, dim_evec1=n
133    dim_evec1= 2*n/istwf_k_
134    ABI_ALLOCATE(tmp_evec,(dim_evec1,n))
135    tmp_evec = 0._dp
136    call init_matrix_scalapack(sca_a,n,n,abi_processor,istwf_k_,10)
137    call init_matrix_scalapack(sca_ev,n,n,abi_processor,istwf_k_,10)
138 
139 #ifdef HAVE_LINALG_ELPA
140    call matrix_from_global_sym(sca_a,a,istwf_k_)
141 #else
142    call matrix_from_global(sca_a,a,istwf_k_)
143 #endif
144    call compute_eigen_problem(abi_processor,sca_a,&
145 &        sca_ev,w,abi_communicator,istwf_k_)
146 
147    call matrix_to_global(sca_a,a,istwf_k_)
148    call matrix_to_reference(sca_ev,tmp_evec,istwf_k_)
149 
150    call xmpi_sum(tmp_evec,z,dim_evec1*n,abi_communicator,ierr)
151 
152    CALL destruction_matrix_scalapack(sca_a)
153    CALL destruction_matrix_scalapack(sca_ev)
154    ABI_DEALLOCATE(tmp_evec)
155   else
156 #endif
157     call abi_dhpev(jobz,uplo,n,a,w,z,n,eigen_d_work,info,&
158 &     rwork=eigen_z_rwork,istwf_k=istwf_k_)
159 #ifdef HAVE_LINALG_SCALAPACK
160   end if
161 #endif
162   if(info/=0) then
163      write(msg,'(a,i3)')' Problem in abi_xhpev, info= ',info
164      MSG_WARNING(msg)
165   endif
166 
167 end subroutine abi_dhpev_alloc_1d

m_abi_linalg/abi_dhpev_alloc_2d [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_dhpev_alloc_2d

FUNCTION

INPUTS

PARENTS

SOURCE

184  subroutine abi_dhpev_alloc_2d(jobz,uplo,n,a,w,z,istwf_k)
185 
186 !This section has been created automatically by the script Abilint (TD).
187 !Do not modify the following lines by hand.
188 #undef ABI_FUNC
189 #define ABI_FUNC 'abi_dhpev_alloc_2d'
190 
191 !End of the abilint section
192 
193  implicit none
194 
195 !Arguments ------------------------------------
196  character(len=1), intent(in) :: jobz
197  character(len=1), intent(in) :: uplo
198  integer, intent(in) :: n
199  real(dp), intent(inout) :: a(:,:)
200  real(dp), intent(out) :: w(:)
201  real(dp), intent(out) :: z(:,:)
202  integer :: info
203  integer, optional, intent(in) :: istwf_k
204 
205 !Local Arguments ------------------------------------
206  integer :: istwf_k_
207 
208  ! *********************************************************************
209 
210  istwf_k_ = 1; if (present(istwf_k)) istwf_k_ = istwf_k
211 
212  call abi_dhpev(jobz,uplo,n,a,w,z,n,eigen_d_work,info,&
213 &  rwork=eigen_z_rwork,istwf_k=istwf_k_)
214 
215 end subroutine abi_dhpev_alloc_2d

m_abi_linalg/abi_xhpev [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

  abi_xhpev

FUNCTION

  abi_xhpev is the generic function that compute
  all eigenvalues and, optionally, eigenvectors of a
  symmetric or hermitian matrix A in packed storage

COPYRIGHT

  Copyright (C) 2001-2018 ABINIT group (LNguyen,FDahm (CS))
  This file is distributed under the terms of the
  GNU General Public License, see ~ABINIT/Infos/copyright
  or http://www.gnu.org/copyleft/gpl.txt .

SOURCE


m_abi_linalg/abi_zhpev [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_zhpev

FUNCTION

INPUTS

PARENTS

SOURCE

316   subroutine abi_zhpev(jobz,uplo,n,a,w,z,ldz,work,rwork,info)
317 
318 !This section has been created automatically by the script Abilint (TD).
319 !Do not modify the following lines by hand.
320 #undef ABI_FUNC
321 #define ABI_FUNC 'abi_zhpev'
322 !End of the abilint section
323 
324  implicit none
325 
326 !Arguments ------------------------------------
327  character(len=1), intent(in) :: jobz
328  character(len=1), intent(in) :: uplo
329  integer, intent(in) :: n
330  integer, intent(in) :: ldz
331  complex(dpc), intent(inout) :: a(:,:)
332  complex(dpc), intent(out) :: z(:,:)
333  complex(dpc), intent(inout) :: work(:)
334  real(dp), intent(inout) :: rwork(:)
335  real(dp), intent(out) :: w(n)
336  integer, intent(out) :: info
337 
338 ! *********************************************************************
339 
340  call zhpev(jobz,uplo,n,a,w,z,ldz,work,rwork,info)
341 
342 end subroutine abi_zhpev

m_abi_linalg/abi_zhpev_alloc [ Functions ]

[ Top ] [ m_abi_linalg ] [ Functions ]

NAME

 abi_zhpev_alloc

FUNCTION

INPUTS

PARENTS

CHILDREN

SOURCE

361  subroutine abi_zhpev_alloc(jobz,uplo,n,a,w,z)
362 
363 !This section has been created automatically by the script Abilint (TD).
364 !Do not modify the following lines by hand.
365 #undef ABI_FUNC
366 #define ABI_FUNC 'abi_zhpev_alloc'
367 
368 !End of the abilint section
369 
370  implicit none
371 
372 !Arguments ------------------------------------
373  character(len=1), intent(in) :: jobz
374  character(len=1), intent(in) :: uplo
375  integer, intent(in) :: n
376  complex(dpc), intent(inout) :: a(:,:)
377  complex(dpc), intent(out) :: z(:,:)
378  real(dp), intent(out) :: w(n)
379  integer :: info
380 
381 ! *********************************************************************
382 
383  call abi_zhpev(jobz,uplo,n,a,w,z,n,eigen_z_work,eigen_z_rwork,info)
384 
385 end subroutine abi_zhpev_alloc