This file is indexed.

/usr/share/gap/small/idgrp1.g is in gap-small-groups 4r6p5-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
#############################################################################
##
#W  idgrp1.g                 GAP group library             Hans Ulrich Besche
##                                               Bettina Eick, Eamonn O'Brien
##
##  This file contains the identification routines for groups with order
##  the product of maximal 3 primes. 
##

#############################################################################
##
#F ID_AVAILABLE_FUNCS[ 1 ]
##
ID_AVAILABLE_FUNCS[ 1 ] := SMALL_AVAILABLE_FUNCS[ 1 ];

#############################################################################
##
#F ID_GROUP_FUNCS[ 1 ]( G, inforec )
##
## order p
##
ID_GROUP_FUNCS[ 1 ] := function( G, inforec )

    return 1;
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 2 ]( G, inforec )
##
## order p ^ 2
##
ID_GROUP_FUNCS[ 2 ] := function( G, inforec )

    if IsCyclic( G ) then 
        return 1;
    else 
        return 2;
    fi;
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 3 ]( G, inforec )
##
## order p * q
##
ID_GROUP_FUNCS[ 3 ] := function( G, inforec )
    local typ;

    if IsAbelian( G ) then 
        typ := "pq";
    else 
        typ := "Dpq";
    fi;

    return Position(
           NUMBER_SMALL_GROUPS_FUNCS[ 3 ]( Size( G ), inforec ).types, typ );
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 4 ]( G, inforec )
##
## order p ^ 3
##
ID_GROUP_FUNCS[ 4 ] := function( G, inforec )

    if IsAbelian( G ) then
        if IsCyclic( G ) then         
            return 1;                                                
        elif IsElementaryAbelian( G ) then
            return 5;
        fi;      
        return 2;                            

    else
        if Size( G ) = 8 then              
            if Length( Filtered( AsList( G ), x-> Order( x ) = 2 ) ) = 1 then
                return 4;
            fi;
            return 3;      
        fi;                                                         

        if Maximum( List( GeneratorsOfGroup( G ), x -> Order( x ) ) ) =
                    FactorsInt( Size( G ) )[ 1 ] then          
            return 3;                                         
        fi;                                    
        return 4;  
    fi;
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 5 ]( G, inforec )
##
## order p ^ 2 * q
##
ID_GROUP_FUNCS[ 5 ] := function( G, inforec )
    local n, p, q, s1, s2, typ;

    # get primes
    n := Size(G);
    p := FactorsInt(n);
    q := p[3];             
    p := p[1];                                                         

    # compute the sylow subgroups
    s1  := SylowSubgroup( G, q );                              
    s2  := SylowSubgroup( G, p );                             

    if IsAbelian( G ) then                                                   
        if IsCyclic( s2 ) then
            typ := "p2q";
        else
            typ := "ppq";                                         
        fi;

    elif IsElementaryAbelian( s2 ) then
        if n = 12 and IsNormal( G, s2 ) then       
            typ := "a4";
        else
            typ := "Dpqxp";
        fi;

    elif not IsTrivial( Centralizer( s2, s1 ) ) then
        typ := "Gp2q";
    else
        typ := "Hp2q";
    fi;

    return Position(
           NUMBER_SMALL_GROUPS_FUNCS[ 5 ]( Size( G ), inforec ).types, typ );
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 6 ]( G, inforec )
##
## order p * q ^ 2
##
ID_GROUP_FUNCS[ 6 ] := function( G, inforec )
    local  n, p, q, s1, s2, typ, lat, nor, non, x, s, A, B, C, AC, BC, PO,id;

    # get primes
    n := Size(G);
    p := FactorsInt(n);
    q := p[3];
    p := p[1];

    # compute the sylow subgroups
    s1  := SylowSubgroup( G, q );
    s2  := SylowSubgroup( G, p );

    if IsAbelian( G ) then
        if IsCyclic( s1 ) then
            typ := "pq2";
        else
            typ := "pqq";
        fi;

    elif ( p <> 2 ) and ( (q+1) mod p = 0 ) then
        typ := "Npq2";

    elif IsCyclic( s1 ) then
        typ := "Mpq2";

    elif not IsTrivial( Centralizer( s1, s2 ) ) then
        typ := "Dpqxq";

    else
        lat := List( ConjugacyClassesSubgroups(s1), Representative );
        lat := Filtered( lat, t -> Size(t) = q );
        nor := [];
        non := [];
        x   := 1;
        while x <= Length(lat) and 0 = Length(non) and Length(nor) < 3 do
            if IsNormal( G, lat[x] )  then
                Add( nor, lat[x] );
            else
                Add( non, lat[x] );
            fi;
            x := x + 1;
        od;
        if 0 = Length(non) and 2 < Length(nor)  then
            # Kpq2;
            typ := 1;
        else
            # Lpq2
            while x <= Length(lat) and Length(nor) < 2  do
                if IsNormal( G, lat[x] )  then
                    Add( nor, lat[x] );
                fi;
                x := x + 1;
            od;
            A  := GeneratorsOfGroup( nor[1] )[1];
            B  := GeneratorsOfGroup( nor[2] )[1];
            C  := GeneratorsOfGroup( s2 )[1];
            AC := A^C;
            x  := 1;
            PO := 0;
            while PO <> AC  do
                x := x+1;
                if x^p mod q = 1  then
                    PO := A^x;
                fi;
            od;
            BC := B^C;
            s  := 1;
            PO := 0;
            while s < q and PO <> BC  do
                s := s+1;
                if s mod p <> 0 and s mod p <> 1  then
                    PO := B^((x^s) mod q);
                fi;
            od;
            s := s mod p;
            if ((1/s) mod p) < s  then s := (1/s) mod p;  fi;
            typ := s;
        fi;
    fi;

    return Position(
           NUMBER_SMALL_GROUPS_FUNCS[ 6 ]( Size( G ), inforec ).types, typ );
