University of Paderborn Department of Mathematics Diploma Thesis ...
University of Paderborn Department of Mathematics Diploma Thesis ...
University of Paderborn Department of Mathematics Diploma Thesis ...
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
96 CHAPTER 4. ALGORITHMS FOR STABLE IDEALSOutput <strong>of</strong> the procedure test contractible.◦ TRUE or FALSE — TRUE, if the monomial m is contractible in the ideal generated byM, and FALSE, otherwisetest_contractible:= proc(M, m, n)local LeftShift, mon, mon1, mon2, last, pos,contractible, cnt, i, j, k;begin/* If m is contained in M return FALSE(i.e. the monomial is not contractible) */if contains(M, m) > 0 thenreturn(FALSE);end_if;/* Compute the index <strong>of</strong> the last variable <strong>of</strong> mand the left-shift <strong>of</strong> m */for i from n+1 downto 0 doif m[i] 0 thenlast:= i;break;end_if;end_for;/* If m multiplied by its last variable is notcontained in M, then also return FALSE */mon:= m;mon[last]:= mon[last] + 1;pos:= contains(M, mon);if pos = 0 thenreturn(FALSE);end_if;/* Compute the left-shift <strong>of</strong> m and check whetherit is contained in the ideal */LeftShift:= {};for i from last downto 2 doif m[i] > 0 then