Ask Your Question
1

Does the .faces function in the polytope package work?

asked 2014-08-11 23:01:29 +0100

bazzatope gravatar image

updated 2014-08-11 23:57:41 +0100

tmonteil gravatar image
 $ sage
----------------------------------------------------------------------
| Sage Version 4.7, Release Date: 2011-05-23                         |
| Type notebook() for the GUI, and license() for information.        |
----------------------------------------------------------------------
sage: P = polytopes.cross_polytope(3)
sage: P.vertices()
[[0, 0, 1], [0, 1, 0], [1, 0, 0], [0, 0, -1], [0, -1, 0], [-1, 0, 0]]
sage: P.faces(3)                     
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)

/home/barry/<ipython console> in <module>()

AttributeError: 'Polyhedron' object has no attribute 'faces'
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
2

answered 2014-08-11 23:47:53 +0100

tmonteil gravatar image

It works at least on the last Sage version, perhaps should you upgrade to the latest Sage 6.3 :

sage: P.faces(3)
(<0,1,2,3,4,5>,)
sage: P.faces(2)
(<0,1,2>, <0,1,3>, <0,2,4>, <0,3,4>, <3,4,5>, <2,4,5>, <1,3,5>, <1,2,5>)
edit flag offensive delete link more
0

answered 2014-08-11 23:51:40 +0100

bazzatope gravatar image

OK, thanks.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2014-08-11 23:01:29 +0100

Seen: 204 times

Last updated: Aug 11 '14