def __init__(self, parent, list=[[]], **options):
        r"""
        Construct a TensorProductOfKirillovReshetikhinTableauxElement.

        INPUT:

        - ``parent`` -- Parent for this element

        - ``list``   -- The list of KR tableaux elements

        EXAMPLES::

            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['A', 3, 1], [[1, 1], [2, 1], [1, 1], [2, 1], [2, 1], [2, 1]])
            sage: T = KRT(pathlist=[[2], [4, 1], [3], [4, 2], [3, 1], [2, 1]])
            sage: T
            [[2]] (X) [[1], [4]] (X) [[3]] (X) [[2], [4]] (X) [[1], [3]] (X) [[1], [2]]
            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['A', 3, 1], [[3,3], [2,1]])
            sage: T = KRT(pathlist=[[3, 2, 1, 4, 2, 1, 4, 3, 1], [2, 1]])
            sage: T
            [[1, 1, 1], [2, 2, 3], [3, 4, 4]] (X) [[1], [2]]
            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['D', 4, 1], [[2, 1], [1, 1], [1, 1], [1, 1]])
            sage: T = KRT(pathlist=[[3,2], [1], [-1], [1]])
            sage: T
            [[2], [3]] (X) [[1]] (X) [[-1]] (X) [[1]]
            sage: TestSuite(T).run()
        """
        if "pathlist" in options:
            pathlist = options["pathlist"]
            TensorProductOfRegularCrystalsElement.__init__(
                self, parent,
                [parent.crystals[i](*tab) for i, tab in enumerate(pathlist)])
        else:
            TensorProductOfRegularCrystalsElement.__init__(self, parent, list)
    def __init__(self, parent, list=[[]], **options):
        r"""
        Construct a TensorProductOfKirillovReshetikhinTableauxElement.

        INPUT:

        - ``parent`` -- Parent for this element

        - ``list``   -- The list of KR tableaux elements

        EXAMPLES::

            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['A', 3, 1], [[1, 1], [2, 1], [1, 1], [2, 1], [2, 1], [2, 1]])
            sage: T = KRT(pathlist=[[2], [4, 1], [3], [4, 2], [3, 1], [2, 1]])
            sage: T
            [[2]] (X) [[1], [4]] (X) [[3]] (X) [[2], [4]] (X) [[1], [3]] (X) [[1], [2]]
            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['A', 3, 1], [[3,3], [2,1]])
            sage: T = KRT(pathlist=[[3, 2, 1, 4, 2, 1, 4, 3, 1], [2, 1]])
            sage: T
            [[1, 1, 1], [2, 2, 3], [3, 4, 4]] (X) [[1], [2]]
            sage: KRT = crystals.TensorProductOfKirillovReshetikhinTableaux(['D', 4, 1], [[2, 1], [1, 1], [1, 1], [1, 1]])
            sage: T = KRT(pathlist=[[3,2], [1], [-1], [1]])
            sage: T
            [[2], [3]] (X) [[1]] (X) [[-1]] (X) [[1]]
            sage: TestSuite(T).run()
        """
        if "pathlist" in options:
            pathlist = options["pathlist"]
            TensorProductOfRegularCrystalsElement.__init__(self, parent,
              [parent.crystals[i](*tab) for i, tab in enumerate(pathlist)])
        else:
            TensorProductOfRegularCrystalsElement.__init__(self, parent, list)
Exemple #3
0
    def e(self, i):
        r"""
        Calculate the action of `e_i` on ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).e(1)
            [[1], [3], [-4], [-2]]
            sage: KRT([-1, -4, 3, 2]).e(3)
        """
        half = TensorProductOfRegularCrystalsElement.e(self, i)
        if half is None:
            return None
        return TensorProductOfRegularCrystalsElement.e(half, i)
Exemple #4
0
    def e(self, i):
        r"""
        Calculate the action of `e_i` on ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).e(1)
            [[1], [3], [-4], [-2]]
            sage: KRT([-1, -4, 3, 2]).e(3)
        """
        half = TensorProductOfRegularCrystalsElement.e(self, i)
        if half is None:
            return None
        return TensorProductOfRegularCrystalsElement.e(half, i)
Exemple #5
0
    def __init__(self, parent, list, **options):
        r"""
        Initialize ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['A', 4, 1], 2, 1)
            sage: elt = KRT([4, 3]); elt
            [[3], [4]]
            sage: TestSuite(elt).run()
        """
        # Make sure we are a list of letters
        if list != [] and type(list[0]) is not parent.letters.element_class:
            list = [parent.letters(x) for x in list]
        TensorProductOfRegularCrystalsElement.__init__(self, parent, list)
Exemple #6
0
    def __init__(self, parent, list, **options):
        r"""
        Initialize ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['A', 4, 1], 2, 1)
            sage: elt = KRT([4, 3]); elt
            [[3], [4]]
            sage: TestSuite(elt).run()
        """
        # Make sure we are a list of letters
        if list != [] and type(list[0]) is not parent.letters.element_class:
            list = [parent.letters(x) for x in list]
        TensorProductOfRegularCrystalsElement.__init__(self, parent, list)
