use application 'ideal'; use vars '$simpl', '$lambda_simpl', '$F_simpl', '$T_simpl', '$F_sqr', '$sqr', '$lambda_sqr', '$T_sqr', '$hex', '$lambda_hex', '$F_hex', '$T_hex', '$lambda_hex_new', '$lambda_hex_new_2', '$n'; script("./random_solve.script"); $n = 500000; ##### Simplex ##### $simpl = new Matrix([ [1, 0, 0], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 0, 1], [1, 1, 1], [1, 2, 1], [1, 0, 2], [1, 1, 2], [1, 0, 3] ]); $lambda_simpl = new Vector([12, 8, 9, 15, 3, 1, 5, 0, 0, 0]); $F_simpl = polytope::regular_subdivision($simpl, $lambda_simpl); $T_simpl = new topaz::GeometricSimplicialComplex(COORDINATES=>$simpl->minor(All,~[0]), FACETS=>$F_simpl); solve_random_wronski($simpl,$lambda_simpl,$n,{file=>'simplex.csv', triangulation=>$T_simpl}); ##### Square ##### $sqr = new Matrix([ [1, 0, 0], [1, 1, 0], [1, 2, 0], [1, 0, 1], [1, 1, 1], [1, 2, 1], [1, 0, 2], [1, 1, 2], [1, 2, 2] ]); $lambda_sqr = new Vector([5, 4, 9, 4, 0, 3, 9, 3, 3]); $F_sqr = polytope::regular_subdivision($sqr, $lambda_sqr); $T_sqr = new topaz::GeometricSimplicialComplex(COORDINATES=>$sqr->minor(All,~[0]), FACETS=>$F_sqr); solve_random_wronski($sqr,$lambda_sqr,$n,{file=>'square.csv', triangulation=>$T_sqr}); ##### Hexagon ##### $hex = new Matrix([[1,0,0],[1,1,0],[1,2,1],[1,2,2],[1,1,2],[1,0,1],[1,1,1]]); $lambda_hex = new Vector([3,1,1,3,1,1,0]); $lambda_hex_new = new Vector([10,1,1,10,1,1,0]); $lambda_hex_new_2 = new Vector([1000,10,0,0,0,100,1]); $F_hex = polytope::regular_subdivision($hex, $lambda_hex); $T_hex = new topaz::GeometricSimplicialComplex(COORDINATES=>$hex->minor(All,~[0]), FACETS=>$F_hex); solve_random_wronski($hex,$lambda_hex,$n,{file=>'hex.csv', triangulation=>$T_hex}); solve_random_wronski($hex,$lambda_hex_new,$n,{file=>'hex_otherlifting.csv', triangulation=>$T_hex}); solve_random_wronski($hex,$lambda_hex_new_2,$n,{file=>'hex_otherlifting_2.csv', triangulation=>$T_hex});