• Aucun résultat trouvé

Base Change

Dans le document This page intentionally left blank (Page 107-110)

Further Low-Level Algorithms

5.4. Base Change

An oft occurring problem is that we already have an SGS for a groupGrelative to some base but we need another base and corresponding SGS that are more suitable for the problem at hand. In Section 5.1.1, we saw that we can construct a base relative to any ordering of the permutation domain; however, more efficient methods exist that exploit the already existing SGS.

The first such base change algorithm was described in [Sims, 1971a, 1971b].

Given an SGS relative to some base (β1, . . . , βm), Sims’s method constructs an SGS relative to the base

1, . . . , βi−1, βi+1, βi, βi+2, . . . , βm).

Repeated applications of this procedure enable us to compute an SGS relative to any base (α1, α2, . . . , αk). Namely, ifα1 does not already occur on the list (β1, . . . , βm) then we insert it at the earliest possible position (i.e., after the firstβi such thatG(β1,...,βi)fixesα) as a redundant base point; after that, with repeated transpositions, we bringα1to the first position. Then, working inGα1, we construct an SGS relative to a base starting with (α1, α2), and so on. This incremental procedure is especially efficient when only an initial segment of a new base is prescribed. For example, this is the case when we need generators for the stabilizer of some pointα1.

The Exchange of Two Base Points (Deterministic Version)

Let S be an SGS for G relative to the base (β1, . . . , βm), let G = G[1]

· · · ≥ G[m+1] =1 be the corresponding point stabilizer subgroup chain, and let R1, . . . ,Rm be the transversals along this subgroup chain. Our goal is to compute an SGS and the transversals ¯R1, . . . ,R¯mcorresponding to the point stabilizer chainG =G¯[1] ≥ · · · ≥ G¯[m+1] =1 defined by the new ordering (β1, . . . , βi1, βi+1, βi, βi+2, . . . , βm).

For 1≤ j <i−1 a ndi +1< jm,R¯j =Rj. Also, since ¯G[i] =G[i], the newith fundamental orbitβi+1SG[i]and a Schreier tree coding ¯Riare readily obtained. The bulk of the work is to compute ¯Ri+1.

We initialize the new (i+1)st fundamental orbit as ¯i+1:= {βi}. Then we form Schreier generators (only as words, without multiplying out permutations) from ¯Ri andSG[i]. If, for some wordwrepresenting aSchreier generator, the imageβiwis not in ¯i+1then we multiply outwto obtain a permutationp

G1,...,βi−1i+1), a dd pto the setS, and recompute ¯i+1 :=βSG(β1,...,βi−1,βi+1 )

i .

Note that the correct value of|¯i+1| = |R¯i+1| = |Ri||Ri+1|/|R¯i|is known in advance, so the algorithm may terminate (and usually does) without considering all Schreier generators. We have to add at most log|R¯i+1|permutations toS, since the already constructed part of ¯i+1 at least doubles at each addition.

The Schreier tree representing the transversal ¯Ri+1can be computed from the augmented strong generating set S. If we use the deterministic algorithm in the proof of Lemma 4.4.2 to code transversals in Schreier trees of depth at most 2 log|G|, then transposing two base points can be done in nearly linear time.

The Exchange of Two Base Points (Las Vegas Version)

The set ¯Ri+1can also be computed by a randomized nearly linear-time algo-rithm. Since we have an SGS forG[i], we can construct uniformly distributed random elementsg of G[i]. Let ¯gR¯i so thatg( ¯g)−1G[i]βi+1. As we sa w in the proof of Lemma4.3.1, g( ¯g)−1 is auniformly distributed random ele-ment of G[i]βi+1, so it has a chance at least 1/2 to increase the already known part of ¯i+1and ¯Ri+1. Since we know the size of ¯Ri+1in advance, this con-struction is Las Vegas type. This randomized concon-struction is usually faster than the deterministic nearly linear one described earlier; an additional advantage is that, by Theorem 4.4.6, the Schreier tree coding ¯Ri+1 will be shallow with high probability. TheGAPimplementation of base change uses this Las Vegas version.

We note that Sims originally used a different method for computing ¯Ri+1

(cf. Exercise 5.5). This result was generalized in [Brown et al., 1989] and used in adeterministicO(n2) time algorithm to perform acyclic base change, that is, changing the base from (β1, . . . , βm) to (β1, . . . , βi1, βj, βi, βi+1, . . . , βj−1, βj+1, . . . , βm). In [Cooperman and Finkelstein, 1992], this generalization is combined with Lemma 4.4.8 to obtain a nearly linear-time deterministic cyclic base change algorithm.

