Algorithm to find convex hull from linear constraints

1k Views Asked by At

Given a set of linear constraints $A_{in} x \leq b_{in}$ and $A_{eq} x = b_{eq}$ (with $x \in \mathbb{R}^n$) is there any algorithm to obtain the vertices of the convex hull generated by these constraints?

Simple example for $x\in\mathbb{R}^2$:

$\begin{cases} x_1+x_2 \leq 2 \\ -x_1+x_2 \leq 0 \\ x_2 = 0.5 \end{cases}$

example in R2 .

The convex hull is the segment between $(0.5,0.5)$ and $(1.5,0.5)$, so the result of the algorithm would be $\{(0.5,0.5), (1.5,0.5)\}$

1

There are 1 best solutions below

0
On BEST ANSWER

A system of equations defines a polyhedron. Defining polyhedra via inequalities is called H-representation (H for halfspace) and there is an equivalent description in terms of vertices, called V-representation (V for vertex). The latter follows from observing that once we enumerate the vertices, we can also capture the same geometric structure by considering their convex combinations. So, your question corresponds to converting H-representation to V-representation, which is a well studied problem in computational geometry literature if you want to go deeper into it.

Assuming there are no redundancies in the system of inequalities*, i.e. no expressions implied by the others, there is a very quick way to do this. A vertex of a polyhedron in an $n$-dimensional space is a point for which at least $n$ of the constraints in the system are active, i.e. satisfied with equality.

The catch in your case is, since there is an equality constraint. It has to be active, since otherwise the point would not be in the convex hull (see $(1,1)$ in your example). In general, if you have $k$ equalities, you are seeking the set of points that satisfy them all, as well as $n-k$ of the inequalities simultaneously.

Going back to your example, we must have $x_2 = 0.5$. Now, we need to find $x_1$ values that make at least one of two inequalities active because we're working with $n=2$ and $k=1$. Well, that yields exactly your result: $\{(0.5,0.5),(1.5,0.5)\}$.

* If you can't guarantee your system is redundancy-free, you can check that and remove the redundant ones via linear programming. Here is a very gentle introduction, check out Section 3.2.