Wrong gyration orbit length
Closed this issue · 11 comments
sage -t --long --random-seed=103314966111765381642554237852288942819 src/sage/combinat/alternating_sign_matrix.py
**********************************************************************
File "src/sage/combinat/alternating_sign_matrix.py", line 609, in sage.combinat.alternating_sign_matrix.?.gyration
Failed example:
a == a0
Expected:
True
Got:
False
**********************************************************************
1 item had failures:
1 of 17 in sage.combinat.alternating_sign_matrix.?.gyration
[313 tests, 1 failure, 0.83 s]
The claim of the doctest is that the orbit length of gyration on AlternatingSignMatrices(5) is a divisor of 10, which appears to be incorrect:
sage: def test_orbit_length(n):
....: a0 = a = AlternatingSignMatrices(n).random_element()
....: for i in range(10000):
....: a = a.gyration()
....: if a == a0:
....: return i + 1
....:
sage: lcm(foo(5) for _ in range(1000))
20
CC: @videlec
Component: combinatorics
Keywords: alternative sign matrices, gyration
Author: Jonathan Kliem
Branch/Commit: 1d021c1
Reviewer: Frédéric Chapoton
Issue created by migration from https://trac.sagemath.org/ticket/32132
Author: Jonathan Kliem
Branch: public/32132
but see table 3.1 on page 6 of
http://www-users.math.umn.edu/~reiner/REU/CloningerDavidowitz2007.pdf
But this is exactly what the table states. The orbit can be of length 2,4,5,10. The lowest common multiple being 20.
Thanks for the pointer. I didn't know where to look for this. So this isn't a bug apparently.
the data of this table can be confirmed using
sage: def ma(M):
....: return matrix(ZZ,5,5,
....: M._matrix, immutable=True)
....:
sage: dg=DiGraph([(ma(x),ma(x.gyration())) for x in A])
sage: set(dg.connected_components_sizes())
{2, 4, 5, 10}
ok, good to go
Reviewer: Frédéric Chapoton
Thank you.
Changed branch from public/32132 to 1d021c1