strange behavior of tex()



Kostas Oikonomou wrote:
> With maxima 5.14, I get the following behavior with tex():
> 
> (%i7) tex(expand((a+b+c)^3));
> $$c^3+3\,b\,c^2+3\,a\,c^2+3\,b^2\,c+6\,a\,b\,c+3\,a^2\,c+b^3+3\,a\,b^2
>   +3\,a^2\,b+a^3$$
> (%o7)                                false
> (%i8) ordergreat(a,b,c);
> (%o8)                                done
> (%i9) tex(expand((a+b+c)^3));
> $${\it \_103a}^3+3\,{\it \_102b}\,{\it \_103a}^2+3\,{\it 
> \_101c}\,
>   {\it \_103a}^2+3\,{\it \_102b}^2\,{\it \_103a}+6\,{\it 
> \_101c}\,
>   {\it \_102b}\,{\it \_103a}+3\,{\it \_101c}^2\,{\it \_103a}+
>   {\it \_102b}^3+3\,{\it \_101c}\,{\it \_102b}^2+3\,{\it 
> \_101c}^2\,
>   {\it \_102b}+{\it \_101c}^3$$
> (%o9)                                false
> (%i10)
> 
> The first output is fine, but what are the _101, _102, etc 
> in the second output?

They come from how ordergreat works.  It prepends those numbers to the 
variable names so that the display function (or something) displays the 
variables in the order that you want.

I guess tex needs to be taught about that so that it doesn't put those 
numbers there.

Ray