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,0,0,0,0,1,0, 0,0,0,0,0,0,0,0,1],
[1,0,0,0,0,0,0,0,0, 0,1,0,0,0,0,0,0,0, 0,0,1,0,0,0,0,0,0, 0,0,0,0,1,0,0,0,0, 0,0,0,1,0,0,0,0,0, 0,0,0,0,0,1,0,0,0, 0,0,0,0,0,0,1,0,0, 0,0,0,0,0,0,0,1,0, 0,0,0,0,0,0,0,0,1],
[2,1,1,1,0,0,0,0,0, -1,0,-1,-1,0,0,0,0,0, -1,-1,0,-1,0,0,0,0,0, -1,-1,-1,0,0,0,0,0,0, 0,0,0,0,1,0,0,0,0, 0,0,0,0,0,1,0,0,0, 0,0,0,0,0,0,1,0,0, 0,0,0,0,0,0,0,1,0, 0,0,0,0,0,0,0,0,1],
[1,0,0,0,0,0,0,0,0, 0,1,0,0,0,0,0,0,0, 0,0,1,0,0,0,0,0,0, 0,0,0,1,0,0,0,0,0, 0,0,0,0,0,1,0,0,0, 0,0,0,0,1,0,0,0,0, 0,0,0,0,0,0,1,0,0, 0,0,0,0,0,0,0,1,0, 0,0,0,0,0,0,0,0,1]>;

Supporting functions

//Transpose Group

