HSL solvers on IPOPT [undefined symbol: dtrsm_]

434 views
Skip to first unread message

Yuki

unread,
Apr 30, 2021, 4:26:54 PM4/30/21
to CasADi
Hello all,

I've been using casadi and I really enjoy casadi! I'd like to ask one question about my problem with the HSL solver with ipopt.

I followed this to use different HSL solver. My  questions are
  1. where should I run this command (./configure --prefix=(where_you_want_to_install) LIBS="-llapack" --with-blas="-L/usr/lib -lblas" CXXFLAGS="-g -O2 -fopenmp" FCFLAGS="-g -O2 -fopenmp" CFLAGS="-g -O2 -fopenmp")? I guess I should run in metis-4.0.3 directory but in the directory there is no configuration files so I just skipped this part. Maybe this skip results in my problem.
  2. So, when I run casadi with ipopt, I got the following error:
    ---
    Exception of type: OPTION_INVALID in file "../../../../Ipopt/src/Algorithm/IpAlgBuilder.cpp" at line 393:
     Exception message: Selected linear solver HSL_MA86 not available.
    Tried to obtain HSL_MA86 from shared library "libhsl.so", but the following error occurred:
    /home/yuki/research/driver/coinhsl-linux-x86_64/lib/libhsl.so: undefined symbol: dtrsm_
    ---
    Could anybody help me with how to fix this issue?
For your reference, I'm using Ubuntu 20.04. Also, I got this result:
---
ldd ~/research/driver/coinhsl-linux-x86_64/lib/libhsl.so 

        linux-vdso.so.1 (0x00007ffece3d2000)
        libgfortran.so.3 => /lib/x86_64-linux-gnu/libgfortran.so.3 (0x00007fc910edf000)
        libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fc910d90000)
        libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fc910b9e000)
        libquadmath.so.0 => /lib/x86_64-linux-gnu/libquadmath.so.0 (0x00007fc910b54000)
        libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fc910b39000)
        /lib64/ld-linux-x86-64.so.2 (0x00007fc911567000)
---

I also got this:
/coinhsl-linux-x86_64/lib$ nm libhsl.so | grep -i dtrmm
                 U dtrmm_


I look forward to hearing from you!
Best regards,
Yuki Shirai

Yuki

unread,
May 6, 2021, 3:23:27 PM5/6/21
to CasADi
Hello all, could anybody help me to solve this issue? Thanks
Best,

joaosa...@gmail.com

unread,
May 15, 2021, 7:17:00 AM5/15/21
to CasADi
I think you  can install HSL separately from IPOPT

Meaning build IPOPT installation without hsl

Install HSL where cmake can find it (/usr/local ...)

Go to casadi/build folder

cmake -DWITH_HSL=ON -DWITH_IPOPT= ON ..

Joel Andersson

unread,
May 21, 2021, 4:34:08 PM5/21/21
to CasADi
IPOPT has a linear solver loader so if you install HSL as a dynamic library, it should be able to use it without reinstalling IPOPT or CasADi. Otherwise, this is mainly a question for the IPOPT mailing list. 

"dtrmm_" is a LAPACK routine however, so maybe the installation fails because you don't have BLAS/LAPACK in your path.

Joel
Reply all
Reply to author
Forward
0 new messages