prints as an approximation to the traditional mathematical notation for expr.
Details and Options
- Output from TraditionalForm cannot necessarily be given as unique and unambiguous input to the Wolfram Language. »
- TraditionalForm inserts invisible TagBox and InterpretationBox constructs into the box form of output it generates, to allow unique interpretation.
- Graphics and Graphics3D are displayed graphically in TraditionalForm. »
- TraditionalForm can be edited in the notebook front end.
- TraditionalForm uses special characters as well as ordinary keyboard characters. »
- TraditionalForm incorporates a large collection of rules for approximating traditional mathematical notation.
- TraditionalForm prints functions in Global` context in the form f(x).
- ToExpression[boxes,TraditionalForm] will attempt to convert from TraditionalForm. »
- The notebook front end contains menu items for conversion to and from TraditionalForm.
- When an input evaluates to TraditionalForm[expr], TraditionalForm does not appear in the output. »
Examplesopen allclose all
Basic Examples (3)
Basic Objects (2)
Special Input Forms (4)
Different ways of representing Power expressions:
The same expressions entered as typical input:
Special Output Forms (3)
Some objects use a special output representation:
Compare the TraditionalForm with the underlying FullForm of the expression:
Some objects use an elided output representation:
The elided information is visible in the InputForm:
Properties & Relations (4)
When an input evaluates to TraditionalForm[expr], TraditionalForm does not appear in the output:
Out is assigned the value x2, not TraditionalForm[x^2]:
TraditionalForm is two-dimensional:
StandardForm is two-dimensional and unambiguous for input:
OutputForm uses only keyboard characters:
InputForm and FullForm provide one-dimensional formatting:
Use ToBoxes to see the underlying box structure:
Use ToExpression to convert the boxes to the original expression:
Add formatting via Format:
Possible Issues (2)
TraditionalForm is ambiguous, i.e. different expressions can display similarly:
The following box structure has similar display:
When interpreting the boxes, a particular interpretation is selected:
Wolfram Language–generated formatting includes data for unambiguous interpretation:
Even when an output omits TraditionalForm from the top level, it is not stripped from subexpressions:
The output does not have TraditionalForm in it:
However, the variable e does have TraditionalForm in it, which may affect subsequent evaluations:
The integral is not evaluated due to the intervening TraditionalForm:
Assign variables first and then apply TraditionalForm to the result to maintain computability:
Wolfram Research (1996), TraditionalForm, Wolfram Language function, https://reference.wolfram.com/language/ref/TraditionalForm.html (updated 2008).
Wolfram Language. 1996. "TraditionalForm." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2008. https://reference.wolfram.com/language/ref/TraditionalForm.html.
Wolfram Language. (1996). TraditionalForm. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TraditionalForm.html