sagemath 8.9.
I do not remember if I mentioned this before or not. I googled and did not find anything. If this is already mentioned and known issue, I am sorry and please feel free to close this.
Fricas returns li
in one result, which gets translated log_integral
by sagemath. But since in Latex, the _ is important , it looks bad when typeset. also, the it should be a math operator, as in \log_integral
but not it just shows as log_integral
.
Here is an example.
sage: var('t')
t
sage: result=integrate(1/log(t)^2,t, algorithm="fricas")
sage: result
(log(t)*log_integral(t) - t)/log(t)
sage: latex(result)
\frac{\log\left(t\right) log_integral\left(t\right) - t}{\log\left(t\right)}
When compiling the above latex, it shows as
\documentclass[11pt]{article}
\usepackage{amsmath}
\begin{document}
$\frac{\log\left(t\right) log_integral\left(t\right) - t}{\log\left(t\right)}$
\end{document}
Using Fricas directly
(3) -> result:=integrate(1/log(t)^2,t)
li(t)log(t) - t
(3) ---------------
log(t)
Type: Union(Expression(Integer),...)
(4) -> latex(result)
(4)
"{{{li \left( {t} \right)} \ {\log \left( {t} \right)}} -t} \over {\log \lef
t( {t} \right)}"
Type: String
(5) ->
Compiling the above gives
\documentclass[11pt]{article}
\usepackage{amsmath}
\begin{document}
${{{li \left( {t} \right)} \ {\log \left( {t} \right)}} -t} \over {\log \left( {t} \right)}$
\end{document}
Not perfect either (since 'li
should have been \li
and made an operator) but it looks better that latex from sagemath,
Is this a known issue? Is there a workaround? editing these outputs by hand each time and fixing them it not practical for me.
Thank you --Nasser