# SmallGrp, chapter 1
#
# DO NOT EDIT THIS FILE - EDIT EXAMPLES IN THE SOURCE INSTEAD!
#
# This file has been generated by AutoDoc. It contains examples extracted from
# the package documentation. Each example is preceded by a comment which gives
# the name of a GAPDoc XML file and a line range from which the example were
# taken. Note that the XML file in turn may have been generated by AutoDoc
# from some other input.
#
gap> START_TEST("smallgrp01.tst");

# doc/../gap/small.gd:619-632
gap> G := SmallGroup( 60, 4 );
<pc group of size 60 with 4 generators>
gap> StructureDescription( G );
"C60"
gap> G := SmallGroup( 60, 5 );
Group([ (1,2,3,4,5), (1,2,3) ])
gap> StructureDescription( G );
"A5"
gap> G := SmallGroup( 768, 1000000 );
<pc group of size 768 with 9 generators>
gap> G := SmallGroup( [768, 1000000] );
<pc group of size 768 with 9 generators>

# doc/../gap/small.gd:711-718
gap> AllSmallGroups( 6 );
[ <pc group of size 6 with 2 generators>, 
  <pc group of size 6 with 2 generators> ]
gap> AllSmallGroups( 60, IsNilpotentGroup );
[ <pc group of size 60 with 4 generators>, 
  <pc group of size 60 with 4 generators> ]

# doc/../gap/small.gd:741-752
gap> G := OneSmallGroup( 6, IsAbelian );
<pc group of size 6 with 2 generators>
gap> StructureDescription( G );
"C6"
gap> G := OneSmallGroup( 6, IsAbelian, false );
<pc group of size 6 with 2 generators>
gap> StructureDescription( G );
"S3"
gap> G := OneSmallGroup( Size, [1..1000], IsSolvableGroup, false );
Group([ (1,2,3,4,5), (1,2,3) ])

# doc/../gap/small.gd:807-814
gap> NumberSmallGroups( 512 );
10494213
gap> NumberSmallGroups( 2^8 * 23 );
1083472
gap> NumberSmallGroups( 4096 );
Error, the library of groups of size 4096 is not available

# doc/../gap/small.gd:819-824
gap> NumberSmallGroups( [ 1 .. 100 ] );
1048
gap> NumberSmallGroups( 96, IsAbelian );
7

# doc/../gap/small.gd:586-595
gap> NumberSmallGroupsAvailable( 100 );
true
gap> NumberSmallGroups( 100 );
16
gap> NumberSmallGroupsAvailable( 4096 );
false
gap> NumberSmallGroups( 4096 );
Error, the library of groups of size 4096 is not available

# doc/../gap/small.gd:910-915
gap> IdSmallGroup( GL( 2,3 ) );
[ 48, 29 ]
gap> IdSmallGroup( Group( (1,2,3,4),(4,5) ) );
[ 120, 34 ]

# doc/../gap/small.gd:775-784
gap> IdsOfAllSmallGroups( 60, IsNilpotentGroup );
[ [ 60, 4 ], [ 60, 13 ] ]
gap> IdsOfAllSmallGroups( 60, IsNilpotentGroup, false );
[ [ 60, 1 ], [ 60, 2 ], [ 60, 3 ], [ 60, 5 ], [ 60, 6 ], [ 60, 7 ], 
  [ 60, 8 ], [ 60, 9 ], [ 60, 10 ], [ 60, 11 ], [ 60, 12 ] ]
gap> IdsOfAllSmallGroups( Size, 60, IsSupersolvableGroup, true );
[ [ 60, 1 ], [ 60, 2 ], [ 60, 3 ], [ 60, 4 ], [ 60, 6 ], [ 60, 7 ], 
  [ 60, 8 ], [ 60, 10 ], [ 60, 11 ], [ 60, 12 ], [ 60, 13 ] ]

# doc/../gap/small.gd:955-973
gap> SmallGroupsInformation( 32 );

  There are 51 groups of order 32.
  They are sorted by their ranks. 
     1 is cyclic. 
     2 - 20 have rank 2.
     21 - 44 have rank 3.
     45 - 50 have rank 4.
     51 is elementary abelian. 

  The following selection criteria are indexed for this size:
     IsAbelian, IsNilpotentGroup, IsSupersolvableGroup, IsSolvableGroup,
     PClassPGroup, RankPGroup, FrattinifactorSize and FrattinifactorId.

  This size belongs to layer 2 of the SmallGroups library. 
  IdSmallGroup is available for this size. 
 

# doc/../gap/small.gd:854-856
gap> UnloadSmallGroupsData();

#
gap> STOP_TEST("smallgrp01.tst", 1);
