Clone this wiki locally

Welcome to CasADi!

CasADi is a symbolic framework for algorithmic (a.k.a. automatic) differentiation and numeric optimization. Using the syntax of computer algebra systems, it allows users to construct symbolic expressions consisting of either scalar- or (sparse) matrix-valued operations. These expressions can then be efficiently differentiated using state-of-the-art algorithms for algorithmic differentiation in forward and reverse modes and graph coloring techniques for generating complete, large and sparse Jacobians and Hessians.

The main purpose of the tool is to be a low-level tool for quick, yet highly efficient implementation of algorithms for nonlinear numerical optimization. Of particular interest is dynamic optimization, using either a collocation approach, or a shooting-based approach using embedded ODE/DAE-integrators. In either case, CasADi relieves the user from the work of efficiently calculating the relevant derivative or ODE/DAE sensitivity information to an arbitrary degree, as needed by the NLP solver. This together with a full-featured Python front end, as well as back ends to state-of-the-art codes such as Sundials (CVODES, IDAS and KINSOL), IPOPT, WORHP, SNOPT and KNITRO, drastically reduces the effort of implementing the methods compared to a pure C/C++/Fortran approach.

Every feature of CasADi (with very few exceptions) is available in C++ and Python with little to no difference in performance, so the user has the possibility of working completely in C++, Python or mixing the languages. We recommend new users to try out the Python version first, since it allows interactivity and is better documented than the C++ front-end.

CasADi is an open-source tool, written in self-contained C++ code, depending only on the C++ Standard Library. It is developed by Joel Andersson and Joris Gillis at the Optimization in Engineering Center, OPTEC of the K.U. Leuven under supervision of Moritz Diehl. CasADi is distributed under the LGPL license, meaning the code can be used royalty-free even in commercial applications.

Pointers

In the following pages, you will find instructions on how to install and use CasADi, as well as pointers to how to get more help.

Major improvements to the build system. In addition to compiling on Linux and Windows, CasADi has now compiles well on Mac OS X.

A major update of the support for embedding ODE/DAE integrators into symbolic expressions. Forward and adjoint sensitivities to an arbitrary degree is now supported. The integrator formulation has been extended to contain a DAE with initial conditions coupled to another DAE with terminal constraints.

Sundials (version 2.5.0) and qpOASES (version 3.0) are now distributed with CasADi.

Interfaces to several new tools, including the OOQP, qpOASES and the ACADO integrators

A feature complete Octave front-end (though not as stable as the Python front-end)

Faster, more economical symbolic and numeric Jacobians through graph coloring

Symbolic Jacobian generation for the MX class, using both forward and adjoint mode (still beta)

An automated test robot compiles the trunk and runs the test suit after every commit with GCC as well as Visual C++, making the trunk notably more stable than before. Thanks Joris for this great feature!

Automatic transformation of certain MX graphs to the (less economical but more efficient) SX graph.

1 June 2011:
Version 1.2.0beta has now been released. See the list of changes for a list of changes from the previous release.

New or improved features include:

Extensive bug fixes

A major documentation effort (thanks Joris and Attila!)

A Python-based test suite

A first version of a symbolic Jacobian generation for the MX class

An Octave front-end (working but not yet completed)

8 February 2011:
Version 1.1.0beta has now been released, the first completely public release. You will find it in the Sourceforge SVN, where the code is now located. Enjoy!