Skip to main content
added 139 characters in body
Source Link
Carl Woll
  • 132.7k
  • 6
  • 253
  • 366

Assuming you never want to try to create TeX of the new numerical approximations output, you could do:

Unprotect[Convert`TeX`ExpressionToTeX]; Convert`TeX`ExpressionToTeX[expr_, o___?OptionQ] /; !TrueQ@$TeX := Block[ {$TeX=True, BoxForm`UseApproximations=False}, Convert`TeX`ExpressionToTeX[expr,o] ] Protect[Convert`TeX`ExpressionToTeX]; 

Then:

Root[#^3 + # + 1&, 2] //TeXForm 

$\text{Root}\left[\text{$\#$1}^3+\text{$\#$1}+1\&,2\right]$

If desired, a more targeted version that only affects Root object is also possible.

Assuming you never want to try to create TeX of the new numerical approximations output, you could do:

Unprotect[Convert`TeX`ExpressionToTeX]; Convert`TeX`ExpressionToTeX[expr_, o___?OptionQ] /; !TrueQ@$TeX := Block[ {$TeX=True, BoxForm`UseApproximations=False}, Convert`TeX`ExpressionToTeX[expr,o] ] Protect[Convert`TeX`ExpressionToTeX]; 

Then:

Root[#^3 + # + 1&, 2] //TeXForm 

$\text{Root}\left[\text{$\#$1}^3+\text{$\#$1}+1\&,2\right]$

Assuming you never want to try to create TeX of the new numerical approximations output, you could do:

Unprotect[Convert`TeX`ExpressionToTeX]; Convert`TeX`ExpressionToTeX[expr_, o___?OptionQ] /; !TrueQ@$TeX := Block[ {$TeX=True, BoxForm`UseApproximations=False}, Convert`TeX`ExpressionToTeX[expr,o] ] Protect[Convert`TeX`ExpressionToTeX]; 

Then:

Root[#^3 + # + 1&, 2] //TeXForm 

$\text{Root}\left[\text{$\#$1}^3+\text{$\#$1}+1\&,2\right]$

If desired, a more targeted version that only affects Root object is also possible.

Source Link
Carl Woll
  • 132.7k
  • 6
  • 253
  • 366

Assuming you never want to try to create TeX of the new numerical approximations output, you could do:

Unprotect[Convert`TeX`ExpressionToTeX]; Convert`TeX`ExpressionToTeX[expr_, o___?OptionQ] /; !TrueQ@$TeX := Block[ {$TeX=True, BoxForm`UseApproximations=False}, Convert`TeX`ExpressionToTeX[expr,o] ] Protect[Convert`TeX`ExpressionToTeX]; 

Then:

Root[#^3 + # + 1&, 2] //TeXForm 

$\text{Root}\left[\text{$\#$1}^3+\text{$\#$1}+1\&,2\right]$