Page 1 of 2

Secondary Fans using gfan

Posted: 18 Mar 2012, 19:52
by simon
Hello,

I'm trying to compute the secondary fan of a vector configuration as described e.g. in

http://www.polymake.org/doku.php/news/release_2_10

I have both polymake 2.11 and gfan 0.5 installed.
However, my installation of polymake does not know about a function "secondary_fan".

Maybe I have to tell polymake first about gfan?

Thanks in advance!

Re: Secondary Fans using gfan

Posted: 27 Mar 2012, 09:53
by joswig
You may have to do

Code: Select all

reconfigure "gfan.rules";
in application fan.

Re: Secondary Fans using gfan

Posted: 27 Mar 2012, 12:19
by simon
ah sure! Thanks!

Re: Secondary Fans using gfan

Posted: 01 Dec 2012, 00:55
by esche
Hi!

I have the same problem here. I use polymake 2.12 and gfan 0.5 in Mac OS X 10.6. The subroutine secondary_fan is undefined and I get the error message

Code: Select all

polytope > reconfigure "gfan.rules"; polymake: ERROR: there are no configuration actions associated with rulefile gfan.rules
Do you have some advice ? Thanks in advance.

esche

Re: Secondary Fans using gfan

Posted: 01 Dec 2012, 13:46
by blorenz
The gfan rules are within application fan and therefore you need to switch to that application before reconfiguring or using the secondary_fan function:

Code: Select all

application "fan"; reconfigure "gfan.rules"; $f = secondary_fan($m);
Ben

Re: Secondary Fans using gfan

Posted: 02 Dec 2012, 13:57
by esche
Thanks a lot for the quick reply. Now, I have the next problem:

Code: Select all

$ptmat = new Matrix<Integer>([[1,0,0,0,0],[1,2,-1,-1,-1],[1,-1,2,-1,-1],[1,-1,-1,-1,-1],[1,0,0,1,0],[1,0,0,0,1]]); $P = new Polytope<Rational>(POINTS=>$ptmat); $Sigma = fan::secondary_fan($P->VERTICES); polymake: transforming /private/var/folders/NQ/NQnbaTxVHAecd8YXcj+MPE+++TI/-Tmp-/poly2028Taaaa0001.poly with upgrade-2.9.10.xslt polymake: transforming /private/var/folders/NQ/NQnbaTxVHAecd8YXcj+MPE+++TI/-Tmp-/poly2028Taaaa0001.poly with upgrade-2.10.xslt polymake: transforming /private/var/folders/NQ/NQnbaTxVHAecd8YXcj+MPE+++TI/-Tmp-/poly2028Taaaa0001.poly with upgrade-2.11.xslt polymake: transforming /private/var/folders/NQ/NQnbaTxVHAecd8YXcj+MPE+++TI/-Tmp-/poly2028Taaaa0001.poly with upgrade-2.12.xslt polymake: WARNING: encountered unknown property 'AMBIENT_DIM' in object SymmetricFan<Rational> Please be aware that all unknown properties are automatically removed from the data files. If you want to supply additional information with the objects, please use attachments or declare new properties in extension rules. polymake: WARNING: Creating backup file /private/var/folders/NQ/NQnbaTxVHAecd8YXcj+MPE+++TI/-Tmp-/poly2028Taaaa0001.poly.bak polymake: WARNING: encountered unknown property 'DIM' in object SymmetricFan<Rational>
Can you give me a hint what I am supposed to do here ?

esche

Re: Secondary Fans using gfan

Posted: 03 Dec 2012, 11:59
by joswig
Can you give me a hint what I am supposed to do here ?
Nothing.

polymake transformed your files into a new format. On the way it trashed the properties DIM and AMBIENT_DIM which became user functions. That's why you got a warning (but no error). No information lost in your data.

Re: Secondary Fans using gfan

Posted: 03 Dec 2012, 22:17
by esche
I see. Then how do I get the 1-dimensional cones ? Or the maximal cones ? I seem to get an empty result which I know not to be true.

Code: Select all

print $Sigma->MAXIMAL_CONES; {}
esche

Re: Secondary Fans using gfan

Posted: 06 Dec 2012, 12:24
by joswig
OK, there is a bug in apps/fan/rules/gfan.rules.

Please replace the line 41 by

Code: Select all

gfan_print_matrix($tempfile,eliminate_denominators_entire_affine($M->minor(All,[1..$M->cols()-1])));
Sorry for the inconvenience.

Re: Secondary Fans using gfan

Posted: 06 Dec 2012, 23:21
by esche
Thanks. Now I'm getting the following error message

Code: Select all

fan > $Sigma = fan::secondary_fan($P->VERTICES); polymake: used package gfan Gfan is a software package for computing Groebner fans and tropical varieties. Copyright by Anders Jensen http://www.math.tu-berlin.de/~jensen/software/gfan/gfan.html polymake: Creating tree /Users/esche/.polymake-macbundle/wrappers/core for automatically generated private C++/perl wrappers polymake: ERROR: Undefined subroutine &Polymake::fan::eliminate_denominators_entire_affine called at /Applications/polymake.app/Contents/MacOS/../Resources//polymake/share/polymake/apps/fan/rules/gfan.rules line 41.
esche