I need a $3$-group of nilpotency class $3$ with $3$ generators, but I can't find any group meeting these criteria. Does such a group exist?
I've already used GAP-System as far as my PC can handle, and I came up with nothing. I tried a small group of order $3^n,n\in\{1,2,3,4,5,6,7,8,9,10\}$. I tried this code in GAP:
for n in [1..10] do
for j in [1..NrSmallGroups(3^n)] do
G:=SmallGroup(3^n,j);
if NilpotencyClassOfGroup(G)=3 then
if Length(GeneratorsOfGroup(G))=3 then
Print(n,", ",j,"\n");
fi;
fi;
od;
od;
I think the issue is your formulation and test of "with three generators". Presumably you mean that the group can be generated by 3 elements (but not by 2). Of course you could generate such a group with more elements. The generating set stored by GAP and returned by
GeneratorsOfGroupis for solvable groups a polycyclic generating set, which for a group of order $p^n$ has always $n$ generators. Thus your test eliminates all groups.If you replace
Length(GeneratorsOfGroup(G))byLength(MinimalGeneratingSet(G))you will find the groups you're interested in (starting in order $3^5$ as noted by Alexander Konovalov above.)