Just compute the points and take their convex hull together with a ray in 
the "up" direction:

sage: R.<x> = ZZ[]
sage: p = sum( x^i for i in range(10) )

sage: points = [ (e, randint(0,10)) for e in p.exponents() ]   # replace 
with whatever y-coordinate you want

sage: q = Polyhedron(vertices=points, rays=[(0,1)])
sage: q
A 2-dimensional polyhedron in ZZ^2 defined as the convex hull of 4 vertices 
and 1 ray
(A ray in the direction (0, 1), A vertex at (0, 8), A vertex at (9, 6), A 
vertex at (2, 2), A vertex at (7, 3))



On Wednesday, October 17, 2012 8:17:27 PM UTC+1, projetmbc wrote:
>
> Hello,
> I would like to draw a kind of "inverse" Newton polygon for points.
>
> How can I achieve this ?
>
> Christophe
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
Visit this group at http://groups.google.com/group/sage-support?hl=en.


Reply via email to