TransGroup:=function(G)
local R,d;
R:=CoefficientRing(G);
d:=Degree(G);
H:=MatrixGroup<d,R|{Transpose(G.k):k in [1..#Generators(G)]}>;
return H;
end function;


//add_block is the support function to modify the cocycle


add_block:=procedure(~M,i,j,M2)
local rows,cols,block;
rows:=NumberOfRows(M2);
cols:=NumberOfColumns(M2);
block:=ExtractBlock(M,i,j,rows,cols);
InsertBlock(~M,block+M2,i,j);
end procedure;
//the function returns the intersection matrix
IsConic:=function(h,H)
local Matrix;
Matrix:=RMatrixSpace(IntegerRing(),#H[h],#H[h])!0;
for i in [1..#H[h]] do
        for j in [1..#H[h]] do
                product:=0;
                for t in [1..9] do
                        if t eq 1 then
                                product:=product+H[h][i][t]*H[h][j][t];
                        else
                                product:=product-H[h][i][t]*H[h][j][t];
                        end if;
                end for;
                Matrix[i,j]:=product;
        end for;
end for;
return Matrix;
end function;
//intersection matrix of 2 orbits
Inter2Orbit:=function(m,n,H)
local Matrix;
Matrix:=RMatrixSpace(IntegerRing(),#H[m],#H[n])!0;
for i in [1..#H[m]] do
        for j in [1..#H[n]] do
                product:=0;
                for t in [1..9] do
                        if t eq 1 then
                                product:=product+H[m][i][t]*H[n][j][t];
                        else
                                product:=product-H[m][i][t]*H[n][j][t];
                        end if;
                end for;
                Matrix[i,j]:=product;
        end for;
end for;
return Matrix;
end function;

Computing H1


//C0Matrix computes the coboundary.
C0Matrix:=function(M)
local l;
l:=IdentityMatrix(BaseRing(M),Dimension(M));
return HorizontalJoin([Transpose(ActionGenerator(M,k))-l:k in [1..Nagens(M)]]);
end function;

//C1Matrix computes the cocycle.

C1Matrix:=function(M)
local K,d,G,RG,r,s,rel,w,C1,g,si,sg;
K:=BaseRing(M);
d:=Dimension(M);
G:=Group(M);
RG:=Relations(FPGroup(G));
r:=#Generators(G);
s:=#RG;
C1:=RMatrixSpace(K,r*d,s*d)!0;
for i in [1..s] do
rel:=RG[i];
w:=LHS(rel)*RHS(rel)^(-1);
si:=(i-1)*d+1;
        for g in [1..r] do
                sg :=(Abs(g)-1)*d+1;
                if Abs(Eltseq(w)[1]) eq g then
                        if Eltseq(w)[1] gt 0 then
                                mattemp:=IdentityMatrix(K,d);
                                add_block(~C1,sg,si,Transpose(mattemp));
                        end if;
                        if Eltseq(w)[1] lt 0 then
                                mattemp:=(-1)*ActionGenerator(M,-Eltseq(w)[1])^(-1);
                                add_block(~C1,sg,si,Transpose(mattemp));
                        end if;
                end if;
                        for h in [2..#w] do
                                if Abs(Eltseq(w)[h]) eq g then
                                        mattemp:=IdentityMatrix(K,d);
                                for t in [1..h-1] do
                                        mattemp:=mattemp*ActionGenerator(M,Abs(Eltseq(w)[t]))^(Sign(Eltseq(w)[t]));
                                end for;
                                if Eltseq(w)[h] lt 0 then
                                        mattemp:=mattemp*(-1)*ActionGenerator(M,-Eltseq(w)[h])^(-1);
                                end if;
                                add_block(~C1,sg,si,Transpose(mattemp));
                        end if;
                end for;
        end for;
end for;
return C1;
end function;

Minimality check

IsMinimal:=function(G,Exceptional)
H:={};
for i in [1..#Exceptional] do
        Include(~H,SetToIndexedSet(Orbit(TransGroup(G),Exceptional[i])));
end for;
H:=SetToIndexedSet(H);
for i in [1..#H] do
        if #H[i] eq 1 then
                return false;
        end if;
end for;
for r in [1..#H] do
        Matrix:=RMatrixSpace(IntegerRing(),#H[r],#H[r])!0;
        for j in [1..#H[r]] do
                for k in [1..#H[r]] do
                        product:=0;
                        for t in [1..9] do
                                if t eq 1 then
                                        product:=product+H[r][j][t]*H[r][k][t];
                                else
                                        product:=product-H[r][j][t]*H[r][k][t];
                                end if;
                        end for;
                        Matrix[j,k]:=product;
                end for;
        end for;
        Matrix:=Matrix+IdentityMatrix(IntegerRing(),#H[r]);
        if IsZero(Matrix) eq true then
                return false;
        end if;
end for;
return true;
end function;

Finding H1-trivial minimal surfaces

D5

//Get Exceptional curve set
Mod:=GModule(GroupE5);
u:=Mod![0,1,0,0,0,0,0,0,0];
Exceptional:=Orbit(TransGroup(GroupE5),u);
Exceptional:=SetToIndexedSet(Exceptional);


//find minimal group with every subgroup having trivial H1

ListE5:=Subgroups(GroupE5);
//Want is the set of the index of the subgroups that we want.
Want:={};

Total:={@ Integers() | x : x in [2..#ListE5] @};
Del:={};
for i in [2..#ListE5] do
        i;
        if i in Del eq false then
                List:=Subgroups(ListE5[i]`subgroup);
                Sum:=0;
                for j in [2..#List] do
                        M:=GModule(List[j]`subgroup);
                        C0:=C0Matrix(M);
                        C1:=C1Matrix(M);
                        H1:=quo<Nullspace(C1)|RowSpace(C0)>;
                        Sum:=Sum+#H1;
                end for;
                if Sum ne #List-1 then
                        Include(~Del,i);
                        for j in [2..#ListE5] do
                                if j in Del eq false then
                                        if ListE5[i]`subgroup subset ListE5[j]`subgroup then
                                                Include(~Del,j);
                                        end if;
                                end if;
                        end for;
                end if;
        end if;
end for;

Remain:=Total diff Del;
        
for i in [2..#Remain] do
        i;
        if IsMinimal(ListE5[Remain[i]]`subgroup,Exceptional) then
                Include(~Want,Remain[i]);
        end if;
end for;
Want;

E6

//Get Exceptional curve set
Mod:=GModule(GroupE6);
u:=Mod![0,1,0,0,0,0,0,0,0];
Exceptional:=Orbit(TransGroup(GroupE6),u);
Exceptional:=SetToIndexedSet(Exceptional);


//find minimal group with every subgroup having trivial H1

ListE6:=Subgroups(GroupE6);
//Want is the set of the index of the subgroups that we want.
Want:={};

Total:={@ Integers() | x : x in [2..#ListE6] @};
Del:={};
for i in [2..#ListE6] do
        i;
        if i in Del eq false then
                List:=Subgroups(ListE6[i]`subgroup);
                Sum:=0;
                for j in [2..#List] do
                        M:=GModule(List[j]`subgroup);
                        C0:=C0Matrix(M);
                        C1:=C1Matrix(M);
                        H1:=quo<Nullspace(C1)|RowSpace(C0)>;
                        Sum:=Sum+#H1;
                end for;
                if Sum ne #List-1 then
                        Include(~Del,i);
                        for j in [2..#ListE6] do
                                if j in Del eq false then
                                        if ListE6[i]`subgroup subset ListE6[j]`subgroup then
                                                Include(~Del,j);
                                        end if;
                                end if;
                        end for;
                end if;
        end if;
end for;

Remain:=Total diff Del;
        
for i in [2..#Remain] do
        i;
        if IsMinimal(ListE6[Remain[i]]`subgroup,Exceptional) then
                Include(~Want,Remain[i]);
        end if;
end for;
Want;

E7

//Get Exceptional curve set
Mod:=GModule(GroupE7);
u:=Mod![0,1,0,0,0,0,0,0,0];
Exceptional:=Orbit(TransGroup(GroupE7),u);
Exceptional:=SetToIndexedSet(Exceptional);


//find minimal group with every subgroup having trivial H1

ListE7:=Subgroups(GroupE7);
//Want is the set of the index of the subgroups that we want.
Want:={};

Total:={@ Integers() | x : x in [2..#ListE7] @};
Del:={};
for i in [2..#ListE7] do
        i;
        if i in Del eq false then
                List:=Subgroups(ListE7[i]`subgroup);
                Sum:=0;
                for j in [2..#List] do
                        M:=GModule(List[j]`subgroup);
                        C0:=C0Matrix(M);
                        C1:=C1Matrix(M);
                        H1:=quo<Nullspace(C1)|RowSpace(C0)>;
                        Sum:=Sum+#H1;
                end for;
                if Sum ne #List-1 then
                        Include(~Del,i);
                        for j in [2..#ListE7] do
                                if j in Del eq false then
                                        if ListE7[i]`subgroup subset ListE7[j]`subgroup then
                                                Include(~Del,j);
                                        end if;
                                end if;
                        end for;
                end if;
        end if;
end for;

Remain:=Total diff Del;
        
for i in [2..#Remain] do
        i;
        if IsMinimal(ListE7[Remain[i]]`subgroup,Exceptional) then
                Include(~Want,Remain[i]);
        end if;
end for;
Want;

E8


//Get Exceptional curve set
Mod:=GModule(GroupE8);
u:=Mod![0,1,0,0,0,0,0,0,0];
Exceptional:=Orbit(TransGroup(GroupE8),u);
Exceptional:=SetToIndexedSet(Exceptional);



//find minimal group with every subgroup having trivial H1(62092 conjugate classes of subgroups)

ListE8:=Subgroups(GroupE8);
//Want is the set of the index of the subgroups that we want.
Want:={};

Total:={@ Integers() | x : x in [2..#ListE8] @};
Del:={};
for i in [2..#ListE8] do
        i;
        if i in Del eq false then
                List:=Subgroups(ListE8[i]`subgroup);
                Sum:=0;
                for j in [2..#List] do
                        M:=GModule(List[j]`subgroup);
                        C0:=C0Matrix(M);
                        C1:=C1Matrix(M);
                        H1:=quo<Nullspace(C1)|RowSpace(C0)>;
                        Sum:=Sum+#H1;
                end for;
                if Sum ne #List-1 then
                        Include(~Del,i);
                        for j in [2..#ListE8] do
                                if j in Del eq false then
                                        if ListE8[i]`subgroup subset ListE8[j]`subgroup then
                                                Include(~Del,j);
                                        end if;
                                end if;
                        end for;
                end if;
        end if;
end for;

Remain:=Total diff Del;
        
for i in [2..#Remain] do
        i;
        if IsMinimal(ListE8[Remain[i]]`subgroup,Exceptional) then
                Include(~Want,Remain[i]);
        end if;
end for;
Want;