summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Chapoton <chapoton@math.univ-lyon1.fr>2018-06-20 16:32:01 +0200
committerFrédéric Chapoton <chapoton@math.univ-lyon1.fr>2018-06-20 16:32:01 +0200
commit7a788f7128bb012b5e53fe56bcc27c81477399ca (patch)
treee85647c216cfc5c873fa5c003c637d04967f4031
parentUpdated SageMath version to 8.3.beta6 (diff)
fix bad escape sequences in the doc of combinat folder
-rw-r--r--src/sage/combinat/abstract_tree.py4
-rw-r--r--src/sage/combinat/affine_permutation.py2
-rw-r--r--src/sage/combinat/alternating_sign_matrix.py7
-rw-r--r--src/sage/combinat/binary_tree.py12
-rw-r--r--src/sage/combinat/cartesian_product.py6
-rw-r--r--src/sage/combinat/colored_permutations.py4
-rw-r--r--src/sage/combinat/combinat.py9
-rw-r--r--src/sage/combinat/combinatorial_algebra.py7
-rw-r--r--src/sage/combinat/diagram_algebras.py5
-rw-r--r--src/sage/combinat/dyck_word.py2
-rw-r--r--src/sage/combinat/finite_state_machine.py7
-rw-r--r--src/sage/combinat/finite_state_machine_generators.py15
-rw-r--r--src/sage/combinat/free_module.py8
-rw-r--r--src/sage/combinat/fully_packed_loop.py3
-rw-r--r--src/sage/combinat/gelfand_tsetlin_patterns.py2
-rw-r--r--src/sage/combinat/interval_posets.py2
-rw-r--r--src/sage/combinat/kazhdan_lusztig.py2
-rw-r--r--src/sage/combinat/knutson_tao_puzzles.py16
-rw-r--r--src/sage/combinat/lr_tableau.py4
-rw-r--r--src/sage/combinat/non_decreasing_parking_function.py7
-rw-r--r--src/sage/combinat/partition.py4
-rw-r--r--src/sage/combinat/partition_algebra.py10
-rw-r--r--src/sage/combinat/partition_kleshchev.py4
-rw-r--r--src/sage/combinat/partition_tuple.py12
-rw-r--r--src/sage/combinat/permutation.py22
-rw-r--r--src/sage/combinat/set_partition.py6
-rw-r--r--src/sage/combinat/set_partition_ordered.py9
-rw-r--r--src/sage/combinat/similarity_class_type.py7
-rw-r--r--src/sage/combinat/skew_tableau.py7
-rw-r--r--src/sage/combinat/sloane_functions.py6
-rw-r--r--src/sage/combinat/subset.py3
-rw-r--r--src/sage/combinat/subsets_pairwise.py2
-rw-r--r--src/sage/combinat/symmetric_group_algebra.py10
-rw-r--r--src/sage/combinat/tableau.py14
34 files changed, 126 insertions, 114 deletions
diff --git a/src/sage/combinat/abstract_tree.py b/src/sage/combinat/abstract_tree.py
index 4ced7fc..0babcf4 100644
--- a/src/sage/combinat/abstract_tree.py
+++ b/src/sage/combinat/abstract_tree.py
@@ -1397,7 +1397,7 @@ class AbstractTree(object):
return "".join(["%x" % len(self)] + [u.to_hexacode() for u in self])
def tree_factorial(self):
- """
+ r"""
Return the tree-factorial of ``self``.
Definition:
@@ -1460,7 +1460,7 @@ class AbstractTree(object):
begin_env = "\\begin{tikzpicture}[auto]\n"
end_env = "\\end{tikzpicture}"
# it uses matrix trick to place each node
- matrix_begin = "\\matrix[column sep=.3cm, row sep=.3cm,ampersand replacement=\&]{\n"
+ matrix_begin = "\\matrix[column sep=.3cm, row sep=.3cm,ampersand replacement=\\&]{\n"
matrix_end = "\\\\\n};\n"
# a basic path to each edges
path_begin = "\\path[ultra thick, red] "
diff --git a/src/sage/combinat/affine_permutation.py b/src/sage/combinat/affine_permutation.py
index 8ee11ec..6ef43993 100644
--- a/src/sage/combinat/affine_permutation.py
+++ b/src/sage/combinat/affine_permutation.py
@@ -1767,7 +1767,7 @@ class AffinePermutationTypeG(AffinePermutation):
#-------------------------------------------------------------------------
def AffinePermutationGroup(cartan_type):
- """
+ r"""
Wrapper function for specific affine permutation groups.
These are combinatorial implementations of the affine Weyl groups of
diff --git a/src/sage/combinat/alternating_sign_matrix.py b/src/sage/combinat/alternating_sign_matrix.py
index 0607ccc..ce2f399 100644
--- a/src/sage/combinat/alternating_sign_matrix.py
+++ b/src/sage/combinat/alternating_sign_matrix.py
@@ -1935,12 +1935,13 @@ class ContreTableaux_n(ContreTableaux):
def _next_column_iterator(previous_column, height, i = None):
- """
+ r"""
Return a generator for all columns of height ``height``
properly filled from row 1 to ``i``.
- ("Properly filled" means strictly increasing and having
+
+ "Properly filled" means strictly increasing and having
the property that the `k`-th entry is `\geq` to the `k`-th
- entry of ``previous_column`` for each `k`.)
+ entry of ``previous_column`` for each `k`.
EXAMPLES::
diff --git a/src/sage/combinat/binary_tree.py b/src/sage/combinat/binary_tree.py
index 06c18ba..1ac89b9 100644
--- a/src/sage/combinat/binary_tree.py
+++ b/src/sage/combinat/binary_tree.py
@@ -170,7 +170,7 @@ class BinaryTree(AbstractClonableTree, ClonableArray):
return BinaryTrees_all()
def __init__(self, parent, children=None, check=True):
- """
+ r"""
TESTS::
sage: BinaryTree([None, None]).parent()
@@ -1891,7 +1891,7 @@ class BinaryTree(AbstractClonableTree, ClonableArray):
return tree
def canopee(self):
- """
+ r"""
Return the canopee of ``self``.
The *canopee* of a non-empty binary tree `T` with `n` internal nodes is
@@ -1961,7 +1961,7 @@ class BinaryTree(AbstractClonableTree, ClonableArray):
return res[1:-1]
def in_order_traversal_iter(self):
- """
+ r"""
The depth-first infix-order traversal iterator for the binary
tree ``self``.
@@ -2474,7 +2474,7 @@ class BinaryTree(AbstractClonableTree, ClonableArray):
[B([self[0], d]) for d in self[1].tamari_succ()])
def single_edge_cut_shapes(self):
- """
+ r"""
Return the list of possible single-edge cut shapes for the binary tree.
This is used in :meth:`sage.combinat.interval_posets.TamariIntervalPoset.is_new`.
@@ -4806,7 +4806,7 @@ class LabelledBinaryTree(AbstractLabelledClonableTree, BinaryTree):
return tuple(resu)
def binary_search_insert(self, letter):
- """
+ r"""
Return the result of inserting a letter ``letter`` into the
right strict binary search tree ``self``.
@@ -4906,7 +4906,7 @@ class LabelledBinaryTree(AbstractLabelledClonableTree, BinaryTree):
return LT([self[0], fils], label=self.label(), check=False)
def semistandard_insert(self, letter):
- """
+ r"""
Return the result of inserting a letter ``letter`` into the
semistandard tree ``self`` using the bumping algorithm.
diff --git a/src/sage/combinat/cartesian_product.py b/src/sage/combinat/cartesian_product.py
index 1dfb80c..ea4e5d7 100644
--- a/src/sage/combinat/cartesian_product.py
+++ b/src/sage/combinat/cartesian_product.py
@@ -240,7 +240,7 @@ class CartesianProduct_iters(EnumeratedSetFromIterator):
return "Cartesian product of " + ", ".join(map(str, self.iters))
def cardinality(self):
- """
+ r"""
Returns the number of elements in the Cartesian product of
everything in \*iters.
@@ -317,7 +317,7 @@ class CartesianProduct_iters(EnumeratedSetFromIterator):
return [e for e in self]
def __iterate__(self):
- """
+ r"""
An iterator for the elements in the Cartesian product of the
iterables \*iters.
@@ -404,7 +404,7 @@ class CartesianProduct_iters(EnumeratedSetFromIterator):
return [unrank(L, i) for L,i in zip(self.iters, positions)]
def random_element(self):
- """
+ r"""
Returns a random element from the Cartesian product of \*iters.
EXAMPLES::
diff --git a/src/sage/combinat/colored_permutations.py b/src/sage/combinat/colored_permutations.py
index 8a9627f..72676f1 100644
--- a/src/sage/combinat/colored_permutations.py
+++ b/src/sage/combinat/colored_permutations.py
@@ -753,7 +753,7 @@ class ColoredPermutations(Parent, UniqueRepresentation):
return self._n
def degrees(self):
- """
+ r"""
Return the degrees of ``self``.
The degrees of a complex reflection group are the degrees of
@@ -897,7 +897,7 @@ class ColoredPermutations(Parent, UniqueRepresentation):
return prod(q + d - 1 for d in self.degrees())
def is_well_generated(self):
- """
+ r"""
Return if ``self`` is a well-generated complex reflection group.
A complex reflection group `G` is well-generated if it is
diff --git a/src/sage/combinat/combinat.py b/src/sage/combinat/combinat.py
index dcdf1cf..8b35051 100644
--- a/src/sage/combinat/combinat.py
+++ b/src/sage/combinat/combinat.py
@@ -687,7 +687,9 @@ def stirling_number1(n, k):
This is the number of permutations of `n` points with `k` cycles.
- This wraps GAP's Stirling1.
+ This wraps GAP's ``Stirling1``.
+
+ See : wikipedia:`Stirling_numbers_of_the_first_kind`
EXAMPLES::
@@ -702,13 +704,14 @@ def stirling_number1(n, k):
Indeed, `S_1(n,k) = S_1(n-1,k-1) + (n-1)S_1(n-1,k)`.
"""
- n = ZZ(n); k = ZZ(k)
+ n = ZZ(n)
+ k = ZZ(k)
from sage.libs.gap.libgap import libgap
return libgap.Stirling1(n, k).sage()
def stirling_number2(n, k, algorithm=None):
- """
+ r"""
Return the `n`-th Stirling number `S_2(n,k)` of the second
kind (the number of ways to partition a set of `n` elements into `k`
pairwise disjoint nonempty subsets). (The `n`-th Bell number is the
diff --git a/src/sage/combinat/combinatorial_algebra.py b/src/sage/combinat/combinatorial_algebra.py
index 502331b..6f036ef 100644
--- a/src/sage/combinat/combinatorial_algebra.py
+++ b/src/sage/combinat/combinatorial_algebra.py
@@ -272,9 +272,10 @@ class CombinatorialAlgebra(CombinatorialFreeModule):
return self._coerce_try(x, [self.base_ring()])
def product(self, left, right):
- """
- Returns left\*right where left and right are elements of self.
- product() uses either _multiply or _multiply basis to carry out
+ r"""
+ Return left\*right where left and right are elements of ``self``.
+
+ ``product()`` uses either ``_multiply`` or ``_multiply basis`` to carry out
the actual multiplication.
EXAMPLES::
diff --git a/src/sage/combinat/diagram_algebras.py b/src/sage/combinat/diagram_algebras.py
index 783019e..2fd8b1e 100644
--- a/src/sage/combinat/diagram_algebras.py
+++ b/src/sage/combinat/diagram_algebras.py
@@ -1725,7 +1725,7 @@ class DiagramAlgebra(CombinatorialFreeModule):
return self[p]
def _diag_to_Blst(self, d):
- """
+ r"""
Return an element of ``self`` from the input ``d``.
If ``d`` is a partial diagram of `\{1,2,\ldots,k,-1,-2,\ldots,-k\}`
@@ -3317,8 +3317,9 @@ class TemperleyLiebAlgebra(SubPartitionAlgebra, UnitDiagramMixin):
set_partition = to_Brauer_partition(set_partition, k=self.order())
return SubPartitionAlgebra._element_constructor_(self, set_partition)
+
class PlanarAlgebra(SubPartitionAlgebra, UnitDiagramMixin):
- """
+ r"""
A planar algebra.
The planar algebra of rank `k` is an algebra with basis indexed by the
diff --git a/src/sage/combinat/dyck_word.py b/src/sage/combinat/dyck_word.py
index 127325d..d946da1 100644
--- a/src/sage/combinat/dyck_word.py
+++ b/src/sage/combinat/dyck_word.py
@@ -527,7 +527,7 @@ class DyckWord(CombinatorialElement):
row += "| "+" ."*(n-1) + labels[-1] + "\n"
return row
else:
- raise ValueError("The given type (=\s) is not valid." % type)
+ raise ValueError("The given type (=%s) is not valid." % type)
def _ascii_art_(self):
r"""
diff --git a/src/sage/combinat/finite_state_machine.py b/src/sage/combinat/finite_state_machine.py
index 468c42b..6e5ad8e 100644
--- a/src/sage/combinat/finite_state_machine.py
+++ b/src/sage/combinat/finite_state_machine.py
@@ -4930,7 +4930,7 @@ class FiniteStateMachine(sage.structure.sage_object.SageObject):
if hasattr(vertex, "accepting_where"):
angle = tikz_automata_where.get(vertex.accepting_where,
vertex.accepting_where)
- result += "\\path[->] (v%d.%.2f) edge node[%s] {$%s \mid %s$} ++(%.2f:%s);\n" % (
+ result += "\\path[->] (v%d.%.2f) edge node[%s] {$%s \\mid %s$} ++(%.2f:%s);\n" % (
j, angle,
label_rotation(angle, False),
EndOfWordLaTeX,
@@ -7445,7 +7445,7 @@ class FiniteStateMachine(sage.structure.sage_object.SageObject):
def concatenation(self, other):
- """
+ r"""
Concatenate this finite state machine with another finite
state machine.
@@ -12604,9 +12604,8 @@ class Transducer(FiniteStateMachine):
return new
-
def cartesian_product(self, other, only_accessible_components=True):
- """
+ r"""
Return a new transducer which can simultaneously process an
input with the machines ``self`` and ``other`` where the
output labels are `d`-tuples of the original output labels.
diff --git a/src/sage/combinat/finite_state_machine_generators.py b/src/sage/combinat/finite_state_machine_generators.py
index 8f60da8..e840ea3 100644
--- a/src/sage/combinat/finite_state_machine_generators.py
+++ b/src/sage/combinat/finite_state_machine_generators.py
@@ -410,9 +410,8 @@ class TransducerGenerators(object):
initial_states=[0],
final_states=[0])
-
def CountSubblockOccurrences(self, block, input_alphabet):
- """
+ r"""
Returns a transducer counting the number of (possibly
overlapping) occurrences of a block in the input.
@@ -706,7 +705,7 @@ class TransducerGenerators(object):
def all(self, input_alphabet, number_of_operands=2):
- """
+ r"""
Returns a transducer which realizes logical ``and`` over the given
input alphabet.
@@ -758,7 +757,7 @@ class TransducerGenerators(object):
def any(self, input_alphabet, number_of_operands=2):
- """
+ r"""
Returns a transducer which realizes logical ``or`` over the given
input alphabet.
@@ -810,7 +809,7 @@ class TransducerGenerators(object):
def add(self, input_alphabet, number_of_operands=2):
- """
+ r"""
Returns a transducer which realizes addition on pairs over the
given input alphabet.
@@ -865,7 +864,7 @@ class TransducerGenerators(object):
def sub(self, input_alphabet):
- """
+ r"""
Returns a transducer which realizes subtraction on pairs over
the given input alphabet.
@@ -972,7 +971,7 @@ class TransducerGenerators(object):
def abs(self, input_alphabet):
- """
+ r"""
Returns a transducer which realizes the letter-wise
absolute value of an input word over the given input alphabet.
@@ -1947,7 +1946,7 @@ class TransducerGenerators(object):
input_alphabet=input_alphabet)
def edge_recursion_digraph(n):
- """
+ r"""
Compute the list of outgoing edges of ``n`` in the recursion digraph.
INPUT:
diff --git a/src/sage/combinat/free_module.py b/src/sage/combinat/free_module.py
index a757952..1561de9 100644
--- a/src/sage/combinat/free_module.py
+++ b/src/sage/combinat/free_module.py
@@ -995,7 +995,7 @@ class CombinatorialFreeModule(UniqueRepresentation, Module, IndexedGenerators):
return self._from_dict(D, remove_zeros=False)
def linear_combination(self, iter_of_elements_coeff, factor_on_left=True):
- """
+ r"""
Return the linear combination `\lambda_1 v_1 + \cdots +
\lambda_k v_k` (resp. the linear combination `v_1 \lambda_1 +
\cdots + v_k \lambda_k`) where ``iter_of_elements_coeff`` iterates
@@ -1342,7 +1342,7 @@ class CombinatorialFreeModule_Tensor(CombinatorialFreeModule):
self._print_options['tensor_symbol'] = options.get('tensor_symbol', tensor.symbol)
def _repr_(self):
- """
+ r"""
This is customizable by setting
``self.print_options('tensor_symbol'=...)``.
@@ -1431,7 +1431,7 @@ class CombinatorialFreeModule_Tensor(CombinatorialFreeModule):
_unicode_art_term = _unicode_art_
def _latex_(self):
- """
+ r"""
TESTS::
sage: F = CombinatorialFreeModule(ZZ, [1,2,3])
@@ -1469,7 +1469,7 @@ class CombinatorialFreeModule_Tensor(CombinatorialFreeModule):
return symb.join(module._repr_term(t) for (module, t) in zip(self._sets, term))
def _latex_term(self, term):
- """
+ r"""
TESTS::
sage: F = CombinatorialFreeModule(ZZ, [1,2,3], prefix='x')
diff --git a/src/sage/combinat/fully_packed_loop.py b/src/sage/combinat/fully_packed_loop.py
index 5c0da61..0a9bd61 100644
--- a/src/sage/combinat/fully_packed_loop.py
+++ b/src/sage/combinat/fully_packed_loop.py
@@ -1048,9 +1048,8 @@ class FullyPackedLoop(Element):
else:
return orbit
-
def link_pattern(self):
- """
+ r"""
Return a link pattern corresponding to a fully packed loop.
Here we define a link pattern `LP` to be a partition of the list
diff --git a/src/sage/combinat/gelfand_tsetlin_patterns.py b/src/sage/combinat/gelfand_tsetlin_patterns.py
index 2cfc07f..97c2ded 100644
--- a/src/sage/combinat/gelfand_tsetlin_patterns.py
+++ b/src/sage/combinat/gelfand_tsetlin_patterns.py
@@ -248,7 +248,7 @@ class GelfandTsetlinPattern(ClonableArray):
@combinatorial_map(name='to semistandard tableau')
def to_tableau(self):
- """
+ r"""
Return ``self`` as a semistandard Young tableau.
The conversion from a Gelfand-Tsetlin pattern to a semistandard Young
diff --git a/src/sage/combinat/interval_posets.py b/src/sage/combinat/interval_posets.py
index a42e000..73dd24a 100644
--- a/src/sage/combinat/interval_posets.py
+++ b/src/sage/combinat/interval_posets.py
@@ -531,7 +531,7 @@ class TamariIntervalPoset(Element):
return "\\draw[line width = " + str(latex_options["line_width"]) + ", color=" + latex_options["color_decreasing"] + "] (T" + str(i) + ") -- (T" + str(j) + ");\n"
if self.size() == 0:
- nodes = "\\node(T0) at (0,0){$\emptyset$};"
+ nodes = "\\node(T0) at (0,0){$\\emptyset$};"
relations = ""