![]() |
Mathematical primitives | ![]() |
These primitives are used for producing large delimiters, like in the formula
1 |
a1 |
1 |
a2 |
1 |
an |
Matching left and right delimiters are automatically sized so as contain the enclosed expression. Between matching left and right delimiters, the formula may contain an arbitrary number of middle delimiters, which are sized in a similar way. Contrary to TeX, the depth of a large delimiter is not necessarily equal to its height, so as to correctly render formulas like
1 | ||||
x +
|
The user may override the automatically determined size by specifying additional length parameters size or bottom and top. For instance,
f<left|(|-8mm|4mm>x<mid|||8mm>y<right|)|-4mm|8mm>
is rendered as
The size may also be a number n, in which case the n-th available size for the delimiter is taken. For instance,
g<left|(|0><left|(|1><left|(|2><left|(|3>z<right|)|3><right|)|2><right|)|1><right|)|0>
is rendered as
This primitive is used in order to produce big operators as in
∑
|
(1) |
The size of the operator depends on whether the formula is
rendered in “display style” or not. Formulas in
separate equations, like (?), are said to be
rendered in display style, contrary to formulas which occur in
the main text, like ∑
ai
zi. The user may use
∞
i = 0
Notice that the formula (?) is internally represented as
<big|sum><rsub|i=0><rsup|∞>a<rsub|i>*z<rsup|i><big|.>
The invisible big operator <big|.> is used to indicate the end of the scope of <big|sum>.
The
x |
y |
<frac|1|a<rsub|0>+<frac|1|a<rsub|1>+<frac|1|a<rsub|2>+⋱>>>
is rendered in display style as
1 | ||||
a0 +
|
The
f(x) |
y2 + z2 |
These primitives are used in order to attach a script to the preceeding box in a horizontal concatenation (in the case of right scripts) or the next one (in the case of left scripts). When there is no such box, then the script is attached to an empty box. Moreover, when both a subscript and a superscript are specified on the same side, then they are merged together. For instance, the expression
<rsub|a><rsup|b>+<lsub|1><lsup|2>x<rsub|3><rsup|4>=y<rsub|1>+<lsub|c>
is rendered as
b |
a |
4 |
3 |
When a right script is attached to an operator (or symbol) which accepts limits, then it is rendered below or above instead of beside the operator:
Scripts are rendered in a smaller font in non-display style. Nevertheless, in order to keep formulas readable, the size is not reduced below script-script-size.
Left and right primes are similar to left and right superscripts, except that they behave in a different way when being edited. For instance, when your cursor is behind the prime symbol in f' and you press backspace, then the prime is removed. If you are behind fn and you press backspace several times, then you first enter the superscript, next remove n and finally remove the superscript. Notice also that prime-symbols is necessarily a string of concatenated prime symbols. For instance, f'† is represented by f<rprime|'†>.
The
can be produced using
<above|<below|xor|i=1>|∞>
x<rsub|i>
These primitives can be used in order to produce wide accents above or below some mathematical content. For instance (x + y)¯ corresponds to the markup <wide|x+y|¯>.
This primitive is mainly used for producing negated symbols or expressions, such as not(↣) or not(a).
This primitive is used to produce a tree with a given root and children child-1 until child-n. The primitive should be used recursively in order to produce trees. For instance,
corresponds to the markup
<tree|+|x|y|<tree|×|2|y|z>>
In the future, we plan to provide further style parameters in order to control the rendering.