Mathematical typesetting arranges symbolic expressions in two dimensions. It must coordinate computer fonts, glyph positioning, typesetting boxes and text baselines while preserving the expression's visible structure. A typeset fraction positions its components above and below a bar; superscripts, subscripts, square roots and mathematical delimiters impose other geometric relationships.[ref]
MATH - The Mathematical Typesetting Table by Microsoft. Overview: hierarchical formulas, recursive layout and component boxes
For example,contains a superscript inside the upper component and a square root inside the lower component. Their dimensions help determine the height of the complete typeset fraction. A larger expression may then require larger surrounding mathematical delimiters. Laying out the smallest parts first makes this a recursive geometric construction.
An OpenType MATH table supplies font-specific information such as placement constants and suitable glyph variants. The table supplies data for layout; different implementations can use those data in different algorithms. TeX and LaTeX provide established authoring systems for expressing such mathematical structure.[ref]
MATH - The Mathematical Typesetting Table by Microsoft. Overview and MATH table structures: font data rather than a complete layout algorithm
The mathematical typesetting axis, or Math axis, is a horizontal alignment reference for a formula. Its offset from the text baseline is a mathematical font constant, represented by
axisHeight in an OpenType MATH table.[ref]MATH - The Mathematical Typesetting Table by Microsoft. MathConstants: axisHeight and baseline offset
For an invented coordinate example, choose upward-positive coordinates, put the text baseline at , and set the axis offset to font units in a computer font with 1000 font units per em. At 20 pixels per em, the axis is pixels above that baseline. A symmetric enclosing shape spanning to has midpoint , so its centre lies on the axis.
The typeset fraction bar is another useful alignment cue. The reference fixes relative placement; translating the whole formula also translates its baseline and axis.
A mathematical typesetting style selects layout conventions appropriate to a formula's context, including compact inline material and more spacious displayed material. In MathML,
math-style distinguishes normal and compact, while math-depth participates in nested size selection.[ref]Compare two presentations of the same expression:Both represent the same quotient, but reserve different vertical space. In TeX,
\displaystyle and \textstyle request these contexts. The choice matters when fitting a typeset fraction into a line without making neighbouring text baselines unnecessarily far apart.For a hypothetical computer font with first- and second-level script scales 80 and 60 percent, a base font size of 20 units gives script sizes 16 and 12. The second value is relative to the base, so it is not . Actual percentages come from the computer font's mathematical font constants.[ref]
MathML Core by World Wide Web Consortium. §4.5: ScriptPercentScaleDown and ScriptScriptPercentScaleDown
A mathematical delimiter is a symbol used to enclose or separate parts of a mathematical expression, such as parentheses, brackets or vertical bars. Its visible size should suit the enclosed material. Mathematical typesetting can select a larger mathematical glyph variant or construct a mathematical glyph assembly when a default glyph is too small.[ref]
MATH - The Mathematical Typesetting Table by Microsoft. MathVariants and MathGlyphConstruction: ready-made variants and assemblies for growing shapes
For example, compare the grouping inThe parentheses enclose the complete typeset fraction, so its height and depth inform their layout. The superscript applies to the grouped expression. In TeX,
\left( and \right) request paired size-sensitive delimiters around the enclosed material. The stored parenthesis characters can therefore yield different glyphs in different formula contexts.The Math axis provides a useful alignment reference for symmetric enclosing shapes. A font's choice of larger variants or assembly parts can preserve appropriate stroke weights and proportions while the expression grows.
A typeset fraction is a two-dimensional layout that places one expression above another, commonly with a horizontal rule between them. The components are laid out as typesetting boxes before they are assembled. In MathML, an
mfrac element supplies the two components; mathematical typesetting style affects their presentation.[ref]For example,has a superscript in its upper component and a square root in its lower component. Their dimensions influence the space above and below the fraction rule. The expression's algebraic meaning and its geometry are related but distinct: the layout can contain arbitrary expressions, including ones whose values are not rational numbers.
A simple own box model makes the horizontal placement explicit. Suppose the component widths are and , and the layout adds a chosen side allowance . If both components are centred in widththeir left offsets are and . This is an illustrative centring model; real layouts also use vertical clearances, rule thickness and font data from an OpenType MATH table.
A subscript is a component placed below the usual baseline of a base expression, commonly at a smaller size. It can label a term of a sequence, as in , or identify a matrix entry, as in . Its position does not by itself determine the mathematical meaning of the label.
In TeX,
x_i attaches a single-token subscript, while x_{i+1} groups a compound subscript. In MathML, msub supplies a base and subscript as separate children. Their layout uses baseline shifts and clearances rather than putting both components on the ordinary text baseline.[ref]MathML Core by World Wide Web Consortium. Subscripts and superscripts: msub child layout and shift calculations
For example, keeps together as one attached component. A mathematical typesetting style controls the treatment of the smaller expression. An OpenType MATH table can supply the font-specific placement data. This is why adding an underscore as an ordinary printed glyph would not reproduce the layout.
A superscript is a component raised relative to a base expression, commonly also reduced in size. An exponent in is one use. The superscript in can instead denote a derivative when that convention has been specified. The typographic position supports several meanings.
In TeX,
x^2 supplies one token as the superscript and x^{n+1} groups a longer expression. In MathML, msup lays out the base and superscript separately, with vertical placement and gap constraints.[ref]MathML Core by World Wide Web Consortium. Subscripts and superscripts: msup layout
For example, the base and raised expression inhave different local baselines. A mathematical typesetting style determines how the raised expression is presented. When subscripts and superscripts are both attached, their mutual clearance also matters; independently moving each one without considering the other could cause a collision. An OpenType MATH table provides font-specific data used for these choices.
Articles by others on the same topic
There are currently no matching articles.