When I run the following code in Mathematica:
mat = {{x1,x2,x3,x6,x7,x8,x11,x12},{x3,x1,x2,x8,x6,x7,x11,x12},{x3,x2,x1,x8,x7,x6,x12,x11},{x2,x3,x1,x7,x8,x6,x11,x12},{x1,x3,x2,x6,x8,x7,x12,x11},{x2,x1,x3,x7,x6,x8,x12,x11},{x4,x4,x4,x9,x9,x9,x13,x13},{x5,x5,x5,x10,x10,x10,x14,x14}}
res = Det[mat];
Factor[res]
I get the following output.
$$-9 (x11-x12) (x2 x6-x3 x6-x1 x7+x3 x7+x1 x8-x2 x8)^2 (-2 x1 x10 x13-2 x10 x13 x2-2 x10 x13 x3+3 x10 x11 x4+3 x10 x12 x4-2 x14 x4 x6+2 x13 x5 x6-2 x14 x4 x7+2 x13 x5 x7-2 x14 x4 x8+2 x13 x5 x8+2 x1 x14 x9+2 x14 x2 x9+2 x14 x3 x9-3 x11 x5 x9-3 x12 x5 x9)$$
Formatted as $\LaTeX$, the output is:
-9 (\text{x11}-\text{x12}) (-\text{x1} \text{x7}+\text{x1} \text{x8}+\text{x2} \text{x6}-\text{x2} \text{x8}-\text{x3} \text{x6}+\text{x3} \text{x7})^2 ...
Question
Is there any way to get the $\LaTeX$ output to be formatted as subscripted variables instead?
-9 (x_{11}-x_{12}) (-x_1 x_7+x_1 x_8+x_2 x_6-x_2 x_8-x_3 x_6+x_3 x_7)^2...
I could not get TeXForm to work either.
TeXFormdo what you have in mind? – Syed Mar 04 '22 at 13:48x1output in latex to bex_1? how about if the input isxnis this supposed to come out in latex asx_nalso? The Latex conversion now is the correct translation. – Nasser Mar 04 '22 at 14:38x1is not subscripted variable. Here is a screen shotFactor[res] // subscriptFormthen right click, Copy As -> LaTeX. – xzczd Mar 05 '22 at 03:39