SkillAgentSearch skills...

Osdp

No description available

Install / Use

/learn @Embedded-SW-VnV/Osdp
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Contributors Forks Stargazers Issues LGPL v2.1 License

<h3 align="center">OSDP: Semi-definite programming (SDP) in OCaml</h3> <p align="center"> OSDP is an OCaml frontend library to semi-definite programming (SDP) solvers. <br /> <a href="https://embedded-sw-vnv.github.io/osdp/doc/"><strong>Explore the docs »</strong></a> <br /> <br /> <!-- <a href="https://github.com/Embedded-SW-VnV/osdp">View Demo</a> · --> <a href="https://github.com/Embedded-SW-VnV/osdp/issues">Report Bug</a> · <a href="https://github.com/Embedded-SW-VnV/osdp/issues">Request Feature</a> </p> </div> <details> <summary>Table of Contents</summary> <ol> <li> <a href="#about-the-project">About The Project</a> <ul> <li><a href="#built-with">Built With</a></li> </ul> </li> <li> <a href="#getting-started">Getting Started</a> <ul> <li><a href="#prerequisites">Prerequisites</a></li> <li><a href="#installation">Installation</a></li> </ul> </li> <li><a href="#usage">Usage</a></li> <li><a href="#documentation">Documentation</a></li> <li><a href="#troubles">Troubles</a></li> <li><a href="#license">License</a></li> </ol> </details>

About OSDP

OSDP is an OCaml frontend library to semi-definite programming (SDP) solvers.

See directory example for how to use the library.

Getting Started

Prerequisites

OSDP relies on external optimization tools

  • Csdp
  • Mosek
  • SDPA

and on the following opam packages:

opam install ocamlfind dune conf-autoconf zarith ocplib-simplex.0.5 conf-csdp

Csdp

Csdp is free software and is available in most Unix systems. Eg. on Debian-based systems

apt-get install csdp

or, on OSX

brew install csdp

Csdp binary has to be available in the path.

Mosek

Mosek is a commercial tool available at www.mosek.com. OSDP is linked against the dynamic library of Mosek. Make sure that the library is available in the dynamic library environment variable.

Let PATH_TO_MOSEKDIR be path that contains the dynamic library, eg. libmosek64.so on Linux and libmosek64.dylib on OSX.

  • On Linux
 export LD_LIBRARY_PATH = PATH_TO_MOSEKDIR:$LD_LIBRARY_PATH
  • On OSX
 export DYLD_LIBRARY_PATH = PATH_TO_MOSEKDIR:$DYLD_LIBRARY_PATH

SDPA

Csdp is free software and is available in most Unix systems. Eg. on Debian-based systems

apt-get install sdpa

Like CSDP, it has to be available as a binary in the user path.

Installation

See INSTALL.

Using opam:

opam install osdp

Using the source:

  1. Clone the repo

    git clone https://github.com/Embedded-SW-VnV/osdp.git
    
  2. Install dependencies

    opam install ocamlfind dune conf-autoconf zarith ocplib-simplex.0.5 conf-csdp
    
  3. Compile

    autoconf
    ./configure
    make
    make install
    

Usage

As library

open Osdp

Ocaml toplevel

To use with the ocaml toplevel

% rlwrap ocaml
# #use "topfind";;
# #require "osdp";;

These last two lines can be added to ~/.ocamlinit to avoid typing them again and again.

Documentation

Type

% make doc

to generate documentation (then see doc/index.html) or visit https://embedded-sw-vnv.github.io/osdp/doc/

Troubles

When running with OSX, some issues with the link of moseklib:

  • either run the final binary with
    DYLD_LIBRARY_PATH="$DYLD_LIBRARY_PATH:`dirname \`which mosek\``" my_new_binary
    
  • or use install_name_tool to provide the absolute path in the dynamic linking lib. It has to be done for every binary using Osdp, even indirectly.

License

Distributed under the LGPL-v2.1 License.

Related Skills

View on GitHub
GitHub Stars5
CategoryDevelopment
Updated2y ago
Forks1

Languages

OCaml

Security Score

65/100

Audited on Aug 22, 2023

No findings