1

I want to evaluate the PARDISO (https://www.pardiso-project.org/) solver. I use MATLAB 2020b on Ubuntu 20.04 LTS for testing it. When I download the corresponding files and want to run a test, I get the error Invalid MEX-file '/home/<username>/Documents/PARDISO/ipopt.mexa64': libgfortran.so.3: cannot open shared object file: No such file or directory but the .mexa64 file is present. I searched for this error and found out, that I most likely need gfortran3 to run this file but gfortran3 is not supported under Ubuntu 20.04 LTS anymore. What can I do? Is there any other possibility to solve this problem?

2 Answers2

1

I am facing the exact problem that you're facing and I was able to overcome the problem by just copying a preexisting install of libfortran3. The link is "https://www.dropbox.com/s/01zxukpydgi749a/libgfort.tar?dl=1" choose either 32 or 64-bit option and extract it onto your pardiso install folder.

make sure you're adding the libfortran to your path with command

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/your path here/pardiso_install_folder

Once that is done check if the .mexa64 executable has all the required libraries linked to it by doing a

ldd ipopt.mexa64

in the pardiso install folder and link the appropriate libraries. I am pretty new to all this too, so let me know if it works.

1

I was able to correct the problem with

  1. First locate matlab's libgfortran file, for me it was in <YOUR MATLAB PATH>/MATLAB/sys/os/glnxa64/libgfortran.so.3.0.0
  2. make a link of this file in same path ln -s libgfortran.so.3.0.0 libgfortran.so.3

The error disappeared afterwards for me. Hope this helps someone.