Home Online Manual
Top
Back: normalFan
Forward: vertexEdgeGraph
FastBack:
FastForward:
Up: polymake_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.13.2.54 vertexAdjacencyGraph

Procedure from library polymake.lib (see polymake_lib).

Usage:
vertexAdjacencyGraph(p); p polytope

Return:
list, the first entry is a bigintmat containing all vertices as row vectors, and therefore assigning all vertices an integer. the second entry is a list of intvecs representing the adjacency graph of the vertices of p, the intvec in position i contains all vertices j which are connected to vertex i via an edge of p.

Example:
 
LIB "polymake.lib";
==> Welcome to polymake version
==> Copyright (c) 1997-2015
==> Ewgenij Gawrilow, Michael Joswig (TU Darmstadt)
==> http://www.polymake.org
intmat M[6][4] =
1,1,0,0,
1,0,1,0,
1,0,-1,0,
1,0,0,1,
1,0,0,-1,
1,-1,0,0;
polytope p = polytopeViaPoints(M);
vertexAdjacencyGraph(p);
==> polymake: used package ppl
==>   The Parma Polyhedra Library (PPL): A C++ library for convex polyhedra
==>   and other numerical abstractions.
==>   http://www.cs.unipr.it/ppl/
==> 
==> [1]:
==> 1, 0, 0,-1,
==> 1, 0,-1, 0,
==> 1,-1, 0, 0,
==> 1, 0, 0, 1,
==> 1, 0, 1, 0,
==> 1, 1, 0, 0
==> [2]:
==>    [1]:
==>       1,2,4,5
==>    [2]:
==>       0,2,3,5
==>    [3]:
==>       0,1,3,4
==>    [4]:
==>       1,2,4,5
==>    [5]:
==>       0,2,3,5
==>    [6]:
==>       0,1,3,4