-- functions to compute the syzygy order of the equivariant cohomology -- of a big polygon space as module over H^*(BT;Q), see -- -- Matthias Franz -- Maximal syzygies in equivariant cohomology -- arXiv:1403.4485 -- -- written by Matthias Franz, 21/05/2014 -- compute the Auslander-Bridger dual of a module auslanderBridgerDual = M -> coker transpose presentation M -- compute the order of syzygy of a module (over a polynomial ring) syzygyOrderModule = M -> ( R := ring M; N := auslanderBridgerDual M; s := 0; for i from 1 to numgens R when Ext^i(N,R) == 0 do s = i; s ) -- compute the order of syzygy of H_T^*(X_{a,b}(ell);Q) over R = H^*(BT;Q) -- where X_{a,b}(ell) is a big polygon space with generic length vector ell syzygyOrder = ell -> ( ellAve := sum(ell)/2; r := length ell; ind := toList (0..r-1); alls := subsets ind; long := select(alls, j -> sum(ell_j) > ellAve); short := select(alls, j -> sum(ell_j) < ellAve); nlong := length long; if length short + nlong != length alls then error "length vector not generic"; allsHT := hashTable for k from 0 to (length alls)-1 list alls_k => k; longHT := hashTable for k from 0 to (length long)-1 list long_k => k; R := QQ[Variables => r, Degrees => toList(r:2)]; koszuldiff := j -> ( s := 1; for k in j list (allsHT#(delete(k,j)),nlong+longHT#j) => s*R_k do s = -s ); allsdeg := apply(alls, length); longdeg := apply(long, length); sourcedeg := longdeg | apply(longdeg, k -> k+1); mm1 := for j in long list (allsHT#j,longHT#j) => 1_R; mm2 := flatten for j in long list koszuldiff(j); f := map(R^(-allsdeg), R^(-sourcedeg), mm1|mm2); syzord := syzygyOrderModule coker f; -- coker f is always the smaller syzygy (by at least order 2) because -- of the exact sequence 0 -> ker f -> free -> free -> coker f -> 0 syzord ) -- some additional functions -- decide whether the subset J is long w.r.t. the length vector ell isLong = (J, ell) -> 2*sum(ell_J) > sum(ell) -- decide whether the subset J is short w.r.t. the length vector ell isShort = (J, ell) -> 2*sum(ell_J) < sum(ell) -- compute the list of all long subsets w.r.t. the length vector ell longSets = ell -> select(subsets(length ell), J -> isLong(J, ell)) -- compute the (rational) Betti sum of the space of polygons E_{2a}(ell) -- ell is assumed to be generic bettiSum = ell -> ( r = length ell; 4 * length select(longSets ell, J -> last(J) != r-1) )