This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Eigenvalue stuff in Fenics?

0 votes

My Fenics install bombs on not finding Eigen. Is that required? Can I disable it?

From googling around I see that there is some connection to Slepc. How can I add that to the installation?

I know that I'm supposed to ask this on the support mailing list, but the link to the support mailing list is strictly 404-compliant.

Victor.

asked Apr 26, 2017 by VictorEijkhout FEniCS Novice (120 points)

Did you install Eigen? It is CMake based and should be straightforward to install:

wget http://bitbucket.org/eigen/eigen/get/3.3.3.tar.gz
tar zxf 3.3.3.tar.gz
cd eigen-eigen-67e894c6cd8f/
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/some/path ..
make install

Then set EIGEN_DIR to the directory you chose to install Eigen:

export EIGEN_DIR=/some/path

DOLFIN should then be able to pick up Eigen.

There is something missing. Dolfin is not finding files because it is looking in the wrong location:

CMake Error at cmake/modules/FindEigen3.cmake:42 (file):
  file failed to open for reading (No such file or directory):

    /work/00434/include/eigen3/Eigen/src/Core/util/Macros.h
Call Stack (most recent call first):
  cmake/modules/FindEigen3.cmake:93 (_eigen3_check_version)
  CMakeLists.txt:337 (find_package)

But as you can see I specified a very different location for eigen:

[staff:fenics:13] ls dolfin-build/
CMakeCache.txt  CMakeFiles/
[staff:fenics:14] grep eigen dolfin-build/CMakeCache.txt 
EIGEN_DIR:UNINITIALIZED=/work/00434/eijkhout/fenics/eigen-install
//The directory containing a CMake configuration file for Eigen3.
Eigen3_DIR:PATH=/work/00434/eijkhout/fenics/eigen-build

Both of those paths exist and are correct.

[staff:fenics:20] ls /work/00434/eijkhout/fenics/eigen-install/include/eigen3/Eigen/src/Core/util/
BlasUtil.h   DisableStupidWarnings.h  IndexedViewHelper.h  Macros.h  Meta.h         NonMPL2.h                 StaticAssert.h   XprHelper.h
Constants.h  ForwardDeclarations.h    IntegralConstant.h   Memory.h  MKL_support.h  ReenableStupidWarnings.h  SymbolicIndex.h
[staff:fenics:21] 

Try removing the CMake build cache for DOLFIN and then try again.

  1. What is the name of that cache?

  2. I've deleted all of the directory in which I build. Same error.

  3. Is EIGEN_DIR the only variable I need to set? It seems that setting EIGEN3_INCLUDE_DIR solves the problem.

  1. The CMake cache is in the build directory where you run cmake. To clean the CMake cache, you can simply remove everything in the build directory, but it is usually enough to remove the file CMakeCache.txt. I usually just wipe out the whole build directory.

  2. That is strange.

  3. It should be enough to set EIGEN_DIR, but you can also try any of these:

    export CMAKE_PREFIX_PATH=/work/00434/eijkhout/fenics/eigen-install
    export EIGEN3_ROOT=/work/00434/eijkhout/fenics/eigen-install

...