How to convert Mathematica syntax to latex?

Tungsten alpha accepts latex, but it is not exported to latex,

it exports plaintext, displayed images, and math syntax.

Is there a javascript library that converts output to latex?

Mathematica Syntax:

Cell[BoxData[FormBox[TagBox[RowBox[List[FractionBox["1", "2"], " ", RowBox[List["(", RowBox[List[RowBox[List["4", " ", SuperscriptBox["x", "2"]]], "+", "x", "+", "2"]], ")"]]]], Identity, Rule[TagBoxNote, List[Rule["Hyperlink", "1/2 (2+x+4 x^2)"]]]], TraditionalForm]], "Output", Rule[PageWidth, 500], Rule[Magnification, 1], Rule[CellMargins, List[List[0, 0], List[0, 0]]], Rule[ShowCellBracket, False], Rule[FontFamily, "Bitstream Charter"], Rule[FontSize, 14], Rule[NumberSeparator, "\[ThinSpace]"]]

Latex syntax

2x^2+\frac{x}{2} +1
+5
source share
1 answer

I know that you can do this in Mathematica itself using TeXForm

So you would do something like ToExpression["\\frac{a}{b}", TeXForm]

+1
source

All Articles