def test_all():
    assert set(VirtualInvolution.all(3, False)) == {
        VirtualInvolution((1, 1), (2, 2)),
        VirtualInvolution((1, 2)),
        #
        VirtualInvolution((1, 1), (2, 2), (3, 3)),
        VirtualInvolution((1, 2), (3, 3)),
        VirtualInvolution((1, 1), (2, 3)),
        VirtualInvolution((1, 1), (2, 3)),
        VirtualInvolution((1, 3), (2, 2)),
    }
def test_is_atom():
    y = AffinePermutation(6, 5, 4, 3, 2, 1, 7)
    i = 3
    j = 14

    y_, i_, j_ = VirtualInvolution.from_permutation(y, i, j)
    for w in y.get_atoms():
        w_ = w.virtualize(i, j, y)
        assert y_.is_virtual_atom(w_)
        assert i_ == 1 and j_ == 3
Beispiel #3
0
    def _get_cases(cls):
        cases = []
        for y in VirtualInvolution.all(maximum_size=4, mimimal_type=True):
            for i, j in itertools.combinations(range(1, y.rank + 1), 2):
                if y.tau(i, j) == y:
                    for w in y.get_virtual_atoms(required_ascents={(i, j)}):
                        cases += [(y, i, j, w)]

        dictionary = {}
        for y, i, j, w in cases:
            case = None
            if i < j == y(j) < y(i) and w(y(i)) < w(i) < w(j):
                case = 'A1'
def test_covering_property():
    a = list(VirtualInvolution.all(maximum_size=4, mimimal_type=True))
    for index, y in enumerate(a):
        print('Left:', len(a) - index)
        for i, j in itertools.combinations(range(1, y.rank + 1), 2):
            z = y.tau(i, j)
            if y != z:
                for w in y.get_virtual_atoms(required_ascents={(i, j)}):
                    print('y =', y)
                    print('z =', z)
                    print('w =', w)
                    print('w * t_{i,j} =', w.transpose(i, j))
                    assert z.is_virtual_atom(w.transpose(i, j))
def test_get_virtual_atoms():
    y = AffinePermutation(6, 5, 4, 3, 2, 1, 7)
    i, j = 1, 6

    y_, i_, j_ = VirtualInvolution.from_permutation(y, i, j)
    assert list(y_.get_virtual_atoms(required_ascents={(i_, j_)})) == []

    atoms = list(y_.get_virtual_atoms())
    assert len(atoms) == 1

    virtual = atoms[0]
    for w in y.get_atoms():
        assert virtual.contains(w.virtualize(i, j, y))
def test_toggling_property():
    a = list(VirtualInvolution.all(maximum_size=4, mimimal_type=True))
    for index, y in enumerate(a):
        print('Left:', len(a) - index)
        for i, j in itertools.combinations(range(1, y.rank + 1), 2):
            z = y.tau(i, j)
            if y == z:
                for w in y.get_virtual_atoms(required_ascents={(i, j)}):
                    print('y =', y)
                    print('w =', w)
                    assert y.rank in {3, 4}
                    if y.rank == 3:
                        assert y.cycles == {(1, 3)} and y.fixed == {2}
                    if y.rank == 4:
                        assert y.cycles == {(1, 4),
                                            (2, 3)} and y.fixed == set()

                    k, l = y.toggle(w, i, j)
                    v = w.transpose(i, j).transpose(k, l)
                    print('v == w?\n', v == w)
                    print('v =', v)
                    assert y.is_virtual_atom(v)
def test_transpose():
    y = AffinePermutation(6, 5, 4, 3, 2, 1, 7)
    i, j = 3, 7

    y_, i_, j_ = VirtualInvolution.from_permutation(y, i, j)

    assert i_ == 1 and j_ == 3

    w = AffinePermutation(6, 1, 4, 3, 5, 2, 7).inverse()
    w_ = w.virtualize(3, 7, y)

    assert y_.is_virtual_atom(w_)

    z_ = y_.tau(i_, j_)
    v_ = w_.transpose(i_, j_)

    a, b = VirtualPermutation.CYCLE_CHARS
    assert not z_.is_virtual_atom(v_)
    assert z_.get_invalid_configurations(v_) == {
        (a, 1, 2, b, 3): {
            (2, 3, b, a, 1): [(y_.REASON_C2, ('P', 'Q', 1, 3))]
        }
    }
