<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Hello Irina, in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107978#M24226</link>
    <description>&lt;P&gt;Hello Irina,&lt;/P&gt;

&lt;P&gt;Regarding the elements h0(3,4), h0(4,3) you are right. It was a misprint. I corrected it.&lt;/P&gt;

&lt;P&gt;And yes you are correct about the complex declaration!&lt;/P&gt;

&lt;P&gt;I changed it to complex(8) and everything works fine!&lt;/P&gt;

&lt;P&gt;Thank you,&lt;/P&gt;

&lt;P&gt;Marios&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;P.S: I can't believe that was the problem, I completely missed it...&lt;/P&gt;</description>
    <pubDate>Sun, 26 Jun 2016 15:27:19 GMT</pubDate>
    <dc:creator>Marios_G_1</dc:creator>
    <dc:date>2016-06-26T15:27:19Z</dc:date>
    <item>
      <title>extended eigensolver routines</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107976#M24224</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;I am trying to diagonalize a matrix using the feast algorithm routines. I have written this small program to test&lt;/P&gt;

&lt;P&gt;zfeast_heev. The following code tries to diagonalize a 4x4 complex Hermitian matrix: &amp;nbsp;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;program test
    
   
    
    implicit none
    integer, parameter :: n=4      ! h0 nxn matrix
     
    complex(16) :: h0(n,n), zero

    character(len=1), parameter :: UPLO='F'
    integer :: fpm(128), loop, M0,M,info
    real(8) ::  epsout, E(n), res(n), Pi, alfa, Mk
  
    integer, parameter :: L=4
    complex(16) :: X(n,n)
    integer :: i,j,k,i1,j1
    
    real(8), parameter :: Emin=-5.0d0, Emax=5.0d0
   complex(16), parameter :: ii=(0.0d0,1.0d0)
    
    open (1, file='eigenvalues.dat')
    open (2, file='check.dat')
    
     zero=dcmplx(0.d0, 0.d0)
    
     h0=zero
     
     h0(1,2)= 2.0d0 + 2.0d0*ii
     h0(1,3)= 3.0d0 - 2.0d0*ii
     h0(2,1)= 2.0d0 - 2.0d0*ii
     h0(2,4)= 3.0d0 - 2.0d0*ii
     h0(3,1)= 3.0d0 + 2.0d0*ii
     h0(3,4)= -2.0d0 - 2.0d0*ii
     h0(4,2)= 3.0d0 + 2.0d0*ii
     h0(4,3)= -2.0d0 - 2.0d0*ii
     
    
    M0=L
    M=M0
      print *,'Search interval ', Emin,' ', Emax

      call feastinit(fpm)
      fpm(1)=1
      print *, ' Testing zfeast_hcsrev '
     
 
     call zfeast_heev(UPLO,n,h0,n, fpm, epsout, loop,Emin,Emax,M0,E,X,M,res,info)
    print  *,' FEAST OUTPUT INFO ',info
    if(info/=0) stop 1

    print *, 'Number of eigenvalues found ', M
    
    
    do i1=1,M
    write(1,*) E(i1)
    end do

  
    
    end program test&lt;/PRE&gt;

&lt;P&gt;The eigenvalues of the matrix h0 are 4.58258, 4.58258, -4.58258, -4.58258 but this program gives me different results.&lt;/P&gt;

&lt;P&gt;I hope someone can explain me what I am missing in order to make this code work properly.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Jun 2016 15:05:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107976#M24224</guid>
      <dc:creator>Marios_G_1</dc:creator>
      <dc:date>2016-06-24T15:05:07Z</dc:date>
    </item>
    <item>
      <title>Hi Marios,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107977#M24225</link>
      <description>&lt;P&gt;Hi Marios,&lt;/P&gt;

&lt;P&gt;The first&amp;nbsp;problem I see is that matrix h0 is not Hermitian (&lt;FONT face="Courier New"&gt;&lt;CODE class="fortran plain"&gt;h0(3,4)&amp;nbsp;is not equal to &lt;/CODE&gt;h0(4,3) conjugate&lt;/FONT&gt;). Intel MKL Extended Eigensolver supports only Symmetric or Hermitian matrices. Set &lt;FONT face="Courier New"&gt;h0(4,3)= -2.0d0&amp;nbsp;+ 2.0d0*ii &lt;/FONT&gt;and that will give you&amp;nbsp;matrix with described eigenvalues.&amp;nbsp;&lt;/P&gt;

&lt;P&gt;The second thing is that you use &lt;FONT face="Courier New"&gt;complex&lt;CODE class="fortran plain"&gt;(16) data type. By specifying parameter in a complex(16) type declaration, you specify both real and imaginary part 16-bytes long that gives overall size of 32 bytes. However, &lt;/CODE&gt;&lt;/FONT&gt;&lt;SPAN style="font: 13px/18.2px &amp;quot;Courier New&amp;quot;, Courier, monospace; color: rgb(102, 102, 102); text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; widows: 1; font-size-adjust: none; font-stretch: normal; background-color: rgb(255, 255, 255); -webkit-text-stroke-width: 0px;"&gt;COMPLEX*16 &lt;/SPAN&gt;type &lt;FONT face="Courier New"&gt;&lt;CODE class="fortran plain"&gt;required for &lt;/CODE&gt;&lt;/FONT&gt;zfeast_heev is of size&amp;nbsp;16, &lt;FONT face="Courier New"&gt;&lt;CODE class="fortran plain"&gt;&amp;nbsp;i.e. imaginary and real part both of size 8. So correct declaration of complex variables in your program would be: &lt;/CODE&gt;complex&lt;CODE class="fortran plain"&gt;(8) or &lt;/CODE&gt;complex*16.&lt;/FONT&gt;&lt;/P&gt;

&lt;P&gt;&lt;FONT face="Courier New"&gt;Best regards,&lt;/FONT&gt;&lt;/P&gt;

&lt;P&gt;&lt;FONT face="Courier New"&gt;Irina&lt;/FONT&gt;&lt;/P&gt;

&lt;P&gt;&lt;FONT face="Courier New"&gt;&lt;CODE class="fortran plain"&gt;&amp;nbsp;&lt;/CODE&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 26 Jun 2016 09:17:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107977#M24225</guid>
      <dc:creator>Irina_S_Intel</dc:creator>
      <dc:date>2016-06-26T09:17:00Z</dc:date>
    </item>
    <item>
      <title>Hello Irina,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107978#M24226</link>
      <description>&lt;P&gt;Hello Irina,&lt;/P&gt;

&lt;P&gt;Regarding the elements h0(3,4), h0(4,3) you are right. It was a misprint. I corrected it.&lt;/P&gt;

&lt;P&gt;And yes you are correct about the complex declaration!&lt;/P&gt;

&lt;P&gt;I changed it to complex(8) and everything works fine!&lt;/P&gt;

&lt;P&gt;Thank you,&lt;/P&gt;

&lt;P&gt;Marios&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;P.S: I can't believe that was the problem, I completely missed it...&lt;/P&gt;</description>
      <pubDate>Sun, 26 Jun 2016 15:27:19 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/extended-eigensolver-routines/m-p/1107978#M24226</guid>
      <dc:creator>Marios_G_1</dc:creator>
      <dc:date>2016-06-26T15:27:19Z</dc:date>
    </item>
  </channel>
</rss>

