Example
Warning: There are no guarantees for the robustness of the GeoCalcLib! Please report any malfunction.
The permutahedron^{1} is given by the convex hull of all permutations of the coordinates of
\begin{equation} \begin{pmatrix} 1 \\ 2 \\ \vdots \\ d \end{pmatrix} \end{equation}
It is easy to see that all such vectors satisfy
\begin{equation} \begin{pmatrix} 1 && 1 && \cdots && 1 \end{pmatrix}x = \frac{d(d1)}{2} \end{equation}
i.e. and therefore has a dimension of .
We use as an example. Naturally is a 3dimensional polytope embedded in , in order to visualise it we need to project it onto . This can easily be done using a QR decomposition of . If then rotates in such a way that its first coordinate corresponds to . We can drop the first coordinate and study at the convex hull of 3dimensional vectors.
In Matlab we can use
Assume now we want to perform a projective transformation, that is we want to intersect the homogenisation of with a hyperplane . Since is a cone in simply rotating using a QR decomposition of and discarding the first coordinates would yield .
Therefore we use a facet enumeration of to produce , with that we will enumerate the vertices of
\begin{equation} T(\Pi_3,H) = \{x\in\mathbb R^4: x\in\text{homog}(\Pi_3)\wedge x\in H\} \end{equation}
Naturally such that we can again project them by using a QR decomposition.
For the numerical example assume . We use the following Matlab code:

G. M. Ziegler  Lectures on Polytopes ↩