diff --git a/build/pkgs/configure/checksums.ini b/build/pkgs/configure/checksums.ini index 3f4c1eecd6d..3240e670fc5 100644 --- a/build/pkgs/configure/checksums.ini +++ b/build/pkgs/configure/checksums.ini @@ -1,3 +1,3 @@ tarball=configure-VERSION.tar.gz -sha1=d2f8c0bc6c40a0e3e8f7cb0deebee5e7bc7da501 -sha256=cde422cec1dc104f4f4b1369167a17cc77519186180bfc14322d078881581c50 +sha1=3df2b29a0be22e74bc2f58297e8848d44d62a1ed +sha256=0e6edf9ba6dcd3c318ef0554940428370fb686403339cbc105cad0aa9296d7e3 diff --git a/build/pkgs/configure/package-version.txt b/build/pkgs/configure/package-version.txt index d3929445739..4d6f980baa5 100644 --- a/build/pkgs/configure/package-version.txt +++ b/build/pkgs/configure/package-version.txt @@ -1 +1 @@ -27fce1faa78ef19b8c43287016f0acbdf0fa169a +63276c5d5afef5f2965464612d0bf399a14b041d diff --git a/src/sage/algebras/quantum_groups/quantum_group_gap.py b/src/sage/algebras/quantum_groups/quantum_group_gap.py index 05e4e1b6982..931ee211ff1 100644 --- a/src/sage/algebras/quantum_groups/quantum_group_gap.py +++ b/src/sage/algebras/quantum_groups/quantum_group_gap.py @@ -838,7 +838,7 @@ def counit(self, elt): constant = R(str(ext_rep.pop(2 * i))) # Pop the coefficient break # To reconstruct, we need the following - F = libgap.eval('ElementsFamily')(libgap.eval('FamilyObj')(self._libgap)) + F = self._libgap.FamilyObj().ElementsFamily() elt = F.ObjByExtRep(ext_rep) co = self._libgap.CounitMap() return R(str(co(elt))) + constant @@ -2330,7 +2330,7 @@ def _construct_monomial(self, k): sage: B._construct_monomial((3,0,1)) F[a1]^(3)*F[a2] """ - F = libgap.eval('ElementsFamily')(libgap.eval('FamilyObj')(self._libgap)) + F = self._libgap.FamilyObj().ElementsFamily() one = self._libgap_base.One() data = [] for i, val in enumerate(k): @@ -2684,7 +2684,7 @@ def _unpickle_generic_element(parent, data): sage: loads(dumps(x)) == x # indirect doctest True """ - F = libgap.eval('ElementsFamily')(libgap.eval('FamilyObj')(parent._libgap)) + F = parent._libgap.FamilyObj().ElementsFamily() ret = [] # We need to multiply by this to get the right type in GAP one = parent._libgap_base.One() diff --git a/src/sage/groups/perm_gps/permgroup.py b/src/sage/groups/perm_gps/permgroup.py index a4e60e771f9..1d3b0bab92c 100644 --- a/src/sage/groups/perm_gps/permgroup.py +++ b/src/sage/groups/perm_gps/permgroup.py @@ -2974,20 +2974,21 @@ def semidirect_product(self, N, mapping, check=True): raise ValueError(msg) # create a parallel list of the automorphisms of N in GAP - libgap.eval('N := Group({})'.format(list(N.gens()))) - gens_string = ",".join(str(x) for x in N.gens()) - homomorphism_cmd = 'alpha := GroupHomomorphismByImages(N, N, [{0}],[{1}])' - libgap.eval('morphisms := []') + N_gap = libgap.eval(f'Group({list(N.gens())})') + morphisms = libgap.eval('[]') + libgap_gens = N_gap.GeneratorsOfGroup() for alpha in mapping[1]: - images_string = ",".join(str(alpha(n)) for n in N.gens()) - libgap.eval(homomorphism_cmd.format(gens_string, images_string)) - libgap.eval('Add(morphisms, alpha)') + images = [alpha(g) for g in N.gens()] + alpha_gap = N_gap.GroupHomomorphismByImages(N_gap, + libgap_gens, images) + morphisms.Add(alpha_gap) # create the necessary homomorphism from self into the # automorphism group of N in GAP - libgap.eval('H := Group({0})'.format(mapping[0])) - libgap.eval('phi := GroupHomomorphismByImages(H, AutomorphismGroup(N),{},morphisms)'.format(mapping[0])) - libgap.eval('sdp := SemidirectProduct(H, phi, N)') - return PermutationGroup(gap_group='sdp') + H = libgap.eval(f'Group({mapping[0]})') + phi = H.GroupHomomorphismByImages(N_gap.AutomorphismGroup(), + H.GeneratorsOfGroup(), morphisms) + sdp = H.SemidirectProduct(phi, N_gap) + return PermutationGroup(gap_group=sdp) def holomorph(self): r""" @@ -3047,11 +3048,11 @@ def holomorph(self): - Kevin Halasz (2012-08-14) """ - libgap.eval('G := Group({})'.format(list(self.gens()))) - libgap.eval('aut := AutomorphismGroup(G)') - libgap.eval('alpha := InverseGeneralMapping(NiceMonomorphism(aut))') - libgap.eval('product := SemidirectProduct(NiceObject(aut),alpha,G)') - return PermutationGroup(gap_group='product') + G = libgap.eval(f'Group({list(self.gens())})') + aut = G.AutomorphismGroup() + alpha = aut.NiceMonomorphism().InverseGeneralMapping() + product = aut.NiceObject().SemidirectProduct(alpha, G) + return PermutationGroup(gap_group=product) def subgroup(self, gens=None, gap_group=None, domain=None, category=None, canonicalize=True, check=True): """