# orb, chapter 7
#
# DO NOT EDIT THIS FILE - EDIT EXAMPLES IN THE SOURCE INSTEAD!
#
# This file has been generated by AutoDoc. It contains examples extracted from
# the package documentation. Each example is preceded by a comment which gives
# the name of a GAPDoc XML file and a line range from which the example were
# taken. Note that the XML file in turn may have been generated by AutoDoc
# from some other input.
#
gap> START_TEST("orb02.tst");

# doc/search.xml:37-53
gap> gens := [(1,2,3,4,5,6,7,8,9,10),(1,2)];
[ (1,2,3,4,5,6,7,8,9,10), (1,2) ]
gap> o := Orb(gens,(),OnRight,rec( report := 2000,
> lookingfor := 
> function(o,x) return NrMovedPoints(x) = 7 and Order(x)=7; end,
> schreier := true ));
<open orbit, 1 points with Schreier tree looking for sth.>
gap> Enumerate(o);
<open orbit, 614 points with Schreier tree looking for sth.>
gap> w := TraceSchreierTreeForward(o,PositionOfFound(o));
[ 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 2 ]
gap> ActWithWord(o!.gens,w,o!.op,o[1]);                  
(1,10,9,8,7,6,5)
gap> o[PositionOfFound(o)] = ActWithWord(o!.gens,w,o!.op,o[1]);
true
gap> EvaluateWord(o!.gens,w);
(1,10,9,8,7,6,5)

#
gap> STOP_TEST("orb02.tst", 1);