end;

#############################################################################
##
#F ID_GROUP_FUNCS[ 7 ]( G, inforec )
##
## order p * q * r
##
ID_GROUP_FUNCS[ 7 ] := function( G, inforec )
    local  n, p, q, r, s1, s2, s3, typ, PO, A, C, AC, x, s, y, B, BC, id;

    # get primes
    n := Size(G);
    p := FactorsInt(n);
    r := p[3];
    q := p[2];
    p := p[1];

    # compute the sylow subgroups
    s1  := SylowSubgroup( G, r );
    s2  := SylowSubgroup( G, q );
    s3  := SylowSubgroup( G, p );

    if IsAbelian( G ) then
        typ := "pqr";

    elif IsNormal( G, s3 ) then
        typ := "Dqrxp";

    elif not IsAbelian( ClosureGroup( s1, s2 ) ) then
        typ := "Hpqr";

    elif IsAbelian( ClosureGroup( s1, s3 ) ) then
        typ := "Dpqxr";

    elif IsAbelian( ClosureGroup( s2, s3 ) ) then
        typ := "Dprxq";

    else

        # find <A> and <C>
        C  := GeneratorsOfGroup( SylowSubgroup(G,p) )[1];
        A  := GeneratorsOfGroup( SylowSubgroup(G,r) )[1];
        AC := A^C;
        PO := 0;
        s  := 1;
        while AC <> PO  do
            s := s+1;
            if s mod r <> 1 and s^p mod r = 1  then
                PO := A^s;
            fi;
        od;

        # correct <C>
        x := First( [2..r-1], t -> t^p mod r = 1 );
        s := LogMod( x, s, r );
        C := C^s;

        # now find <B>
        B  := GeneratorsOfGroup( SylowSubgroup(G,q) )[1];
        BC := B^C;
        PO := 0;
        s  := 1;
        while BC <> PO  do
            s := s+1;
            if s mod r <> 1 and s^p mod r = 1  then
                PO := B^s;
            fi;
        od;

        # and find <s>
        y := First( [2..q-1], t -> t^p mod q = 1 );
        s := LogMod( s, y, q ) mod OrderMod( y, q );

        typ := s; # the typ is Gpqr( s )
    fi;

    return Position(
           NUMBER_SMALL_GROUPS_FUNCS[ 7 ]( Size( G ), inforec ).types, typ );
end;