Polyhedron.radius() bug?

Showing 1-5 of 5 messages
Polyhedron.radius() bug? rickhg12hs 2/10/12 5:27 AM
      "Return the maximal distance from the center to a vertex."

Shouldn't this be translation invariant?  Doesn't seem like any of
these are answers right.


sage: sq=polytopes.n_cube(2)
sage: sq.vertices()
[[1, 1], [-1, 1], [1, -1], [-1, -1]]

sage: sq.radius()
2*sqrt(2)

sage: Polyhedron([[p0+1,p1] for p0,p1 in sq.vertices()]).radius()
2*sqrt(3)
sage: Polyhedron([[p0+10,p1] for p0,p1 in sq.vertices()]).radius()
2*sqrt(102)
Re: Polyhedron.radius() bug? Keshav Kini 2/10/12 6:52 AM
That looks obviously broken to me. I'll write a patch.

-Keshav

----
Join us in #sagemath on irc.freenode.net !
Re: [sage-support] Polyhedron.radius() bug? Anton Sherwood 2/10/12 9:06 AM
On 2012-2-10 05:27, rickhg12hs wrote:
>         "Return the maximal distance from the center to a vertex."
>
> Shouldn't this be translation invariant?

Could 'center' here mean 'origin'?  It's not obviously unreasonable to
assume that a polyhedron is defined so that they coincide.

--
Anton Sherwood *\\* www.bendwavy.org *\\* www.zazzle.com/tamfang

Re: [sage-support] Polyhedron.radius() bug? Keshav Kini 2/10/12 10:35 AM

Seems unlikely to me. The output does not match this theory either.

-keshav

achtung: sent from phone, possibly unduly terse

-- To post to this group, send email to sage-s...@googlegroups.com To unsubscribe from this gr...

Re: Polyhedron.radius() bug? Keshav Kini 2/11/12 1:37 AM
Fixed this issue at http://trac.sagemath.org/sage_trac/ticket/12492 . Thanks for reporting this bug, rickhg12hs!