-
-
Notifications
You must be signed in to change notification settings - Fork 655
Closed
Milestone
Description
sage: p = SkewPartition([[],[]])
sage: latex(p)
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
Input In [9], in <cell line: 1>()
----> 1 latex(p)
File ~/sage-develop/src/sage/misc/latex.py:929, in LatexCall.__call__(self, x, combine_all)
898 r"""
899 Return a :class:`LatexExpr` built out of the argument ``x``.
900
(...)
926 x 2
927 """
928 if has_latex_attr(x):
--> 929 return LatexExpr(x._latex_())
930 try:
931 f = latex_table[type(x)]
File ~/sage-develop/src/sage/combinat/skew_partition.py:254, in SkewPartition._latex_(self)
235 def _latex_(self):
236 r"""
237 Return a `\LaTeX` representation of ``self``.
238
(...)
252 }
253 """
--> 254 return self.parent().options._dispatch(self, '_latex_', 'latex')
File ~/sage-develop/src/sage/structure/global_options.py:1690, in GlobalOptions._dispatch(self, obj, dispatch_to, option, *args, **kargs)
1688 dispatch_to = dispatch_to[:-1]
1689 dispatch = getattr(obj, dispatch_to + '_' + self._value[option])
-> 1690 return dispatch(*args, **kargs)
1692 raise ValueError('%s is not a dispatchable option!' % option)
File ~/sage-develop/src/sage/combinat/skew_partition.py:306, in SkewPartition._latex_young_diagram(self)
304 for j in range(skew_size):
305 arr[i][j] = None
--> 306 return tex_from_array(arr)
File ~/sage-develop/src/sage/combinat/output.py:175, in tex_from_array(array, with_lines)
173 lr=lr_macro.substitute(bar='|' if with_lines else '')
174 if Tableaux.options.convention == "English":
--> 175 return '{%s\n%s\n}' % (lr, tex_from_skew_array(array, with_lines))
176 else:
177 return '{%s\n%s\n}' % (lr, tex_from_skew_array(array[::-1], with_lines, align='t'))
File ~/sage-develop/src/sage/combinat/output.py:309, in tex_from_skew_array(array, with_lines, align)
306 end_line=lambda r: r'\\'
308 # now we draw the array
--> 309 tex=r'\raisebox{-.6ex}{$\begin{array}[%s]{*{%s}c}'%(align,max(map(len,array)))
310 tex+=end_line(0)+'\n'
311 for r in range(len(array)):
ValueError: max() arg is an empty sequence
CC: @stumpc5
Component: combinatorics
Keywords: findstat
Author: Martin Rubey
Branch/Commit: 249ce49
Reviewer: Christian Stump
Issue created by migration from https://trac.sagemath.org/ticket/34760