Base Change by Conjugation

[Sims, 1971a] also contains the following observation. Suppose that an SGSS relative to the base (β1, . . . , βm) is known and we need an SGS ¯Srelative to a base starting with (α1, . . . , αk). If there existsgGwithβig =αifor 1≤ik then ¯S := Sg can be chosen, which is usually faster than a sequence of base point transpositions. Therefore, inGAP, the method of transposing base points is combined with the construction of a conjugating permutationc. Initially, we setc := 1 and build upcrecursively, obtaining permutations that conjugate

larger and larger initial segments of the base to the desired points. Suppose that currently, after some base point transpositions, we have an SGS relative to the base (γ1, . . . , γl), andγic = αi for 1 ≤ ij −1. Ifαcj−1 is in the jth fundamental orbit then we compute the transversal elementr from the jth transversal satisfyingγrj =αcj1, and we redefinec:=r c. Ifαcj1is not in the jth fundamental orbit then we bringαcj−1 in the jth position of the base via repeated transpositions and leavec unchanged. In both cases, we get a base (γ1, . . . , γl) a ndcsuch that (γi)c=αiholds forij. Afterksteps, we have an SGSSrelative to some base such thatScis an SGS relative to a base starting with (α1, . . . , αk).

If a very long initial segment of a new base is prescribed and it differs significantly from the current base, it may be beneficial to construct the new SGS from scratch, instead of applying a long sequence of transpositions of base points. Since we already have an SGS, uniformly distributed random elements ofGare available. Thus the heuristic SGS construction described in Section 4.3, the so-called random Schreier–Sims algorithm, is upgraded to Las Vegas type by Lemma4.3.1.

Lemma 5.4.1. Let G ≤ Sym(), let = (β1, β2, . . . , βn)be an ordering of, and suppose that uniformly distributed random elements of G can be constructed in timeξ. Let d >0be also given. Then there is a Monte Carlo algorithm that constructs an SGS of size O(dlognlog|G|)for G, relative to the (redundant) base1, β2, . . . , βn). The time requirement of the algorithm is O(dlognlog|G|(ξ+ndlognlog|G|))and the probability of error is less than1/nd. If|G|is known in advance then this algorithm is a Las Vegas one.

Proof. Suppose that we already constructed some subsetsS1,S2, . . .of gener-ator sets for the chain of subgroupsG[1] :=G,G[2] :=Gβ1, . . .and Schreier trees (Si,Ti) reaching subsets1, 2, . . .of the fundamental orbits. During the construction, we maintain the property that, for alli, if the currentSi has kelements then the depth of the Schreier treeTi is at mostk. Because of this restriction, it is possible thati does not contain all points ofβiSi.

Letg be auniformly distributed random element ofG. We sift g through the partial coset representative system we have already constructed and obtain elementsg1,g2, . . . ,gj,giG[i], up to an index j; the sifting process stops at asubgroupG[j]where the siftee falls into a coset not yet represented in (Sj,Tj).

As observed in the proof of Lemma4.3.1,giis auniformly distributed random element ofG[i] for 1≤ij. For 1ij we addgi to the generator set Si

forG[i], and we add one more level to the treeTi, by computingγg−1i for all

γi. Hence the new tree reaches the subsetiigi1of the fundamental orbit. (Ifigi−1i =ithen we discardgi.) The procedure stops whendlogn random elements sift through (or, in the case when|G|is known,dlognrandom elements sift through orn

i=1|i|reaches|G|). By Lemma 4.3.1, at termination we have an SGS forGwith probability at least 1−1/nd.

By Theorem 4.4.6, for eachiwithG[i] =G[i+1], the size of|Si|, and hence the depth of theith Schreier tree, will beO(dlognlog|G[i]:G[i+1]|) with probabil-ity at least 1−1/nd+1. Thus the new SGS will consist ofO(dlog|G|logn) group elements and the sum of depths of the Schreier trees isO(dlognlog|G|). The time requirement of the algorithm is as stated, since we siftO(dlognlog|G|) random elements at anO(ndlognlog|G|) cost each.

Although it is easy to give examples for which constructing an SGS from scratch is faster than the construction via a sequence of base point transpositions, in practice it is hard to recognize in advance the instances when the construction from scratch will be faster. The default method inGAPis viaasequence of base point transpositions combined with a conjugation, as described in this section.

Dans le document This page intentionally left blank (Page 107-110)