#18213: A lot of polytopes constructor are broken
------------------------------+------------------------
Reporter: vdelecroix | Owner:
Type: defect | Status: new
Priority: major | Milestone: sage-6.7
Component: geometry | Resolution:
Keywords: | Merged in:
Authors: | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: | Stopgaps:
------------------------------+------------------------
Description changed by jdemeyer:
Old description:
> A lot of polytopes constructors in `sage.geometry.polyhedron.library`.
>
> 1. The Rhombicuboctahedron does not return what it should (as Python
> division was thought as Sage integer divisions). There is in the code
> {{{
> verts = [ [-3/2, -1/2, -1/2], [-3/2, -1/2, 1/2], [-3/2, 1/2, -1/2],
> ...
> }}}
>
> 2. The `great_rhombicuboctahedron` is defined over `QQ` but it should be
> defined over `QQ[sqrt(2)]`!! There are in two places rough approximation
> of sqrt(2) in the code
> {{{
> v1 = QQ(131739771357/54568400000) # ~ sqrt(2) + 1
> v2 = QQ(104455571357/27284200000) # ~ 2 sqrt(2)
> }}}
> Now that Sage supports Polyhedron over number fields, we should use
> them!
New description:
A lot of polytopes constructors in `sage.geometry.polyhedron.library`.
1. The Rhombicuboctahedron does not return what it should (as Python
division was thought as Sage integer divisions). There is in the code
{{{
verts = [ [-3/2, -1/2, -1/2], [-3/2, -1/2, 1/2], [-3/2, 1/2, -1/2],
...
}}}
2. The `great_rhombicuboctahedron` is defined over `QQ` but it should be
defined over `QQ[sqrt(2)]`! There are in two places rough approximation of
sqrt(2) in the code
{{{
v1 = QQ(131739771357/54568400000) # ~ sqrt(2) + 1 but actually 2 due to
Python division
v2 = QQ(104455571357/27284200000) # ~ 2 sqrt(2) but actually 3 due to
Python division
}}}
Instead, we should use the `base_ring` argument (with appropriate
defaults) and use `base_ring(2).sqrt()` instead.
3. While we're at it, remove the deprecations from #11634.
--
--
Ticket URL: <http://trac.sagemath.org/ticket/18213#comment:1>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.