Thank you very much. Two quick questions: 1) Is it currently possible to print the sympy expressions to stdout and at the same time write the latex output to a file? In this case, the latex file would be a kind of logging device. 2) Is it currently possible to choose my own latex representation for the variables? E.g. I would like the sympy.tensor expression L[0,1] to translate to something like $L_{0}^{(1)}$.
Best, Akin On Feb 3, 6:03 pm, Alan Bromborsky <abro...@verizon.net> wrote: > On 02/03/2012 11:52 AM, Akin wrote: > > > > > > > > > Hi, > > > it seems that the extended latex module fails to typeset expressions > > involving sympy.tensors, whereas the sympy.printing.latex command > > works. Here is a minimal script that reproduces the error messages I > > get: > > > from sympy import * > > import sympy.galgebra.latex_ex as tex > > > x = Symbol('x') > > A = 2*x > > > C = IndexedBase('C') > > L = IndexedBase('L') > > tau = IndexedBase('tau') > > hd = IndexedBase('hd') > > xi = IndexedBase('xi') > > B = 3**(1/2)*C[5]*L[0]*tau[0]*hd[0]*xi[1]/3 > > > print latex(A) #Works > > print latex(B) #Works > > > tex.Format() > > print A # Works > > print B # Fails with error message 'RuntimeError: maximum > > recursion depth exceeded while calling a Python object' > > tex.xdvi('test.tex') > > > Any thoughts on that? > > > Best, > > > Akin > > When I wrote letex_ex I don't think sympy had tensors. I will fix this. -- You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to sympy@googlegroups.com. To unsubscribe from this group, send email to sympy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sympy?hl=en.