@@ -881,8 +881,8 @@ def render_points_1d(self, **kwds):
881
881
882
882
sage: cube1 = polytopes.hypercube(1)
883
883
sage: proj = cube1.projection()
884
- sage: points = proj.render_points_1d()
885
- sage: points._objects
884
+ sage: points = proj.render_points_1d() # optional - sage.plot
885
+ sage: points._objects # optional - sage.plot
886
886
[Point set defined by 2 point(s)]
887
887
"""
888
888
return point2d ([c + [0 ] for c in self .coordinates_of (self .points )], ** kwds )
@@ -902,8 +902,8 @@ def render_line_1d(self, **kwds):
902
902
903
903
EXAMPLES::
904
904
905
- sage: outline = polytopes.hypercube(1).projection().render_line_1d()
906
- sage: outline._objects[0]
905
+ sage: outline = polytopes.hypercube(1).projection().render_line_1d() # optional - sage.plot
906
+ sage: outline._objects[0] # optional - sage.plot
907
907
Line defined by 2 points
908
908
"""
909
909
if len (self .lines ) == 0 :
@@ -922,8 +922,8 @@ def render_points_2d(self, **kwds):
922
922
923
923
sage: hex = polytopes.regular_polygon(6)
924
924
sage: proj = hex.projection()
925
- sage: hex_points = proj.render_points_2d()
926
- sage: hex_points._objects
925
+ sage: hex_points = proj.render_points_2d() # optional - sage.plot
926
+ sage: hex_points._objects # optional - sage.plot
927
927
[Point set defined by 6 point(s)]
928
928
"""
929
929
return point2d (self .coordinates_of (self .points ), ** kwds )
@@ -935,8 +935,8 @@ def render_outline_2d(self, **kwds):
935
935
EXAMPLES::
936
936
937
937
sage: penta = polytopes.regular_polygon(5)
938
- sage: outline = penta.projection().render_outline_2d()
939
- sage: outline._objects[0]
938
+ sage: outline = penta.projection().render_outline_2d() # optional - sage.plot
939
+ sage: outline._objects[0] # optional - sage.plot
940
940
Line defined by 2 points
941
941
"""
942
942
wireframe = []
@@ -957,8 +957,8 @@ def render_fill_2d(self, **kwds):
957
957
sage: cps = [i^3 for i in srange(-2,2,1/5)]
958
958
sage: p = Polyhedron(vertices = [[(t^2-1)/(t^2+1),2*t/(t^2+1)] for t in cps])
959
959
sage: proj = p.projection()
960
- sage: filled_poly = proj.render_fill_2d()
961
- sage: filled_poly.axes_width()
960
+ sage: filled_poly = proj.render_fill_2d() # optional - sage.plot
961
+ sage: filled_poly.axes_width() # optional - sage.plot
962
962
0.8
963
963
"""
964
964
poly = [polygon2d (self .coordinates_of (p ), ** kwds )
@@ -973,8 +973,8 @@ def render_vertices_3d(self, **kwds):
973
973
974
974
sage: p = polytopes.cross_polytope(3)
975
975
sage: proj = p.projection()
976
- sage: verts = proj.render_vertices_3d()
977
- sage: verts.bounding_box()
976
+ sage: verts = proj.render_vertices_3d() # optional - sage.plot
977
+ sage: verts.bounding_box() # optional - sage.plot
978
978
((-1.0, -1.0, -1.0), (1.0, 1.0, 1.0))
979
979
"""
980
980
return point3d (self .coordinates_of (self .points ), ** kwds )
@@ -987,8 +987,8 @@ def render_wireframe_3d(self, **kwds):
987
987
988
988
sage: cube = polytopes.hypercube(3)
989
989
sage: cube_proj = cube.projection()
990
- sage: wire = cube_proj.render_wireframe_3d()
991
- sage: print(wire.tachyon().split('\n')[77]) # for testing
990
+ sage: wire = cube_proj.render_wireframe_3d() # optional - sage.plot
991
+ sage: print(wire.tachyon().split('\n')[77]) # for testing # optional - sage.plot
992
992
FCylinder base 1.0 1.0 -1.0 apex -1.0 1.0 -1.0 rad 0.005 texture...
993
993
"""
994
994
wireframe = []
@@ -1007,8 +1007,8 @@ def render_solid_3d(self, **kwds):
1007
1007
EXAMPLES::
1008
1008
1009
1009
sage: p = polytopes.hypercube(3).projection()
1010
- sage: p_solid = p.render_solid_3d(opacity = .7)
1011
- sage: type(p_solid)
1010
+ sage: p_solid = p.render_solid_3d(opacity= .7) # optional - sage.plot
1011
+ sage: type(p_solid) # optional - sage.plot
1012
1012
<class 'sage.plot.plot3d.index_face_set.IndexFaceSet'>
1013
1013
"""
1014
1014
polys = self .polygons
@@ -1031,9 +1031,9 @@ def render_0d(self, point_opts=None, line_opts=None, polygon_opts=None):
1031
1031
1032
1032
EXAMPLES::
1033
1033
1034
- sage: print(Polyhedron([]).projection().render_0d().description())
1034
+ sage: print(Polyhedron([]).projection().render_0d().description()) # optional - sage.plot
1035
1035
<BLANKLINE>
1036
- sage: print(Polyhedron(ieqs=[(1,)]).projection().render_0d().description())
1036
+ sage: print(Polyhedron(ieqs=[(1,)]).projection().render_0d().description()) # optional - sage.plot
1037
1037
Point set defined by 1 point(s): [(0.0, 0.0)]
1038
1038
"""
1039
1039
if point_opts is None :
@@ -1062,7 +1062,7 @@ def render_1d(self, point_opts=None, line_opts=None, polygon_opts=None):
1062
1062
1063
1063
EXAMPLES::
1064
1064
1065
- sage: Polyhedron([(0,), (1,)]).projection().render_1d()
1065
+ sage: Polyhedron([(0,), (1,)]).projection().render_1d() # optional - sage.plot
1066
1066
Graphics object consisting of 2 graphics primitives
1067
1067
"""
1068
1068
plt = Graphics ()
0 commit comments