Skip to content

Commit a49f142

Browse files
committed
adding better check as suggested + cross links in the doc
1 parent 6abfdfc commit a49f142

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

src/sage/geometry/polyhedron/base5.py

+12-3
Original file line numberDiff line numberDiff line change
@@ -1521,6 +1521,8 @@ def translation(self, displacement):
15211521
15221522
OUTPUT: the translated polyhedron
15231523
1524+
.. SEEALSO:: :meth:`linear_transformation`, :meth:`dilation`
1525+
15241526
EXAMPLES::
15251527
15261528
sage: P = Polyhedron([[0,0], [1,0], [0,1]], base_ring=ZZ)
@@ -1606,6 +1608,8 @@ def dilation(self, scalar):
16061608
The polyhedron dilated by that scalar, possibly coerced to a
16071609
bigger base ring.
16081610
1611+
.. SEEALSO:: :meth:`linear_transformation`, :meth:`translation`
1612+
16091613
EXAMPLES::
16101614
16111615
sage: p = Polyhedron(vertices=[[t,t^2,t^3] for t in srange(2,6)])
@@ -1763,6 +1767,8 @@ def linear_transformation(self, linear_transf,
17631767
The polyhedron transformed by that matrix, possibly coerced to a
17641768
bigger base ring.
17651769
1770+
.. SEEALSO:: :meth:`dilation`, :meth:`translation`
1771+
17661772
EXAMPLES::
17671773
17681774
sage: b3 = polytopes.Birkhoff_polytope(3)
@@ -1810,9 +1816,12 @@ def linear_transformation(self, linear_transf,
18101816
18111817
One can scale by a scalar as follows::
18121818
1813-
sage: P = polytopes.simplex()
1814-
sage: P.linear_transformation(2)
1815-
A 3-dimensional polyhedron in QQ^4 defined as the convex hull of 4 vertices
1819+
sage: P = polytopes.cube()
1820+
sage: P2 = P.linear_transformation(2); P2
1821+
A 3-dimensional polyhedron in QQ^3 defined as
1822+
the convex hull of 8 vertices
1823+
sage: P2.volume()
1824+
64
18161825
18171826
Linear transformation respects backend::
18181827

0 commit comments

Comments
 (0)