[GAP Forum] Permutizer Condition

Dima Pasechnik dima at pasechnik.info
Wed Jul 14 22:38:40 BST 2021


Hello,
On Wed, Jul 14, 2021 at 04:29:44PM +0000, lopo apelo kosho wrote:
> I am writing a GAP code to check on the normalizer condition. Recall that a finite group G satisfies the  normalizer condition iff for each proper subgroup H of G H is Proper in its normalizer. 
> I have constructed the following code: 
> 
> #################
>  IsNormalizerGroup:=function(g) local s,i;
> > if IsAbelian(g) then return true;
> > fi;
> > if IsPGroup(g) then return true;
> > fi;
> > s:=Difference(Subgroups(g),[g]);
> > for i in [1..Size(g)] do
> return false;
> > if Order(Normalizer(g,s[i]))=Order(s[i]) then
> > return false;
> > fi;
> > od;
> > return true;
> > end;
> function( g ) ... end
> #################
> but when I checked for the direct product group D:= C3X Q8
> I get the following error: 
> 
> 
> Error, List Element: <list>[20] must have an assigned value in
>   if Order( Normalizer( g, s[i] ) ) = Order( s[i] ) then
>     return false;
> fi; at *stdin*:2805 called from
> <function "IsD3Group">( <arguments> )
>  called from read-eval loop at *stdin*:2809
> you can 'return;' after assigning a value
> ################################################
> 
> I still do not know how to fix it

The problem is that i should range in [1..Size(s)]
and not in [1..Size(g)]

Actually, even better, you can write 

  for i in s do
    if Order(Normalizer(g,i))=Order(i) then
    ....

which is avoiding the unnecessaru here indexing.
     
How this helps,
Dima



More information about the Forum mailing list