# cartesian product polyhedra

Are there any book or paper citations on how the Cartesian product of polyhedra is computed within the polyhedron base class? Consider the following example input:

```
P1 = Polyhedron(vertices = [[1,1], [2,3], [3,0]], rays = [[3,2], [5,2]])
P2 = Polyhedron(vertices = [[6,0]], rays = [[1,9], [1,3]])
ExampleP = P1.product(P2)
ExampleP.Vrepresentation()
```

The output is:

```
A ray in the direction (0, 0, 1, 3),
A ray in the direction (0, 0, 1, 9),
A vertex at (1, 1, 6, 0),
A vertex at (2, 3, 6, 0),
A vertex at (3, 0, 6, 0),
A ray in the direction (3, 2, 0, 0),
A ray in the direction (5, 2, 0, 0)
```

How is this related to Sage ?

The question is asking if there is any reference for the computation that Sage is making.

Which is the code doing the computation, for instance for the cartesian product of the following object

`X`

with itself?Is this

`X`

in the right (polyhedron base) class?!To the orignal poster: please provide an example of the computation you are asking about. This makes it way easier to explore a question, thereby increasing chances of an answer.

Thanks for updating your question, now i think/hope i understand what you are asking for.