Exemple #7
0
    def f(self, i):
        r"""
        Calculate the action of `f_i` on ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).f(1)
            sage: KRT([-1, -4, 3, 2]).f(3)
            [[2], [4], [-3], [-1]]
        """
        half = TensorProductOfRegularCrystalsElement.f(self, i)
        if half is None:
            return None

        return TensorProductOfRegularCrystalsElement.f(half, i)
Exemple #8
0
    def f(self, i):
        r"""
        Calculate the action of `f_i` on ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).f(1)
            sage: KRT([-1, -4, 3, 2]).f(3)
            [[2], [4], [-3], [-1]]
        """
        half = TensorProductOfRegularCrystalsElement.f(self, i)
        if half is None:
            return None

        return TensorProductOfRegularCrystalsElement.f(half, i)
Exemple #9
0
    def epsilon(self, i):
        r"""
        Compute `\epsilon_i` of ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).epsilon(1)
            1
            sage: KRT([-1, -4, 3, 2]).epsilon(3)
            0
        """
        return TensorProductOfRegularCrystalsElement.epsilon(self, i) / 2
Exemple #10
0
    def phi(self, i):
        r"""
        Compute `\phi_i` of ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).phi(1)
            0
            sage: KRT([-1, -4, 3, 2]).phi(3)
            1
        """
        return TensorProductOfRegularCrystalsElement.phi(self, i) / 2
Exemple #11
0
    def epsilon(self, i):
        r"""
        Compute `\epsilon_i` of ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).epsilon(1)
            1
            sage: KRT([-1, -4, 3, 2]).epsilon(3)
            0
        """
        return TensorProductOfRegularCrystalsElement.epsilon(self, i) / 2
Exemple #12
0
    def phi(self, i):
        r"""
        Compute `\phi_i` of ``self``.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 4, 1)
            sage: KRT([-1, -4, 3, 2]).phi(1)
            0
            sage: KRT([-1, -4, 3, 2]).phi(3)
            1
        """
        return TensorProductOfRegularCrystalsElement.phi(self, i) / 2
Exemple #13
0
    def f(self, i):
        r"""
        Return the action of `f_i` on ``self``.

        EXAMPLES::

            sage: KRT = TensorProductOfKirillovReshetikhinTableaux(['D', 4, 1], [[2,1]])
            sage: T = KRT(pathlist=[[4,3]])
            sage: T.f(1)
            sage: T.f(4)
            [[-4], [4]]
        """
        if i != 0:
            return TensorProductOfRegularCrystalsElement.f(self, i)

        return None
Exemple #14
0
        def weight(self):
            """
            Return the weight of ``self``.

            EXAMPLES::

                sage: B = crystals.KirillovReshetikhin(['A',2,1], 1,1)
                sage: P = RootSystem(['A',2,1]).weight_lattice(extended=True)
                sage: La = P.fundamental_weights()
                sage: C = crystals.KyotoPathModel(B, La[0])
                sage: mg = C.module_generators[0]
                sage: mg.weight()
                Lambda[0]
                sage: mg.f_string([0,1,2]).weight()
                Lambda[0] - delta
            """
            wt = TensorProductOfRegularCrystalsElement.weight(self)
            return wt + self[-1].Epsilon()
        def weight(self):
            """
            Return the weight of ``self``.

            EXAMPLES::

                sage: B = crystals.KirillovReshetikhin(['A',2,1], 1,1)
                sage: P = RootSystem(['A',2,1]).weight_lattice(extended=True)
                sage: La = P.fundamental_weights()
                sage: C = crystals.KyotoPathModel(B, La[0])
                sage: mg = C.module_generators[0]
                sage: mg.weight()
                Lambda[0]
                sage: mg.f_string([0,1,2]).weight()
                Lambda[0] - delta
            """
            wt = TensorProductOfRegularCrystalsElement.weight(self)
            return wt + self[-1].Epsilon()
Exemple #16
0
    def f(self, i):
        """
        Perform the action of `f_i` on ``self``.

        .. TODO::

            Implement a direct action of `f_0` without moving to KR crystals.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 2,2)
            sage: KRT.module_generators[0].f(0)
            [[1, 1], [2, -1]]
        """
        if i == 0:
            ret = self.to_Kirillov_Reshetikhin_crystal().f0()
            if ret is None:
                return None
            return ret.to_Kirillov_Reshetikhin_tableau()
        return TensorProductOfRegularCrystalsElement.f(self, i)
Exemple #17
0
    def f(self, i):
        """
        Perform the action of `f_i` on ``self``.

        .. TODO::

            Implement a direct action of `f_0` without moving to KR crystals.

        EXAMPLES::

            sage: KRT = KirillovReshetikhinTableaux(['D',4,1], 2,2)
            sage: KRT.module_generators[0].f(0)
            [[1, 1], [2, -1]]
        """
        if i == 0:
            ret = self.to_Kirillov_Reshetikhin_crystal().f0()
            if ret is None:
                return None
            return ret.to_Kirillov_Reshetikhin_tableau()
        return TensorProductOfRegularCrystalsElement.f(self, i)