Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

There is no method action for elements of the symmetric group. You should write a(tuple) instead of a.action(tuple). And by the way, your function does not return anything, and I think c should be initialized to 0. Maybe:

def Aut(tuple):
    c = 0
    for a in SymmetricGroup(len(tuple)):
        if a(tuple) == tuple:
            c = c+1
    return c