#17197: document Polyhedron defined over number field
--------------------------------------------+--------------------------
       Reporter:  mbell                     |        Owner:
           Type:  defect                    |       Status:  needs_work
       Priority:  major                     |    Milestone:  sage-7.3
      Component:  number theory             |   Resolution:
       Keywords:  Polyhedron, Number field  |    Merged in:
        Authors:                            |    Reviewers:
Report Upstream:  N/A                       |  Work issues:
         Branch:                            |       Commit:
   Dependencies:                            |     Stopgaps:
--------------------------------------------+--------------------------
Description changed by vdelecroix:

Old description:

> I reported this to the google group
> (https://groups.google.com/forum/#!topic/sage-support/ew0bnGzjm98) but
> was told to repeat it here.
>
> To create polyhedra quickly, the final suggestion in the Polyhedron
> documentation
> (http://www.sagemath.org/doc/reference/geometry/sage/geometry/polyhedron/constructor.html
> #base-rings) is to work in a set number field. Although this appears to
> work for setting vertices, it does not appear to work for lines (or
> rays).
>
> For example:
> {{{
> sage: var('x')
> x
> sage: K.<sqrt3> = NumberField(x^2-3, embedding=1.732)
> sage: P = Polyhedron(lines=[(1,sqrt3)])
> sage: P
> A 1-dimensional polyhedron in (Number Field in sqrt3 with defining
> polynomial x^10 + x^2 - 3)^2 defined as the convex hull of 1 vertex and 2
> rays
> sage: P.rays()
> (A ray in the direction (0, -sqrt3), A ray in the direction (1, sqrt3))
> }}}
>
> This should be compared with:
> {{{
> sage: P = Polyhedron(lines=[(1, sqrt(3))])
> sage: P
> A 1-dimensional polyhedron in (Symbolic Ring)^2 defined as the convex
> hull of 1 vertex and 1 line
> }}}
> and
> {{{
> sage: P = Polyhedron(lines=[(1, sqrt(3))], base_ring=AA)
> sage: P
> A 1-dimensional polyhedron in AA^2 defined as the convex hull of 1 vertex
> and 1 line
> }}}
>

> Additionally, how can a "1-dimensional polyhedron" be "defined as the
> convex hull of 1 vertex and 2 rays"?
>
> --------------------------------------------
>
> As pointed out below this is an issue with Polyhedron using a number
> fields < comparison
> {{{
> sage: K.<x> = NumberField(x^3 - 1001, embedding=10)
> sage: x > x + 1
> True
> }}}

New description:

 As reported in this google group (https://groups.google.com/forum/#!topic
 /sage-support/ew0bnGzjm98), it was not possible to create Polyhedron
 defined over number fields. Now that #17830 is merged it does work and it
 should be documented and even advertised in the documentation!

 ---------
 from the previous report:

 To create polyhedra quickly, the final suggestion in the Polyhedron
 documentation
 
(http://www.sagemath.org/doc/reference/geometry/sage/geometry/polyhedron/constructor.html
 #base-rings) is to work in a set number field. Although this appears to
 work for setting vertices, it does not appear to work for lines (or rays).

 For example:
 {{{
 sage: var('x')
 x
 sage: K.<sqrt3> = NumberField(x^2-3, embedding=1.732)
 sage: P = Polyhedron(lines=[(1,sqrt3)])
 sage: P
 A 1-dimensional polyhedron in (Number Field in sqrt3 with defining
 polynomial x^10 + x^2 - 3)^2 defined as the convex hull of 1 vertex and 2
 rays
 sage: P.rays()
 (A ray in the direction (0, -sqrt3), A ray in the direction (1, sqrt3))
 }}}

 This should be compared with:
 {{{
 sage: P = Polyhedron(lines=[(1, sqrt(3))])
 sage: P
 A 1-dimensional polyhedron in (Symbolic Ring)^2 defined as the convex hull
 of 1 vertex and 1 line
 }}}
 and
 {{{
 sage: P = Polyhedron(lines=[(1, sqrt(3))], base_ring=AA)
 sage: P
 A 1-dimensional polyhedron in AA^2 defined as the convex hull of 1 vertex
 and 1 line
 }}}


 Additionally, how can a "1-dimensional polyhedron" be "defined as the
 convex hull of 1 vertex and 2 rays"?

 As pointed out below this is an issue with Polyhedron using a number
 fields < comparison
 {{{
 sage: K.<x> = NumberField(x^3 - 1001, embedding=10)
 sage: x > x + 1
 True
 }}}

--

--
Ticket URL: <https://trac.sagemath.org/ticket/17197#comment:10>
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 https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to