Hi Nicolas, You are talking about lattice polytopes, right? There are three different representations:
* The LatticePolytope class, which is mostly geared towards reflexive polytopes in small dimensions. It uses a pexpect interface with PALP. It also has some compile-time limits with number of points and dimension that make it unsuitable for arbitrary lattice polytopes. * The PPL-based polytopes over ZZ: Polyhedron([[1,0],[0,1],[0,0]], base_ring=ZZ). I think this should be eventually the default lattice polytope class, but it lacks some functionality specific to lattice polytopes. And its not backwards compatible with LatticePolytope since the latter interface isn't particularly nice in some cases. * The LatticePolytope_PPL class that is not public and currently only in http://trac.sagemath.org/12553. Its rather bare-bones but designed to be fast enough to be able to iterate through all 4d reflexive polytopes (~500 million). I've been using it for internal computations for a while now. So my suggestion would be to base your stuff on Polyhedron() whether or not your have lattice polytopes. If you need any particular functionality thats not available then let me know. On Monday, February 18, 2013 1:58:53 PM UTC, Nicolas M. Thiery wrote: > > Hi Volker, > > I am building pictures (for representing root systems) having > typically 1000 small polyhedrons of small dimension (2). It's very > nice to be able to express my problem at this level! However, a lot of > time seems to be spent in communications: > > sage: %prun RootSystem(["G",2,1]).coambient_space().plot(bounding_box=3) > 11585493 function calls (11505945 primitive calls) in 95.937 > seconds > > Ordered by: internal time > > ncalls tottime percall cumtime percall filename:lineno(function) > 9756 36.522 0.004 36.522 0.004 {posix.read} > 3252 21.061 0.006 21.061 0.006 {posix.fork} > 53198 7.324 0.000 13.506 0.000 weakref.py:55(__getitem__) > 3887440 6.768 0.000 7.237 0.000 face.py:235(__cmp__) > 13433 2.890 0.000 2.890 0.000 {built-in method poll} > 8657 1.886 0.000 3.290 0.000 weakref.py:79(__setitem__) > > Is this to be expected (i.e. should I try to use less polyhedrons)? > Would you have recommendations? Things are roughly 3 times faster with > the ppl backend, but at this point I can't always have data in QQ. > > I can push my code to the sage-combinat queue tomorrow in case you > would like to experiment with it. > > Thanks! > > Cheers, > Nicolas > -- > Nicolas M. Thi�ry "Isil" <nth...@users.sf.net <javascript:>> > http://Nicolas.Thiery.name/ > -- You received this message because you are subscribed to the Google Groups "sage-combinat-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-combinat-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-combinat-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-combinat-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.