#8934 closed defect (fixed)
Trivial bug in computing faces of non-full-dimensional lattice polytopes
Reported by: | novoselt | Owned by: | mhampton |
---|---|---|---|
Priority: | major | Milestone: | sage-4.4.4 |
Component: | geometry | Keywords: | |
Cc: | vbraun | Merged in: | sage-4.4.4.alpha0 |
Authors: | Andrey Novoseltsev | Reviewers: | Volker Braun |
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description
Currently computing faces of a non-full-dimensional lattice polytopes causes and exception, because when I was implementing support for such polytopes I missed a parameter in one place. The attached little patch fixes it and adds a doctest for the future.
Attachments (1)
Change History (7)
comment:1 Changed 12 years ago by
- Status changed from new to needs_review
comment:2 Changed 12 years ago by
- Cc vbraun added
- Status changed from needs_review to needs_work
Changed 12 years ago by
comment:3 Changed 12 years ago by
- Status changed from needs_work to needs_review
I added ":" into the docstring and tried to address some of the issues with 0-dimensional polytopes, namely, it is now possible to ask for points and faces of them. The list of faces in this case is empty, since only proper faces are returned in the other dimensions. In particular, asking for any faces of the given dimension will cause an error, but that seems to be consistent and I have documented it. I also added a synonym "all_facet_equations" for "all_polars", since calling the second one does not make a lot of sense for non-reflexive polytopes (although it will do the job). Thanks a lot for quick reviews!
comment:4 Changed 12 years ago by
- Status changed from needs_review to positive_review
The new patch looks good! I've tried it and it works as expected. Should be committed to Sage asap.
comment:5 Changed 12 years ago by
- Merged in set to sage-4.4.4.alpha0
- Resolution set to fixed
- Reviewers set to Voker Braun
- Status changed from positive_review to closed
comment:6 Changed 12 years ago by
- Reviewers changed from Voker Braun to Volker Braun
I'm pretty sure you need the double colon in
or the example will not be typeset correctly.
A special case of non-full-dimensional polytopes is the zero-dimensional case. This one is also broken, but in a slightly different way:
Also,
p.points()
fails for the same reason. It would be great if you could fix this case as well.