Did I find the right examples for you? yes no

All Samples(4)  |  Call(4)  |  Derive(0)  |  Import(0)
Returns the number of integers moved by a permutation.

Examples
========

>>> from sympy.combinatorics import Permutation
>>> Permutation([0, 3, 2, 1]).length()
2
>>> Permutation([[0, 1], [2, 3]]).length()
4(more...)

src/s/y/sympy-0.7.5/sympy/combinatorics/tests/test_permutations.py   sympy(Download)
    assert (p**(p.order())).is_Identity
 
    assert p.length() == 6
    assert q.length() == 7
    assert r.length() == 4

src/s/y/sympy-HEAD/sympy/combinatorics/tests/test_permutations.py   sympy(Download)
    assert (p**(p.order())).is_Identity
 
    assert p.length() == 6
    assert q.length() == 7
    assert r.length() == 4