
Estoy intentando usar pythontex en Texmaker/TexLive. Descargué el paquete pythontex y ejecuté el archivo pythontex.ins. He configurado la compilación de esta manera:
lualatex --shell-escape -synctex=1 -interaction=nonstopmode %.tex|
/home/simon/texmf/tex/latex/pythontex/pythontex.py %.tex|
lualatex -interaction=nonstopmode %.tex
Cuando yo escribo :
\pyc{from sympy import * ;
x=Symbol('x') ;
var=latex(factor(x**2+3*x-4));
print(var)}
en mi archivo .tex, obtengo un buen resultado. Pero tan pronto como intento poner todo ese código en un entorno pycode, como:
\begin{pycode}
from sympy import *
x=Symbol('x')
var=latex(factor(x**2+3*x-4))
\end{pycode}
\py{var}
no funciona...
Alguien me puede ayudar ?