I have a list and a function on the elements on this list. I want to define an equivalence relation on this list by saying that two elements are equivalent if the function applied to those elements gives the same results. Is there a way to obtain in GAP the euivalence classes (so the result should be a list of lists corresponding to the equivalence classes). Example: The list is
[ [ 2, 2, 2, 1 ], [ 3, 2, 2, 1 ], [ 2, 3, 2, 1 ], [ 3, 3, 2, 1 ], [ 4, 3, 2, 1 ] ]
and the function $f$ is taking the Maximum of the number of such an element. Thus for example $f([ 3, 2, 2, 1 ])=3$. The equivalence classes are in this example :
-[ 2, 2, 2, 1 ]
-[ 3, 2, 2, 1 ], [ 2, 3, 2, 1 ], [ 3, 3, 2, 1 ]
-[ 4, 3, 2, 1 ]
Maximumbyx->BlaBla(FooBar(x,GF(3),99))– ahulpke Aug 25 '17 at 20:17