Installation

This section shows how to install Julia, Polyhedra and a Polyhedra Manipulation Library of your choice.

Getting Julia

The first step is to install Julia. At the time of writing, the latest release of Julia is version 0.4 and the version 0.5 is in development. Polyhedra can be used with either Julia 0.4 and 0.5. Download links and more detailed instructions are available on the Julia website.

Getting Polyhedra

Julia has a package manager that makes the installation of new packages ridiculously simple. Open a Julia console (e.g. enter julia at the command line) and write:

julia> Pkg.add("Polyhedra")

To start using Polyhedra, you can now just write:

julia> using Polyhedra

Of course without installing a library, you won’t be able to do much. See the next section on installing a library.

Getting Libraries

Many C libraries are are available for manipulating Polyhedra. Some of them works with floating point arithmetic and some of them can do the computation exactly using rational arithmetic and multiple precision libraries such as GMP. Julia also natively support Rational arithmetic using multiple precision libraries and of course floating point arithmetic. That makes the use of both arithmetic very easy and transparent.

The following table provides a list of Polyhedra Manipulation Libraries. When they have a Julia library implementing the interface of Polyhedra.jl then the “Library” column shows the name of the library.

Solver Julia Package Library License Exact Rational Floating point
cdd CDDLib.jl CDDLibrary() GPL X X
ConvexHull ConvexHull.jl ConvexHullLib() MIT X  
lrs LRSLib.jl LRSLibrary() GPL X X
qhull QHull.jl QHullLib()     X
CHull2d CHull2d.jl   MIT X X
NewPolka None   GPL X  
Parma Polyhedra Library None   GPL X  
pd None   GPL X  
porta None   GPL X (overflow !)  

Please let me know if you plan to write a new wrapper (or an implementation in pure Julia). Since libraries use different algorithms, no library is better for every problem; here and here are comparisons.