// This script removes duplicate // lattices from 1115out.txt // Lattices that appear in 1115out.txt but not in // e4.txt are written to 1115red.txt load "e4.txt"; load "1115out.txt"; PrintFile("1115red.txt","switch1red := ["); newforms := 0; for m in [1..#switch1] do found := false; for n in [1..#e4] do if Determinant(2*switch1[m]) eq Determinant(2*e4[n]) then L1 := LatticeWithGram(2*switch1[m]); L2 := LatticeWithGram(2*e4[n]); if IsIsometric(L1,L2) then found := true; end if; end if; end for; if found eq false then newforms := newforms + 1; if newforms gt 1 then PrintFile("1115red.txt",","); end if; printf "Lattice %o is new.\n",m; PrintFile("1115red.txt","Matrix(4,4,"); PrintFile("1115red.txt",ElementToSequence(switch1[m])); PrintFile("1115red.txt",")"); end if; if found eq true then printf "Lattice %o is old.\n",m; end if; end for; PrintFile("1115red.txt","];"); printf "A total of %o new forms were found.\n",newforms;