YANE - Short Software Guide 1.0.1

Configuring and Compiling the Problem Package


The C++ examples accompanying the book are contained in a single "CMake" project. To compile this project you require:

and additionally the core routine of the YANE package, that is

as well as at least one of the optimization method wrappers for YANE:

In order to download all these packages you need to login to our homepage www.nonlinearmpc.com to access the software.

All these packages are again "CMake" projects, so the installation guide on this page also applies to these packages.


Unpacking any of the files via

        tar -xvf <libname>-<version>.tar.gz
        cd <libname>

will create a new folder containing the source code files.

Configuring the Project

Within this folder, a new subfolder for compiling the source code must be generated

        cd <libname>-<version>
        mkdir <build> (or md <build> using Windows)

to avoid overwriting the CMake compilation and installation routines.

Now, the configuration file for CMake needs to be generated from within the created subfolder <build>. Here, user specific options can be supplied, e.g., a local installation path:

        cd build
        cmake -DCMAKE_INSTALL_PREFIX=<installation_path> ../

Note that the standard installationprefix is set to /usr/local (or the corresponding Windows equivalent) and uses the subfolders /lib and /include/<libname>.

Compiling and Installing

Once the configuration is complete, the package can be compiled and installed via

        make install

Note that depending on the chosen <installation_path> the install command may require superuser rights.

Moreover, the environment variables used by the C++ compiler of the system must contain the installation path which can be added via

        export CPLUS_INCLUDE_PATH=<installation_path>/include:$CPLUS_INCLUDE_PATH
        export LIBRARY_PATH=<installation_path>/lib:$LIBRARY_PATH
        export LD_LIBRARY_PATH=<installation_path>/lib:$LD_LIBRARY_PATH

Note that the names of the environmental variables depend on your operating system. For instance, the variabale LD_LIBARY_PATH needs to be replaced by DYLD_LIBRARY_PATH if you are using MacOS. To obtain the correct variable names and to set these variables globally please follow the documentation of operating system.

Jürgen Pannek <juergen.pannek@googlemail.com>