Search found 181 matches

Go to advanced search

12 Jan 2022, 12:04
Forum: General Discussion
Topic: Convex Decomposition
Replies: 5
Views: 142

Re: Convex Decomposition

That does not have unique solutions. Instead the set of such solutions forms a polyhedron in the parameter space (= coefficients of the linear combinations).
12 Jan 2022, 09:30
Forum: General Discussion
Topic: Convex Decomposition
Replies: 5
Views: 142

Re: Convex Decomposition

Sorry, I don't understand the question.

Is it that P_2 is a subpolytope of P_1, and you want to find those vcertices of P_1 which are not vertices of P_2?
25 Oct 2021, 17:44
Forum: Helpdesk
Topic: Saving Polytope Vertices to CSV or TXT
Replies: 1
Views: 222

Your command sequence > $p = cube(3); > print($p->VERTICES); > save_data($p->VERTICES, "my_vertices.txt"); is perfectly OK; the result is a JSON file (format defined by polymake) which contains just one matrix plus a bit of metadata. If you want the matrix (coefficients separated by blanks) directly... 28 Sep 2021, 10:23 Forum: General Discussion Topic: how to define integer polytope by matrix representation Replies: 6 Views: 899 Re: how to define integer polytope by matrix representation Your example has a lineality space of positive dimension. polytope >$p = new Polytope(INEQUALITIES=>[[13,-6,0,-7,0,-9,0],[11,0,-8,0,-5,0,-6]],EQUATIONS=>[[-1,1,1,0,0,0,0],[-1,0,0,1,1,0,0],[-1,0,0,0,0,1,1]]); polytope > print $p->VERTICES; 1 -1/4 5/4 1 0 5/6 1/6 0 1 -1 0 0 -2/3 2/3 0 1 -1 0 0 -4/3 4... 27 Sep 2021, 10:13 Forum: General Discussion Topic: how to define integer polytope by matrix representation Replies: 6 Views: 899 Re: how to define integer polytope by matrix representation You can specify polyhedra in terms of INEQUALITIES and EQUATIONS. Asking for VERTICES then triggers a dual convex hull computation. Please see tutorial. The web version of polymake runs in a sandbox. So, by design, you cannot read from or write to files. 20 Aug 2021, 12:59 Forum: General Discussion Topic: Mixed volume -> edge matrix is singular? Replies: 4 Views: 5188 Re: Mixed volume -> edge matrix is singular? polymake uses the normalized volume convention for mixed volumes (i.e., counting solutions of polynomial systems directly, as in the BKK theorem). You can see this, e.g., from polytope > print mixed_volume(cube(2,0),cube(2,0)); 2 The mixed volume of a polygon with itself equals the volume (i.e., are... 09 Aug 2021, 09:45 Forum: Helpdesk Topic: how to avoid ERROR: No random access Replies: 5 Views: 3617 Re: how to avoid ERROR: No random access Well, Vector and Array are random access data structures, i.e., you can use indices. And Set is not random access; pretty much as the error message says. These different data structures exist because they help make several kinds of functions fast: While vector and Array allow to access an element at... 31 Jul 2021, 18:44 Forum: Helpdesk Topic: Label the ground set of a matroid from 1 to n Replies: 3 Views: 3048 Re: Label the ground set of a matroid from 1 to n Internally, polymake will always use indices starting at zero. matroid >$F = fano_matroid; matroid > print $F->CIRCUITS; {0 1 6} {0 2 5} {0 3 4} {1 2 3} {1 4 5} {2 4 6} {3 5 6} {0 1 2 4} {0 1 3 5} {0 2 3 6} {0 4 5 6} {1 2 5 6} {1 3 4 6} {2 3 4 5} But you can use LABELS to make things look different... 31 Jul 2021, 18:36 Forum: Helpdesk Topic: how to use polymake other than command line? Replies: 2 Views: 2975 Re: how to use polymake other than command line? Yes to both questions. Even the command line provide full perl functionality. > sub myowncode($) { my ($arg)=@_; return cube($arg)->VOLUME; } > print myowncode(4); 16 Then you can store a sequence of commands as a text file and apply load_commands to execute that code line by line. For best experien...
27 Jul 2021, 12:19
Forum: Helpdesk
Topic: Checking if two fans have the same support
Replies: 3
Views: 4688

Re: Checking if two fans have the same support

Indeed, currently polymake does not have such a function. Of course, it is absolutely desirable. We started to discuss the matter within the developer's team. There are several ways to implement this, all of which are computationally costly, except for small fans in very low dimensions. We are in th...

Go to advanced search