Skip to content

Commit

Permalink
Use init argument in Product
Browse files Browse the repository at this point in the history
Fixes #8.
  • Loading branch information
Alexander Konovalov authored and alex-konovalov committed Sep 13, 2018
1 parent 3af435e commit e46f698
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/tuple.gi
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ InstallGlobalFunction(RandomGeneratingTuple,function(group, tuple, OurG, OurR)
local i, k, t, product, c;
while true do
t:=List([1..2*OurG], x-> Random(group));
product:=Product(List([1..OurG], x->Comm(t[x], t[OurG+x])));
product:=Product(List([1..OurG], x->Comm(t[x], t[OurG+x])),One(group));
if OurR=0 then
if product=One(group) then
return rec(tuple:=t, subgroupNumber:=1);
Expand All @@ -98,7 +98,6 @@ InstallGlobalFunction(RandomGeneratingTuple,function(group, tuple, OurG, OurR)
if Size(Subgroup(group,t))= Size(group) then
return rec(tuple:=t, subgroupNumber:=1);
fi;

fi;
fi;
od;
Expand Down

0 comments on commit e46f698

Please sign in to comment.