Skip to content

Treatment of inverses in MappedWord #6678

Open

Description

@ThomasBreuer

(See #6628 for the motivation.)

According to the documentation of MappedWord( w, gens, imgs ), inverting intermediate results in terms of imgs can be avoided in the situation that w is an element of a free group and gens are the free generators, by appending the inverses of the free generators to gens and appending the (a priori known) inverses of the entries in imgs to imgs.

This seems to be not the case when w is represented by a straight line program (indicated by the filter IsStraightLineProgElm), and if the defining straight line program involves inverting some of the intermediate results.
Such elements can be created for example as follows.

gap> F:= FreeGroup( 2 );;
gap> G:= F / [ F.1^7, F.2^9, F.1*F.2*F.1^-1*F.2^-1 ];;
gap> IsFinite( G );;
gap> H:= CyclicSubgroupFpGroup( G );;
gap> iso:= IsomorphismFpGroup( H );;
gap> l:= MappingGeneratorsImages( iso )[1];;
gap> w:= Inverse( UnderlyingElement( l[1] ) );
<[ [ 1, -1 ] ]|f1^-1>
gap> w in F;
true
gap> IsStraightLineProgElm( w );
true
gap> w![1];
rec( seeds := [ f1 ] )

(In IsomorphismFpGroup, the function TreeRepresentedWord is called for creating the elements in question.)

Calling MappedWord for w and two lists (with or without inverses) will evaluate the straight line program defined by [ [ 1, -1 ] ], which means to compute x^-1 where x is the first given image.

What would be the best way to support known inverses of the generators also in this situation?

We could change the straight line program stored in w to avoid inverses at all.
Or the stored straight line programs could be written in terms of the generators and their inverses, and inverses of the given images could be computed on demand if they are not given.

(By the way, the syntax MappedWord( w, gens, imgs, invimgs ) would be more useful than the current treatment of inverses; then a perhaps empty list could be entered as invimgs, and as soon as an inverse gets computed it would get cached in this list, such that inverses are computed at most once in several subsequent MappedWord calls with the same imgs.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions