coin-or / qpOASES

Open-source C++ implementation of the recently proposed online active set strategy
GNU Lesser General Public License v2.1
376 stars 127 forks source link

Schur complement approach for sparse QPs #40

Closed svigerske closed 4 years ago

svigerske commented 4 years ago

Issue created by migration from Trac.

Original creator: @djanka2

Original creation time: 2015-08-17 11:59:17

Assignee: @djanka2

Version:

Dear qpOASES community,

I'd like to point out a new feature of qpOASES: There is now support for solving QPs using a Schur complement approach for the linear algebra, which is especially efficient if the Hessian and Jacobian are sparse.

The Schur complement approach requires Harwell's MA57 4218174697 to factorize the KKT matrices. So far, it has only been tested for the Linux version of qpOASES. The changes concern Revision 154 of the qpOASES trunk.

To use the Schur complement approach in qpOASES, you need to take the following steps:

1.) Compile and install MA57. I took the following steps for MA57 5.2.0 under Ubuntu 14.04: a) Extract tar-archive. In the MA57 directory, call "./configure" b) Edit "src/Makefile": Add the "-fPIC" option to FCFLAGS (line 148) and FFLAGS (line 150) c) Call "make" and "sudo make install" to compile and copy "libhsl_ma57.a" and "libfakemetis.a" to "/usr/local/lib"

2.) Modify "make_linux.mk": a) Set line 46 to "REPLACE_LINALG = 0" an line 58 to "USE_SOLVER = MA57". Note that an external LAPACK version is required. b) In line 61, set the location of the MA57 and METIS libraries (should be correct if you have installed MA57 as described above).

3.) Call "make".

4.) The new class "SQProblemSchur" can now be used to create a QP that is solved with the new algorithm. See "examples/qrecipeSchur.cpp" for an example similar to the one given in "examples/qrecipe.cpp".

The main part of the algorithm was implemented by Andreas Waechter (Northwestern University). I contributed parts for treating nonconvex problems and made some changes to improve stability. The full algorithm is described in Chapter 8 of my PhD thesis 2 and is also included in a paper which is currently under review.

If you have questions, remarks, or feedback of any kind, don't hesitate to contact me!

Best regards, Dennis

4218174697: http://www.hsl.rl.ac.uk/catalogue/ma57.html

svigerske commented 4 years ago

Comment by ferreau created at 2015-08-17 12:00:02

Resolution: fixed

svigerske commented 4 years ago

Comment by ferreau created at 2015-08-17 12:00:02

Version: 3.0.1