Re: [sage-combinat-devel] Question about LatticePolytopeClass

2010-07-09 Thread Nicolas M. Thiery
Hi Johannes,

On Fri, Jul 09, 2010 at 03:11:39PM +0200, Johannes wrote:
> im just playing around with sage and LatticePolytopes and im wondering
> why theres no __eq__ implementet for them.
> if i have this code:
> s1 = LatteciPolytope(matrix([[1,0,-1],[0,1,-1]])
> s2 = LatteciPolytope(matrix([[1,0,-1],[0,1,-1]])
> 
> then s1 == s2 evals to false.
> thats right in the sentence of ref-equality but in my eyes two polytopes
> are equal, if they live in the same space (in this case, on the same
> Lattice) and have the same edges.
> Is there any reason, why its not implemented that way?

I am forwarding this to the author, Andrey, since I don't remember if
he is on sage-combinat-devel.

By the way, Andrey, would you consider that the elements of a
LatticePolytope are its integer points? If yes, could you add aliases:

 - cardinality -> npoints
 - points -> list

for consistency with other FiniteEnumeratedSets? (and it would be even
better if LatticePolytope was in that category).

Should I open a ticket about this?

Cheers,
Nicolas
--
Nicolas M. ThiƩry "Isil" 
http://Nicolas.Thiery.name/

-- 
You received this message because you are subscribed to the Google Groups 
"sage-combinat-devel" group.
To post to this group, send email to sage-combinat-de...@googlegroups.com.
To unsubscribe from this group, send email to 
sage-combinat-devel+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sage-combinat-devel?hl=en.



[sage-combinat-devel] Question about LatticePolytopeClass

2010-07-09 Thread Johannes
Hi list,
im just playing around with sage and LatticePolytopes and im wondering
why theres no __eq__ implementet for them.
if i have this code:
s1 = LatteciPolytope(matrix([[1,0,-1],[0,1,-1]])
s2 = LatteciPolytope(matrix([[1,0,-1],[0,1,-1]])

then s1 == s2 evals to false.
thats right in the sentence of ref-equality but in my eyes two polytopes
are equal, if they live in the same space (in this case, on the same
Lattice) and have the same edges.
Is there any reason, why its not implemented that way?

greatz Johannes

-- 
You received this message because you are subscribed to the Google Groups 
"sage-combinat-devel" group.
To post to this group, send email to sage-combinat-de...@googlegroups.com.
To unsubscribe from this group, send email to 
sage-combinat-devel+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sage-combinat-devel?hl=en.