Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected error computing PreImagesRepresentative #1005

Closed
fingolfin opened this issue Dec 7, 2016 · 2 comments
Closed

Unexpected error computing PreImagesRepresentative #1005

fingolfin opened this issue Dec 7, 2016 · 2 comments

Comments

@fingolfin
Copy link
Member

Another issue based on http://tracker.gap-system.org/issues/391: The following error is unexpected, I'd instead expect PreImagesRepresentative to print an error that the object is not contained in the image of the map?

gap> g := DihedralGroup(100);;
gap> g := SemidirectProduct(AutomorphismGroup(g),g);;
gap> f := GroupHomomorphismByImages(g,g,List(GeneratorsOfGroup(g),x->(x^Projection(g))^Embedding(g,1)));
[ f1, f2, f3, f4, f5, f6, f7, f8, f9, f10 ] -> [ f1, f2, f3, f4, f5, f6, <identity> of ..., <identity> of ..., <identity> of ..., <identity> of ... ]
gap> g.7 in Range(f);
true
gap> g.7 in Image(f);
false
gap> PreImagesRepresentative(f,g.7);
Error, List Element: <list>[7] must have an assigned value in
  if map[d] > max  then
    elm := id;
else
    if not IsBound( map[d] )  then
        Error( "<elm> lies not in group defined by <pcgs>" );
    fi;
    ll := LeadingExponentOfPcElement( pa, elm );
    lr := lc[d];
    exp[map[d]] := ll / lr mod ros[d];
    elm := LeftQuotientPowerPcgsElement( pcgs, map[d], exp[map[d]], elm );
fi; at gap.github/lib/pcgsind.gi:1411 called from
ExponentsOfPcElement( ParentPcgs( pcgs ), elm, pcgs!.depthsInParent ) at gap.github/lib/pcgsind.gi:1472 called from
ExponentsOfPcElement( pcgsR, elm ) at gap.github/lib/ghompcgs.gi:504 called from
@hulpke
Copy link
Contributor

hulpke commented Dec 7, 2016

The if in the else branch should be first, I'll fix this. Wirth it the error message will be
lies not in group defined by
which I think is a plausible error indicating the problem.

hulpke added a commit to hulpke/gap that referenced this issue Dec 7, 2016
hulpke added a commit to hulpke/gap that referenced this issue Dec 7, 2016
@fingolfin
Copy link
Member Author

This has been resolved by @hulpke and now gives this helpful error:

gap> PreImagesRepresentative(f,g.7);
Error, <elm> lies not in group defined by <pcgs> at /Users/mhorn/Projekte/GAP/gap.github/lib/pcgsind.gi:1397 called from
ExponentsOfPcElement( ParentPcgs( pcgs ), elm, pcgs!.depthsInParent ) at /Users/mhorn/Projekte/GAP/gap.github/lib/pcgsind.gi:1471 called from
ExponentsOfPcElement( pcgsR, elm ) at /Users/mhorn/Projekte/GAP/gap.github/lib/ghompcgs.gi:504 called from
<function "unknown">( <arguments> )
 called from read-eval loop at *stdin*:14
you can 'quit;' to quit to outer loop, or
you can 'return;' to continue
brk>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants