The following log illustrates an irritation when composing mappings
where the first map is the inclusion of an identity subgroup.
This problem arises, for example, when writing a function to perform
some operation on all normal subgroups of a group G, so that the
identity subgroup needs to be treated as a special case.
gap> G := Group( (1,2,3) );; gap> idmap := GroupHomomorphismByImages( G, G, [ (1,2,3) ], [ (1,2,3) ] );; gap> idsubgp := Subgroup( G, [ () ] );; gap> G.name := "G";; idsubgp.name := "I";; gap> incmap := GroupHomomorphismByImages( idsubgp, G, [ () ], [ () ] ); GroupHomomorphismByImages( I, G, [ () ], [ () ] )
gap> # expect composite (idmap)o(incmap) = incmap :-
gap> comp := CompositionMapping( idmap, incmap );
Error, Record: element 'orbit' must have an assigned value at
for <var> in [ 1 .. Length( hom2.orbit ) ] ... in
com.operations.CompositionMapping( arg[i], com ) called from
CompositionMapping( idmap, incmap ) called from
gap> # can fix the problem by inserting missing fields in incmap :- gap> incmap.orbit := [ 1 ];; gap> incmap.transversal := [ () ];; gap> incmap.stabilizer := rec( generators := [ ], identity := () );; gap> comp := CompositionMapping( idmap, incmap ); GroupHomomorphismByImages( I, G, [ () ], [ () ] )
Should this be considered a bug, or are there good reasons not to
define .orbit, .transversal & .stabilizer in this case?
Sorry if this has been discussed previously.
Chris Wensley (email@example.com)