code
stringlengths
17
6.64M
class SymmetricGroupRepresentations_class(UniqueRepresentation, Parent): '\n Generic methods for the CombinatorialClass of irreducible\n representations of the symmetric group.\n ' def __init__(self, n, ring=None, cache_matrices=True): '\n Irreducible representations of the symmetric ...
class YoungRepresentation_generic(SymmetricGroupRepresentation_generic_class): "\n Generic methods for Young's representations of the symmetric group.\n " @lazy_attribute def _yang_baxter_graph(self): '\n Return the Yang-Baxter graph associated with the representation,\n with ...
class YoungRepresentation_Seminormal(YoungRepresentation_generic): def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: SymmetricGroupRepresentation([2,1], "seminormal")\n Seminormal representation of the symmetric group corresponding to [2...
class YoungRepresentations_Seminormal(SymmetricGroupRepresentations_class): _default_ring = QQ Element = YoungRepresentation_Seminormal def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: from sage.combinat.symmetric_group_representations imp...
class YoungRepresentation_Orthogonal(YoungRepresentation_generic): def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: SymmetricGroupRepresentation([2,1], "orthogonal") # needs sage.symbolic\n Orthogonal representation ...
class YoungRepresentations_Orthogonal(SymmetricGroupRepresentations_class): _default_ring = SR Element = YoungRepresentation_Orthogonal def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: from sage.combinat.symmetric_group_representations imp...
class SpechtRepresentation(SymmetricGroupRepresentation_generic_class): def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: SymmetricGroupRepresentation([2,1], "specht")\n Specht representation of the symmetric group corresponding to [2, 1...
class SpechtRepresentations(SymmetricGroupRepresentations_class): _default_ring = ZZ Element = SpechtRepresentation def _repr_(self): '\n String representation of ``self``.\n\n EXAMPLES::\n\n sage: spc = SymmetricGroupRepresentations(4)\n sage: spc\n ...
def partition_to_vector_of_contents(partition, reverse=False): '\n Return the "vector of contents" associated to ``partition``.\n\n EXAMPLES::\n\n sage: from sage.combinat.symmetric_group_representations import partition_to_vector_of_contents\n sage: partition_to_vector_of_contents([3,2])\n ...
def _nonperiodic_autocorrelation(sequences, j): '\n Compute the nonperiodic autocorrelation of a familiy of sequences.\n\n Namely, given a family of sequences `X` it computes:\n\n .. MATH::\n\n N_X(j) = \\sum_{i=1}^{n-j}(a_{1,i}a_{1,i+j} + a_{2,i}a_{2,i+j} + ... + a_{n,i}a_{n,i+j})\n\n INPUT:\n...
def is_skew(seq, verbose=False): '\n Check if the given sequence is skew.\n\n A sequence `X=\\{x_1, x_2, ...,x_n\\}` is defined skew (according to Definition\n 7.4 of [Seb2017]_) if `n` is even and `x_i = -x_{n-i+1}`.\n\n INPUT:\n\n - ``seq`` -- the sequence that should be checked.\n\n - ``verbo...
def is_symmetric(seq, verbose=False) -> bool: '\n Check if the given sequence is symmetric.\n\n A sequence `X=\\{x_1, x_2, ...,x_n\\}` is defined symmetric (according to Definition\n 7.4 of [Seb2017]_) if `n` is odd and `x_i = x_{n-i+1}`.\n\n INPUT:\n\n - ``seq`` -- the sequence that should be chec...
def is_T_sequences_set(sequences, verbose=False): '\n Check if a family of sequences is composed of T-sequences.\n\n Given 4 (-1, 0, +1) sequences, they will be T-sequences if\n (Definition 7.4 of [Seb2017]_):\n\n * they have all the same length `t`\n * for each index `i`, exactly one sequence is n...
def turyn_sequences_smallcases(l, existence=False): '\n Construction of Turyn sequences for small values of `l`.\n\n The data is taken from [Seb2017]_ and [CRSKKY1989]_.\n\n INPUT:\n\n - ``l`` -- integer, the length of the Turyn sequences.\n\n - ``existence`` -- boolean (default False). If true, on...
def T_sequences_construction_from_base_sequences(base_sequences, check=True): '\n Construct T-sequences of length `2n+p` from base sequences of length `n+p, n+p, n, n`.\n\n Given base sequences `A, B, C, D`, the T-sequences are constructed as described in\n [KTR2005]_:\n\n .. MATH::\n\n \\begin...
def T_sequences_construction_from_turyn_sequences(turyn_sequences, check=True): '\n Construct T-sequences of length `4l-1` from Turyn sequences of length `l`.\n\n Given Turyn sequences `X, U, Y, V`, the T-sequences are constructed as described in\n theorem 7.7 of [Seb2017]_:\n\n .. MATH::\n\n \...
def T_sequences_smallcases(t, existence=False, check=True): '\n Construct T-sequences for some small values of `t`.\n\n This method will try to use the constructions defined in\n :func:`T_sequences_construction_from_base_sequences` and\n :func:`T_sequences_construction_from_turyn_sequences`\n toget...
def base_sequences_construction(turyn_type_seqs, check=True): 'Construct base sequences of length `2n-1, 2n-1, n, n` from Turyn type sequences of length `n,n,n,n-1`.\n\n Given Turyn type sequences `X, Y, Z, W` of length `n,n,n,n-1`, Theorem 1 of [KTR2005]_ shows that the\n following are base sequences of l...
def is_base_sequences_tuple(base_sequences, verbose=False): 'Check if the given sequences are base sequences.\n\n Four (-1, +1) sequences `A, B, C, D` of length `n+p, n+p, n, n` are called base sequences if\n for all `j \\ge 1`:\n\n .. MATH::\n\n N_A(j)+N_B(j)+N_C(j)+N_D(j) = 0\n\n where `N_X(j...
def turyn_type_sequences_smallcases(n, existence=False): '\n Construction of Turyn type sequences for small values of `n`.\n\n The data is taken from [KTR2005]_ for `n= 36`, and from [BDKR2013]_ for `n\\le 32`.\n\n INPUT:\n\n - ``n`` -- integer, the length of the Turyn type sequences.\n\n - ``exist...
def base_sequences_smallcases(n, p, existence=False, check=True): 'Construct base sequences of length `n+p, n+p, n, n` from available data.\n\n The function uses the construction :func:`base_sequences_construction`, together with\n Turyn type sequences from :func:`turyn_type_sequences_smallcases` to constru...
@richcmp_method class Tableau(ClonableList, metaclass=InheritComparisonClasscallMetaclass): "\n A class to model a tableau.\n\n INPUT:\n\n - ``t`` -- a Tableau, a list of iterables, or an empty list\n\n OUTPUT:\n\n - A Tableau object constructed from ``t``.\n\n A tableau is abstractly a mapping ...
class SemistandardTableau(Tableau): '\n A class to model a semistandard tableau.\n\n INPUT:\n\n - ``t`` -- a tableau, a list of iterables, or an empty list\n\n OUTPUT:\n\n - A SemistandardTableau object constructed from ``t``.\n\n A semistandard tableau is a tableau whose entries are positive in...
class RowStandardTableau(Tableau): '\n A class to model a row standard tableau.\n\n A row standard tableau is a tableau whose entries are\n positive integers from 1 to `m` that increase along rows.\n\n INPUT:\n\n - ``t`` -- a Tableau, a list of iterables, or an empty list\n\n EXAMPLES::\n\n ...
class StandardTableau(SemistandardTableau): '\n A class to model a standard tableau.\n\n INPUT:\n\n - ``t`` -- a Tableau, a list of iterables, or an empty list\n\n A standard tableau is a semistandard tableau whose entries are exactly the\n positive integers from 1 to `n`, where `n` is the size of ...
def from_chain(chain): '\n Return a semistandard tableau from a chain of partitions.\n\n EXAMPLES::\n\n sage: from sage.combinat.tableau import from_chain\n sage: from_chain([[], [2], [2, 1], [3, 2, 1]])\n [[1, 1, 3], [2, 3], [3]]\n ' res = [([0] * chain[(- 1)][i]) for i in range...
def from_shape_and_word(shape, w, convention='French'): '\n Return a tableau from a shape and word.\n\n INPUT:\n\n - ``shape`` -- a partition\n\n - ``w`` -- a word whose length equals that of the partition\n\n - ``convention`` -- a string which can take values ``"French"`` or\n ``"English"``; ...
class IncreasingTableau(Tableau): '\n A class to model an increasing tableau.\n\n INPUT:\n\n - ``t`` -- a tableau, a list of iterables, or an empty list\n\n An *increasing tableau* is a tableau whose entries are positive\n integers that are strictly increasing across rows and strictly\n increasi...
class Tableaux(UniqueRepresentation, Parent): "\n A factory class for the various classes of tableaux.\n\n INPUT:\n\n - ``n`` (optional) -- a non-negative integer\n\n OUTPUT:\n\n - If ``n`` is specified, the class of tableaux of size ``n``. Otherwise,\n the class of all tableaux.\n\n A tabl...
class Tableaux_all(Tableaux): def __init__(self): '\n Initializes the class of all tableaux\n\n TESTS::\n\n sage: T = sage.combinat.tableau.Tableaux_all()\n sage: TestSuite(T).run()\n ' super().__init__(category=Sets()) def _repr_(self): "\n...
class Tableaux_size(Tableaux): '\n Tableaux of a fixed size `n`.\n ' def __init__(self, n): '\n Initializes the class of tableaux of size ``n``.\n\n TESTS::\n\n sage: T = sage.combinat.tableau.Tableaux_size(3)\n sage: TestSuite(T).run()\n\n sage: T...
class SemistandardTableaux(Tableaux): '\n A factory class for the various classes of semistandard tableaux.\n\n INPUT:\n\n Keyword arguments:\n\n - ``size`` -- The size of the tableaux\n - ``shape`` -- The shape of the tableaux\n - ``eval`` -- The weight (also called content or evaluation) of\n ...
class SemistandardTableaux_all(SemistandardTableaux, DisjointUnionEnumeratedSets): '\n All semistandard tableaux.\n ' def __init__(self, max_entry=None): '\n Initializes the class of all semistandard tableaux.\n\n .. WARNING::\n\n Input is not checked; please use :class...
class SemistandardTableaux_size_inf(SemistandardTableaux): '\n Semistandard tableaux of fixed size `n` with no maximum entry.\n ' def __init__(self, n): '\n Initialize the class of semistandard tableaux of size ``n`` with no\n maximum entry.\n\n .. WARNING::\n\n ...
class SemistandardTableaux_shape_inf(SemistandardTableaux): '\n Semistandard tableaux of fixed shape `p` and no maximum entry.\n ' def __init__(self, p): "\n Initializes the class of semistandard tableaux of shape ``p`` and no\n maximum entry.\n\n .. WARNING::\n\n ...
class SemistandardTableaux_size(SemistandardTableaux): '\n Semistandard tableaux of fixed size `n`.\n ' def __init__(self, n, max_entry=None): "\n Initializes the class of semistandard tableaux of size ``n``.\n\n .. WARNING::\n\n Input is not checked; please use :class:...
class SemistandardTableaux_shape(SemistandardTableaux): '\n Semistandard tableaux of fixed shape `p` with a given max entry.\n\n A semistandard tableau with max entry `i` is required to have all\n its entries less or equal to `i`. It is not required to actually\n contain an entry `i`.\n\n INPUT:\n\...
class SemistandardTableaux_shape_weight(SemistandardTableaux_shape): '\n Semistandard tableaux of fixed shape `p` and weight `\\mu`.\n ' def __init__(self, p, mu): '\n Initializes the class of all semistandard tableaux of shape ``p`` and\n weight ``mu``.\n\n .. WARNING::\n\...
class SemistandardTableaux_size_weight(SemistandardTableaux): '\n Semistandard tableaux of fixed size `n` and weight `\\mu`.\n ' def __init__(self, n, mu): '\n Initializes the class of semistandard tableaux of size ``n`` and\n weight ``mu``.\n\n .. WARNING::\n\n ...
class RowStandardTableaux(Tableaux): '\n A factory for the various classes of row standard tableaux.\n\n INPUT:\n\n - either a non-negative integer (possibly specified with the keyword\n ``n``) or a partition\n\n OUTPUT:\n\n - with no argument, the class of all standard tableaux\n\n - with ...
class RowStandardTableaux_all(RowStandardTableaux, DisjointUnionEnumeratedSets): '\n All row standard tableaux.\n ' def __init__(self): '\n Initializes the class of all standard tableaux.\n\n .. WARNING::\n\n Input is not checked; please use :class:`RowStandardTableaux`...
class RowStandardTableaux_size(RowStandardTableaux, DisjointUnionEnumeratedSets): '\n Row standard tableaux of fixed size `n`.\n\n EXAMPLES::\n\n sage: [t for t in RowStandardTableaux(1)] # needs sage.graphs\n [[[1]]]\n sage: [t for t in RowStandard...
class RowStandardTableaux_shape(RowStandardTableaux): '\n Row Standard tableaux of a fixed shape `p`.\n ' def __init__(self, p): '\n Initializes the class of all row standard tableaux of a given shape.\n\n .. WARNING::\n\n Input is not checked; please use :class:`RowSta...
class StandardTableaux(SemistandardTableaux): '\n A factory for the various classes of standard tableaux.\n\n INPUT:\n\n - Either a non-negative integer (possibly specified with the keyword ``n``)\n or a partition.\n\n OUTPUT:\n\n - With no argument, the class of all standard tableaux\n\n -...
class StandardTableaux_all(StandardTableaux, DisjointUnionEnumeratedSets): '\n All standard tableaux.\n ' def __init__(self): '\n Initializes the class of all standard tableaux.\n\n TESTS::\n\n sage: ST = StandardTableaux()\n sage: TestSuite(ST).run()\n ...
class StandardTableaux_size(StandardTableaux, DisjointUnionEnumeratedSets): '\n Standard tableaux of fixed size `n`.\n\n EXAMPLES::\n\n sage: [ t for t in StandardTableaux(1) ]\n [[[1]]]\n sage: [ t for t in StandardTableaux(2) ]\n [[[1, 2]], [[1], [2]]]\n sage: [ t for t ...
class StandardTableaux_shape(StandardTableaux): '\n Semistandard tableaux of a fixed shape `p`.\n ' def __init__(self, p): '\n Initializes the class of all semistandard tableaux of a given shape.\n\n .. WARNING::\n\n Input is not checked; please use :class:`StandardTabl...
def unmatched_places(w, open, close): '\n Given a word ``w`` and two letters ``open`` and\n ``close`` to be treated as opening and closing\n parentheses (respectively), return a pair ``(xs, ys)``\n that encodes the positions of the unmatched\n parentheses after the standard parenthesis matching\n ...
def symmetric_group_action_on_values(word, perm): '\n Return the image of the word ``word`` under the\n Lascoux-Schuetzenberger action of the permutation\n ``perm``.\n\n See :meth:`Tableau.symmetric_group_action_on_values`\n for the definition of the Lascoux-Schuetzenberger\n action on semistand...
class Tableau_class(Tableau): '\n This exists solely for unpickling ``Tableau_class`` objects.\n ' def __setstate__(self, state): '\n Unpickle old ``Tableau_class`` objects.\n\n TESTS::\n\n sage: loads(b\'x\\x9ck`J.NLO\\xd5K\\xce\\xcfM\\xca\\xccK,\\xd1+IL\\xcaIM,\\xe5\\...
class IncreasingTableaux(Tableaux): "\n A factory class for the various classes of increasing tableaux.\n\n An *increasing tableau* is a tableau whose entries are positive\n integers that are strictly increasing across rows and strictly\n increasing down columns. Note that Sage uses the English conven...
class IncreasingTableaux_all(IncreasingTableaux, DisjointUnionEnumeratedSets): '\n All increasing tableaux.\n\n EXAMPLES::\n\n sage: T = IncreasingTableaux()\n sage: T.cardinality()\n +Infinity\n\n sage: T = IncreasingTableaux(max_entry=3)\n sage: list(T)\n [[],\n ...
class IncreasingTableaux_size_inf(IncreasingTableaux): '\n Increasing tableaux of fixed size `n` with no maximum entry.\n ' def __init__(self, n): '\n Initializes the class of increasing tableaux of size ``n`` with no\n maximum entry.\n\n .. WARNING::\n\n Input i...
class IncreasingTableaux_shape_inf(IncreasingTableaux): '\n Increasing tableaux of fixed shape `p` and no maximum entry.\n ' def __init__(self, p): "\n Initializes the class of increasing tableaux of shape ``p`` and no\n maximum entry.\n\n .. WARNING::\n\n Input ...
class IncreasingTableaux_size(IncreasingTableaux): '\n Increasing tableaux of fixed size `n`.\n ' def __init__(self, n, max_entry=None): "\n Initializes the class of increasing tableaux of size ``n``.\n\n .. WARNING::\n\n Input is not checked; please use :class:`Increas...
class IncreasingTableaux_shape(IncreasingTableaux): '\n Increasing tableaux of fixed shape `p` with a given max entry.\n\n An increasing tableau with max entry `i` is required to have all\n its entries less or equal to `i`. It is not required to actually\n contain an entry `i`.\n\n INPUT:\n\n - ...
class IncreasingTableaux_shape_weight(IncreasingTableaux_shape): '\n Increasing tableaux of fixed shape `p` and binary weight `wt`.\n ' def __init__(self, p, wt): '\n Initializes the class of all increasing tableaux of shape ``p`` and\n weight ``mu``.\n\n .. WARNING::\n\n ...
class IncreasingTableaux_size_weight(IncreasingTableaux): '\n Increasing tableaux of fixed size `n` and weight `wt`.\n ' def __init__(self, n, wt): '\n Initializes the class of increasing tableaux of size ``n`` and\n weight ``wt``.\n\n .. WARNING::\n\n Input is n...
class ResidueSequence(ClonableArray, metaclass=InheritComparisonClasscallMetaclass): "\n A residue sequence.\n\n The *residue sequence* of a tableau `t` (of partition or partition tuple\n shape) is the sequence `(i_1, i_2, \\ldots, i_n)` where `i_k` is the\n residue of `l` in `t`, for `k = 1, 2, \\ldo...
class ResidueSequences(UniqueRepresentation, Parent): "\n A parent class for :class:`ResidueSequence`.\n\n This class exists because :class:`ResidueSequence` needs to have a parent.\n Apart form being a parent the only useful method that it provides is\n :meth:`cell_residue`, which is a short-hand for...
class TableauTuple(CombinatorialElement): "\n A class to model a tuple of tableaux.\n\n INPUT:\n\n - ``t`` -- a list or tuple of :class:`Tableau`, a list or tuple of lists\n of lists\n\n OUTPUT:\n\n - The Tableau tuple object constructed from ``t``.\n\n A :class:`TableauTuple` is a tuple of...
class RowStandardTableauTuple(TableauTuple, metaclass=ClasscallMetaclass): '\n A class for row standard tableau tuples of shape a partition tuple.\n\n A row standard tableau tuple of size `n` is an ordered tuple of row\n standard tableaux (see :class:`RowStandardTableau`), with entries `1, 2,\n \\ldot...
class StandardTableauTuple(RowStandardTableauTuple): '\n A class to model a standard tableau of shape a partition tuple. This is\n a tuple of standard tableau with entries `1, 2, \\ldots, n`, where `n`\n is the size of the underlying partition tuple, such that the entries\n increase along rows and dow...
class TableauTuples(UniqueRepresentation, Parent): "\n A factory class for the various classes of tableau tuples.\n\n INPUT:\n\n There are three optional arguments:\n\n - ``shape`` -- determines a :class:`PartitionTuple` which gives the shape\n of the :class:`TableauTuples`\n\n - ``level`` -- ...
class TableauTuples_all(TableauTuples): '\n The parent class of all :class:`TableauTuples`, with arbitrary ``level``\n and ``size``.\n ' def __init__(self): '\n Initializes the class of all tableaux.\n\n EXAMPLES::\n\n sage: TableauTuples()\n Tableau tuple...
class TableauTuples_level(TableauTuples): '\n Class of all :class:`TableauTuples` with a fixed ``level`` and arbitrary\n ``size``.\n ' def __init__(self, level): '\n Initializes the class of tableaux of level ``level``.\n\n EXAMPLES::\n\n sage: TableauTuples(level=4)...
class TableauTuples_size(TableauTuples): '\n Class of all :class:`TableauTuples` with a arbitrary ``level`` and fixed\n ``size``.\n ' def __init__(self, size): '\n Initializes the class of tableaux of size ``size``.\n\n EXAMPLES::\n\n sage: TableauTuples(size=6)\n ...
class TableauTuples_level_size(TableauTuples): '\n Class of all :class:`TableauTuples` with a fixed ``level`` and a fixed\n ``size``.\n ' def __init__(self, level, size): '\n Initializes the class of tableaux of size ``size``.\n\n EXAMPLES::\n\n sage: TableauTuples(4...
class RowStandardTableauTuples(TableauTuples): '\n A factory class for the various classes of tuples of row standard tableau.\n\n INPUT:\n\n There are three optional arguments:\n\n - ``level`` -- the :meth:`~TableauTuples.level` of the tuples of tableaux\n\n - ``size`` -- the :meth:`~TableauTuples...
class RowStandardTableauTuples_all(RowStandardTableauTuples, DisjointUnionEnumeratedSets): '\n Default class of all :class:`RowStandardTableauTuples` with an arbitrary\n :meth:`~TableauTuples.level` and :meth:`~TableauTuples.size`.\n ' def __init__(self): '\n Initializes the class of ...
class RowStandardTableauTuples_level(RowStandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`RowStandardTableauTuples` with a fixed ``level``\n and arbitrary ``size``.\n ' def __init__(self, level): '\n Initializes the class of row standard tableaux of level\n...
class RowStandardTableauTuples_size(RowStandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`RowStandardTableauTuples` with an arbitrary ``level``\n and a fixed ``size``.\n ' def __init__(self, size): '\n Initializes the class of row standard tableaux of size `...
class RowStandardTableauTuples_level_size(RowStandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`RowStandardTableauTuples` with a fixed ``level``\n and a fixed ``size``.\n ' def __init__(self, level, size): '\n Initializes the class of row standard tableaux o...
class RowStandardTableauTuples_shape(RowStandardTableauTuples): '\n Class of all :class:`RowStandardTableauTuples` of a fixed shape.\n ' def __init__(self, shape): '\n Initializes the class of row standard tableaux of shape ``p``\n and no maximum entry.\n\n .. WARNING::\n\n...
class RowStandardTableauTuples_residue(RowStandardTableauTuples): '\n Class of all row standard tableau tuples with a fixed residue sequence.\n\n Implicitly, this also specifies the quantum characteristic, multicharge\n and hence the level and size of the tableaux.\n\n .. NOTE::\n\n This class ...
class RowStandardTableauTuples_residue_shape(RowStandardTableauTuples_residue): '\n All row standard tableau tuples with a fixed residue and shape.\n\n INPUT:\n\n - ``shape`` -- the shape of the partitions or partition tuples\n - ``residue`` -- the residue sequence of the label\n\n EXAMPLES::\n\n ...
class StandardTableauTuples(RowStandardTableauTuples): '\n A factory class for the various classes of tuples of standard tableau.\n\n INPUT:\n\n There are three optional arguments:\n\n - ``level`` -- the :meth:`~TableauTuples.level` of the tuples of tableaux\n\n - ``size`` -- the :meth:`~TableauTu...
class StandardTableauTuples_all(StandardTableauTuples, DisjointUnionEnumeratedSets): '\n Default class of all :class:`StandardTableauTuples` with an arbitrary\n :meth:`~TableauTuples.level` and :meth:`~TableauTuples.size`.\n ' def __init__(self): '\n Initializes the class of all stand...
class StandardTableauTuples_level(StandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`StandardTableauTuples` with a fixed ``level``\n and arbitrary ``size``.\n ' def __init__(self, level): '\n Initialize the class of semistandard tableaux of level ``level`` o...
class StandardTableauTuples_size(StandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`StandardTableauTuples` with an arbitrary ``level``\n and a fixed ``size``.\n ' def __init__(self, size): '\n Initializes the class of semistandard tableaux of size ``size`` o...
class StandardTableauTuples_level_size(StandardTableauTuples, DisjointUnionEnumeratedSets): '\n Class of all :class:`StandardTableauTuples` with a fixed ``level`` and a\n fixed ``size``.\n ' def __init__(self, level, size): '\n Initializes the class of semistandard tableaux of level `...
class StandardTableauTuples_shape(StandardTableauTuples): '\n Class of all :class:`StandardTableauTuples` of a fixed shape.\n ' def __init__(self, shape): '\n Initializes the class of semistandard tableaux of shape ``p`` and no\n maximum entry. Input is not checked; please use\n ...
class StandardTableaux_residue(StandardTableauTuples): '\n Class of all standard tableau tuples with a fixed residue sequence.\n\n Implicitly, this also specifies the quantum characteristic, multicharge\n and hence the level and size of the tableaux.\n\n .. NOTE::\n\n This class is not intended...
class StandardTableaux_residue_shape(StandardTableaux_residue): '\n All standard tableau tuples with a fixed residue and shape.\n\n INPUT:\n\n - ``shape`` -- the shape of the partitions or partition tuples\n - ``residue`` -- the residue sequence of the label\n\n EXAMPLES::\n\n sage: res = St...
def _add_entry_fast(T, cell, m): '\n Helper function to set ``cell`` to ``m`` in ``T`` or add the\n cell to ``T`` with entry ``m``.\n\n INPUT:\n\n - ``T`` -- a tableau tuple\n - ``cell`` -- the cell\n - ``m`` -- the entry to add\n\n OUTPUT:\n\n - a list of lists of lists representing the t...
def paths_in_triangle(i, j, a, b) -> list[tuple[(int, ...)]]: '\n Return all Dyck paths from `(0,0)` to `(i,j)` in the `(a \\times\n b)`-rectangle.\n\n This means that at each step of the path, one has `a y \\geq b x`.\n\n A path is represented by a sequence of `0` and `1`, where `0` is an\n horizo...
def swap(p, i, m=1) -> tuple[(int, ...)]: '\n Perform a covering move in the `(a,b)`-Tamari lattice of parameter `m`.\n\n The letter at position `i` in `p` must be a `0`, followed by at\n least one `1`.\n\n INPUT:\n\n - ``p`` -- a Dyck path in the `(a \\times b)`-rectangle\n\n - ``i`` -- an inte...
def GeneralizedTamariLattice(a, b, m=1, check=True): '\n Return the `(a,b)`-Tamari lattice of parameter `m`.\n\n INPUT:\n\n - `a` and `b` -- coprime integers with `a \\geq b`\n\n - `m` -- a nonnegative integer such that `a \\geq b m`\n\n OUTPUT:\n\n - a finite lattice (the lattice property is on...
def TamariLattice(n, m=1): '\n Return the `n`-th Tamari lattice.\n\n Using the slope parameter `m`, one can also get the `m`-Tamari lattices.\n\n INPUT:\n\n - `n` -- a nonnegative integer (the index)\n\n - `m` -- an optional nonnegative integer (the slope, default to 1)\n\n OUTPUT:\n\n a fini...
def swap_dexter(p, i) -> list[tuple[(int, ...)]]: '\n Perform covering moves in the `(a,b)`-Dexter posets.\n\n The letter at position `i` in `p` must be a `0`, followed by at\n least one `1`.\n\n INPUT:\n\n - ``p`` -- a Dyck path in the `(a \\times b)`-rectangle\n\n - ``i`` -- an integer between...
def DexterSemilattice(n): '\n Return the `n`-th Dexter meet-semilattice.\n\n INPUT:\n\n - ``n`` -- a nonnegative integer (the index)\n\n OUTPUT:\n\n a finite meet-semilattice\n\n The elements of the semilattice are :func:`Dyck\n paths<sage.combinat.dyck_word.DyckWord>` in the `(n+1 \\times\n ...
def ncube_isometry_group(n, orientation_preserving=True): "\n Return the isometry group of the `n`-cube as a list of matrices.\n\n INPUT:\n\n - ``n`` -- positive integer, dimension of the space\n - ``orientation_preserving`` -- bool (optional, default: ``True``),\n whether the orientation is pres...
@cached_function def ncube_isometry_group_cosets(n, orientation_preserving=True): "\n Return the quotient of the isometry group of the `n`-cube by the\n the isometry group of the rectangular parallelepiped.\n\n INPUT:\n\n - ``n`` -- positive integer, dimension of the space\n - ``orientation_preserv...
class Polyomino(SageObject): "\n A polyomino in `\\ZZ^d`.\n\n The polyomino is the union of the unit square (or cube, or n-cube)\n centered at those coordinates. Such an object should be connected, but\n the code does not make this assumption.\n\n INPUT:\n\n - ``coords`` -- iterable of integer c...
class TilingSolver(SageObject): '\n Tiling solver\n\n Solve the problem of tiling a polyomino with a certain number\n of polyominoes.\n\n INPUT:\n\n - ``pieces`` -- iterable of Polyominoes\n - ``box`` -- Polyomino or tuple of integers (size of a box)\n - ``rotation`` -- bool (optional, defaul...
def transitive_ideal(f, x): '\n Return a list of all elements reachable from `x` in the abstract\n reduction system whose reduction relation is given by the function\n `f`.\n\n In more elementary terms:\n\n If `S` is a set, and `f` is a function sending every element of `S`\n to a list of elemen...
def _matrix_display(self, variables=None): "\n Return the 2-variable polynomial ``self`` as a matrix for display.\n\n INPUT:\n\n - ``variables`` -- optional choice of 2 variables\n\n OUPUT:\n\n matrix\n\n EXAMPLES::\n\n sage: from sage.combinat.triangles_FHM import _matrix_display\n ...
class Triangle(SageObject): "\n Common class for different kinds of triangles.\n\n This serves as a base class for F-triangles, H-triangles, M-triangles\n and Gamma-triangles.\n\n The user should use these subclasses directly.\n\n The input is a polynomial in two variables. One can also give a\n ...
class M_triangle(Triangle): "\n Class for the M-triangles.\n\n This is motivated by generating series of Möbius numbers of graded posets.\n\n EXAMPLES::\n\n sage: x, y = polygens(ZZ, 'x,y')\n sage: P = Poset({2: [1]}) # needs sage.graphs...
class H_triangle(Triangle): '\n Class for the H-triangles.\n ' _prefix = 'H' def transpose(self): "\n Return the transposed H-triangle.\n\n OUTPUT:\n\n another H-triangle\n\n This operation is an involution. When seen as a matrix, it\n performs a symmetry...