This is something of a noodling around that may be of use/interest to someone. It uses Rebol's operator semantics to generate LaTeX equation notation. It is by no means comprehensive, I had a use for it and it serves that purpose.
Of interest is the redefinition of math operators as they are known in Rebol and while they are still largely compatible with their regular function, they instead accumulate values as LaTeX notation rather than evaluating them.
Note the handling of blocks and groups (parens). To create intentionally parenthesized content, blocks are required; to manage Rebol's semantics without creating parenthesized content, use groups (parens).
e ^ 1 + x ; => {e}^{1}+{x}
e ^ (1 + x) ; => {e}^{1+{x}}
e ^ [1 + x] ; => {e}^{\left(1+{x}\right)}