It doesn't look like there's an easy way to do this. The only way would be
to subclass LatexPrinter and override _print_Mul. The problem is that it
uses fraction() to pull out the numerator and denominator, which
distributes the 2.

Can you open an issue for this?  The LaTeX printing should generally match
the pretty printing.

Aaron Meurer

On Mon, Jun 20, 2016 at 2:53 PM, chaowen guo <[email protected]> wrote:

>
> <https://lh3.googleusercontent.com/-AhOaZsEAbsA/V2g6XjLekAI/AAAAAAAAAAs/b3jkoU_rCpAzMXZD-QGxhcHyEkRy32jywCLcB/s1600/latex.png>
> Hi:
>
> The example is shown above. I want the latex output of x is like that in
> Out[5], the factor version of denominator. It seems that str and sympy
> internal representation respect that denominator is factored. How to let
> sympy.latex to show the factor version of denominator?
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/sympy.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/sympy/08051972-102c-41a2-bc66-39e16cdbc73c%40googlegroups.com
> <https://groups.google.com/d/msgid/sympy/08051972-102c-41a2-bc66-39e16cdbc73c%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sympy.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/CAKgW%3D6KqhVY3Lk_xV2KyAHEysgCLArdMOQhfONjGO01ruaX4EA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to