Index( G, U )
Let U be a subgroup of G. Then Index returns the index of U in
G as an integer.
Note that Index sets and checks U.index if G is the parent group
of U.
gap> s4 := Group( (1,2,3,4), (1,2) );
Group( (1,2,3,4), (1,2) )
gap> Index( s4, DerivedSubgroup( s4 ) );
2
The default function GroupOps.Index needs a finite group G. It
returns the quotient of Size( G ) and Size( U ).
GAP 3.4.4