Using lapack to find eigenvectors of matrix

Post here if you have a question about linking your program with LAPACK or ScaLAPACK library

Using lapack to find eigenvectors of matrix

Postby hjacobse » Mon Jan 13, 2014 7:34 pm

Hi there
I just installed lapack using
sudo apt-get install liblapack-dev
I am trying to write some fortran code, where I need to calculate the eigenvalues of a matrix.
I can compile and run the programs on this web site: http://people.sc.fsu.edu/~jburkardt%20/ ... mples.html (the one named apack_prb.f90, near the bottom), so I would think that everything is installed correctly.
To find the eigenvalues and eigenvectors, I followed the recommendations here: http://software.intel.com/sites/product ... B4537F.htm and am trying to use the heevd routine (http://software.intel.com/sites/product ... B4537F.htm)
In my code, I implement this simply as call heevd(Hup, Evecup, 'V'), where Hup is a 16x16 matrix and Evecup is declared as an array with 16 entries.
I try to compile the code with
gfortran -o test test.f90 -L$HOME/libf77/$ARCH -lblas -llapack
(this is the same command that worked for the test program I downloaded).
I get the following error:
/tmp/ccBaf67l.o: In function MAIN__': test.f90:(.text+0x33ff): undefined reference to heevd_' collect2: error: ld returned 1 exit status
I have no idea what to do - can anyone enlighten me?
I use Ubuntu 12.10.
hjacobse
 
Posts: 1
Joined: Mon Jan 13, 2014 7:30 pm

Return to Linking Problem

Who is online

Users browsing this forum: No registered users and 1 guest