Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

There is probably no "general" xolution to your problem. breqn attempt this for "regular" mathematical expression, but I'm not convinced it would work with your case (yourv permutation elements are not regular LaTeX "math ob jects...

Possible workaround in your specific case :

sage: a=set([3, 9, 11, 23])
sage: print("\\begin{verbatim}\n%s\n\\end{verbatim}"%"\n".join([str(u) for u in Permutations(a)]))
\begin{verbatim}
[11, 9, 3, 23]
[11, 9, 23, 3]

[ Snip... ]

[23, 3, 11, 9]
[23, 3, 9, 11]
\end{verbatim}

There is probably no "general" xolution to your problem. breqn attempt this for "regular" mathematical expression, but I'm not convinced it would work with your case (yourv permutation elements are not regular LaTeX "math ob jects...

Possible workaround in your specific case :

sage: a=set([3, 9, 11, 23])
sage: print("\\begin{verbatim}\n%s\n\\end{verbatim}"%"\n".join([str(u) for u in Permutations(a)]))
\begin{verbatim}
[11, 9, 3, 23]
[11, 9, 23, 3]

[ Snip... ]

[23, 3, 11, 9]
[23, 3, 9, 11]
\end{verbatim}

Otherwise, SageTeX may be your friend...