Beispiel #8
0
    def _tex(self):
        self.lines = [
            """
\\documentclass[10pt]{article}
\\usepackage{amsmath,amssymb,amsthm,fullpage,hyperref}
\\usepackage[margin=0.75in]{geometry}
\\usepackage[shortlabels]{enumitem}

\\theoremstyle{definition}
\\newtheorem*{theorem}{Theorem}
\\theoremstyle{definition}
\\newtheorem{lemma}{Lemma}

\\def\\dash{\\text{\\hspace{0.5mm}---\\hspace{0.5mm}}}
\\def\\Fix{\\mathrm{Fix}}
\\def\\Cyc{\\mathrm{Cyc}}
\\def\\ZZ{\\mathbb{Z}}

\\begin{document}

\\title{Computer-generated proof of affine involution covering property}
\\author{Eric MARBERG \\and Yifeng ZHANG}
\\maketitle
\\tableofcontents

\\section{Setup}

Let $n$ be a positive integer.
For the definition of the affine symmetric group $\\tilde S_n$, see \\cite{M}.
Fix an affine permutation $w \\in \\tilde S_n$ and an involution $y =y^{-1} \\in\\tilde S_n$.
We set $y_a = y(a)$ for $a \\in \\ZZ$ and define
\\[\\Cyc(y) = \\{ (a,b) \\in \\ZZ\\times\\ZZ : a \\leq b = y_a\\}.\\]
As a shorthand, we write $w^{-1} = \\dash a\\dash b\\dash c \\dash \\cdots\\dash d \\dash$
to mean that $w_a < w_b < w_c < \\dots < w_d$.

\\begin{lemma}\\label{lem-1}
One has $w \\in \\mathcal{A}(y)$
if and only if for all $(a,b),(a',b') \\in \\Cyc(y)$, the following properties hold:
\\begin{enumerate}
\\item[(Y1)] If $a < b$ then $w^{-1} = \\dash b \\dash a \\dash$.
\\item[(Y2)] If $a < a' \\leq b' < b$ then $w^{-1} \\neq \\dash b \\dash a' \\dash a \\dash$
and $w^{-1}\\neq \\dash b \\dash b' \\dash a \\dash.$
\\item[(Y3)] If $a < a'$ and $b < b'$ then $w^{-1} = \\dash a \\dash b' \\dash.$
\\end{enumerate}
\\end{lemma}

\\begin{proof}
This is equivalent to \\cite[Theorem 7.6]{M}.
\\end{proof}

Fix integers $i < j$ that are not congruent modulo $n$.
Let $t=t_{ij} \\in \\tilde S_n$ denote the reflection
that interchanges $i$ and $j$ while fixing all integers not congruent to
$i$ or $j$ modulo $n$.
Write $\\lessdot$ for the covering relation in the Bruhat order on $\\tilde S_n$.

\\begin{lemma}
One has $w \\lessdot wt$
if and only if the following property holds:
\\begin{enumerate}
\\item[(T)] $w^{-1} = \\dash i \\dash j \\dash$ but if $i<e<j$
then $w^{-1} \\neq \\dash i \\dash e \\dash j\\dash$.
\\end{enumerate}
Moreover, if $i\'$ and $j\'$ are integers with $i-i\' = j-j\' \\in n\\ZZ$,
then property (T) is equivalent to the following:
\\begin{enumerate}
\\item[(U)] $w^{-1} = \\dash i\' \\dash j\' \\dash$ but if $i\'<e<j\'$
then $w^{-1} \\neq \\dash i\' \\dash e \\dash j\'\\dash$.
\\end{enumerate}
\\end{lemma}

\\begin{proof}
This is equivalent to \\cite[Proposition 8.3.6]{BB}.
\\end{proof}

Recall the definition of the operator $\\tau^n_{ij}$ from \\cite[\\S8]{M} and
let $z = z^{-1} = \\tau^n_{ij}(y) \\in \\tilde S_n$.

\\begin{theorem}
Assume $\\{i, y_i\\} + n \\ZZ$ and $\\{j,y_j\\} + n \\ZZ$ are disjoint.
If $y \\neq z$, $w \\in \\mathcal{A}(y)$, and $w\\lessdot wt$, then $wt \\in \\mathcal{A}(z)$.
\\end{theorem}

The proof of this statement occupies the rest of this computer-generated document.
\\begin{proof}
Assume that  $\\{i, y_i\\} + n \\ZZ$ and $\\{j,y_j\\} + n \\ZZ$ are disjoint
and that $y \\neq z$ and $w \\in \\mathcal{A}(y)$ and $w\\lessdot wt$.
Observe that if $i \\neq y_i$ then the sets $i + n\\ZZ$ and $y_i + n \\ZZ$ are disjoint,
and that if $j \\neq y_j$ then the sets $j + n\\ZZ$ and $y_j + n\\ZZ$ are disjoint.

To show that $wt \\in \\mathcal{A}(z)$, it suffices by Lemma~\\ref{lem-1} to check that if
$(a,b),(a',b') \\in \\Cyc(z)$ then the following properties hold:
\\begin{enumerate}
\\item[(Z1)] If $a < b$ then $(wt)^{-1} = \\dash b \\dash a \\dash$.
\\item[(Z2)] If $a < a' \\leq b' < b$ then $(wt)^{-1} \\neq \\dash b \\dash a' \\dash a \\dash$
and $(wt)^{-1}\\neq \\dash b \\dash b' \\dash a.$
\\item[(Z3)] If $a < a'$ and $b < b'$ then $(wt)^{-1} = \\dash a \\dash b' \\dash.$
\\end{enumerate}
Let $E = \\{i, j, y_i, y_j\\}$.
Then $w_a = (wt)_a$ and $y_a = z_a$ for all integers $a \\notin E + n\\ZZ$,
and we may decompose $\\Cyc(z)$ as a disjoint union of four subsets
$
\\Cyc(z) = \\Cyc^1(z) \\sqcup \\Cyc^2(z) \\sqcup \\Cyc^3(z)
$
where
\\[
\\begin{aligned}
\\Cyc^1(z) &= \\{ (a,b) \\in \\Cyc(z): a,b \\in E\\},\\\\
\\Cyc^2(z) &= \\{ (a,b) \\in \\Cyc(y): a,b \\notin E + n\\ZZ\\} =
              \\{ (a,b) \\in \\Cyc(z): a,b \\notin E + n\\ZZ\\},\\\\
\\Cyc^3(z) &= \\{ (a+mn,b+mn): 0 \\neq m \\in \\ZZ\\text{ and }(a,b)\\in \\Cyc^1(z)\\}.
\\end{aligned}
\\]
When $(a,b),(a',b') \\in \\Cyc^2(z)\\subset \\Cyc(y)$,
properties (Z1)-(Z3) are equivalent to (Y1)-(Y3)
and therefore hold since $w \\in \\mathcal{A}(y)$.
It remains to check properties (Z1)-(Z3) in the following cases:
\\begin{itemize}
\\item[(i)] When $(a,b),(a',b') \\in \\Cyc^1(z)$.
\\item[(ii)] When one of the pairs $(a,b)$, $(a',b')$ belongs to $\\Cyc^1(z)$
             while the other belongs to $\\Cyc^2(z)$.
\\item[(iii)] When $(a,b) \\in \\Cyc^1(z)$ and $(a',b') \\in \\Cyc^3(z)$,
              or $(a',b') \\in \\Cyc^1(z)$ and $(a,b) \\in \\Cyc^3(z)$.
\\end{itemize}
Since we assume $z = \\tau^n_{ij}(y) \\neq y$,
there are twelve possibilities for the relative orders of $i$, $j$, $y_i$, and $y_j$.
We examine each of these possibilities in turn and check directly that
properties (Z1)-(Z3) hold in cases (i), (ii), and (iii).
"""
        ]

        for y in VirtualInvolution.all(maximum_size=4, mimimal_type=True):
            for i, j in itertools.combinations(range(1, y.rank + 1), 2):
                if y.tau(i, j) != y:
                    self.y = y
                    self.i = i
                    self.j = j
                    self._tex_involution_analysis()

        self.lines += [
            """
\\section{Conclusion}
It follows from this exhaustive case analysis
that properties (Z1)-(Z3) hold for all pairs $(a,b),(a\',b\') \\in \\Cyc(z)$.
We conclude by Lemma~\\ref{lem-1} that $wt \\in \\mathcal{A}(z)$.
This completes the proof of the theorem.
\\end{proof}

\\begin{thebibliography}{99}

\\bibitem{BB} A. Bj\\"orner and F. Brenti,
\\emph{Combinatorics of Coxeter groups},
Graduate Texts in Mathematics 231, Springer, New York, 2005.

\\bibitem{M} E. Marberg,
On some actions of the $0$-Hecke monoids of affine symmetric groups,
\\emph{J. Combin. Theory Ser. A} \\textbf{161} (2019), 178--219.

\\end{thebibliography}

\\end{document}
"""
        ]