]>
This section describes the customized and extended version of Content MathML developed for the project Virtual Laboratories in Probability and Statistics. Thus, the information here should be considered a companion to the standard Content MathML documentation at W3C. The customized Content MathML markup is translated into standard Presentation MathML via the XSL transformation file stat.xsl which in turn is based on the standard XSL transformation file ctop.xsl written by David Carlisle. Our stylesheet stat.xsl also corrects a number of bugs in the original ctop.xsl. These corrections are due to Tom Leathrum.
The markup <prob />
has been added to denote probability measure, and is rendered by the stylesheet with the special symbol
. This markup is ordinarily used with the standard <apply></apply>
construction, with one or more arguments. For example, the markup
<apply><prob /> <apply><intersect /> <ci>A</ci> <ci>B</ci> </apply> </apply>
is rendered by the stylesheet as .
Similarly, the markup <expect />
has been added to denote the expected value operator, and is rendered by the stylesheet with the special symbol
. This markup is ordinarily used with the standard <apply></apply>
construction, with one or more arguments. For example, the markup
<apply><expect /> <ci>X</ci> <apply><geq /> <ci>Y</ci> <cn>0</cn> </apply> </apply>
is rendered by the stylesheet as
The notion of conditioning is of central importance in modern probability, so the markup <given></given>
has been added for conditional probability and conditional expected value. This markup is used inside the <apply></apply>
construction, and can have any number of arguments. For example, the markup
<apply><prob /> <ci>A</ci> <given> <ci>B</ci> <ci>C</ci> </given> </apply>
is rendered by the stylesheet as . Similarly, the markup
<apply><expect /> <ci>X</ci> <given> <apply><geq /> <ci>Y</ci> <cn>0</cn> </apply> </given> </apply>
is rendered by the stylesheet as
Our stylesheet uses the standard <apply></apply>
construction with all of the trigonometric, logarithmic, hyperbolic functions and the inverses of these functions, that are in standard Content MathML. Thus, the stylesheet renders these functions in consistent notation, with arguments enclosed in parentheses after the function name. For example,
<apply><sin /> <ci>θ</ci> </apply>
is rendered by the stylesheet as rather than .
We use function notation for cardinality. The markup <card />
in standard Content MathML is rendered with our stylesheet by
.
This markup works in the usual way with the standard <apply></apply>
construction. For example,
<apply><card /> <ci>A</ci> </apply>
is rendered by the stylesheet as rather than .
Similarly, we use function notation for determinants. The markup <determinant />
in standard Content MathML is rendered by our stylesheet as
. This markup works in the usual way with the standard <apply></apply>
construction. For example
<apply><determinant /> <ci>A</ci> </apply>
is rendered by the stylesheet as rather than .
Markup has been added for a number of special functions, particularly those related to probability and statistics.
<variance />
denotes variance and is rendered by the stylesheet as
.
<covariance />
denotes covariance and is rendered by the stylesheet as
.
<correlation />
denotes correlation and is rendered by the stylesheet as
.
<skew />
denotes skewness and is rendered by the stylesheet as
.
<kurt />
denotes correlation and is rendered by the stylesheet as
.
<Beta />
denotes the beta function and is rendered by the stylesheet as
.
<Gamma />
denotes the gamma function and is rendered by the stylesheet as
.
<zeta />
denotes the zeta function and is rendered by the stylesheet as
.
<lebesgue />
denotes Lebesgue measure and is rendered by the stylesheet as
.
<closure />
denotes closure and is rendered by the stylesheet as
.
Each of these works in the usual with the standard <apply></apply>
construction. With this construction, <covariance />
and <correlation />
ordinarily have two arguments; the other functions in the list ordinarily have one argument. For example,
<apply><covariance /> <ci>X</ci> <ci>Y</ci> </apply>
is rendered by the stylesheet as while
<apply><skew /> <ci>X</ci> </apply>
is rendered by the stylesheet as .
Chi-square procedures are common in statistics, and involve some complicated notation. The markup <chisquare />
has been added for the chi-square quantile function with a specified degrees of freedom. This markup shoud be used in the standard <apply></apply>
construction, with two arguments. For example, the markup
<apply><chisquare /> <ci>k</ci> <ci>p</ci> </apply>
is rendered by the stylesheet as .
The markup <indicate />
has been added for an indicator function, and is rendered by the stylesheet as
. This markup is used with the <apply></apply>
construction. For example, the markup
<apply> <apply><indicate /> <ci>A</ci> </apply> <ci>x</ci> </apply>
is rendered by the stylesheet as .
The markup <positivepart />
and <negativepart />
have been added for the positive and negative parts of a real number, respectivley. These should be used with the standard <apply></apply>
construction, with one argument. For example, the markup
<apply><positivepart /> <ci>x</ci> </apply>
is rendered by the stylesheet as , while the markup
<apply><negativepart /> <ci>x</ci> </apply>
is rendered by the stylesheet as .
The markup <norm />
has been added for the norm of a vector. The markup should be used with the <apply></apply>
construction, with one argument. For example, the markup
<apply><norm /> <ci>x</ci> </apply>
is rendered by the stylesheet as .
The markup <innerproduct />
has been added for the inner product of two vectors. The markup should be used with the <apply></apply>
construction, with two arguments. For example, the markup
<apply><innerproduct /> <ci>x</ci> <ci>y</ci> </apply>
is rendered by the stylesheet as
. Standard Content MathML has the markup <scalarproduct />
for scalar product (or dot product). Our stylesheet leaves the rendering of this element unchanged.
The markup <factorial />
for factorials has been extended to denote the falling power
formula used for counting permutations and an even more general permutation formula. (For the definitions of these, see Combinatorial Structures in Virtual Laboratories in Probability and Statistics) This markup should be used in the standard <apply></apply>
construction, with one, two, or three arguments. With one argument, the markup denotes the standard factorial, so that
<apply><factorial /> <ci>n</ci> </apply>
is rendered by the stylesheet as . With two arguments, the markup denotes the falling power factorial formula, so that
<apply><factorial /> <ci>n</ci> <ci>k</ci> </apply>
is rendered by the stylesheet as . With three arguments, the markup denotes the general factorial formula, so that
<apply><factorial /> <ci>n</ci> <ci>k</ci> <ci>c</ci> </apply>
is rendered by the stylesheet as
The markup <binomial />
has been added for binomial and multinomial coefficients. This markup should be used with the standard <apply></apply>
construction; with two arguments it represents a binomial coefficient, and with more than two arguments it represents a multinomial coefficient. For example,
<apply><binomial /> <ci>n</ci> <ci>k</ci> </apply>
is rendered by the stylesheet as , and
<apply><binomial /> <ci>n</ci> <ci>i</ci> <ci>j</ci> <ci>k</ci> </apply>
is rendered by the stylesheet as .
The standard <apply></apply>
construction has been extended with the addition of a type
attribute. The type="relation"
setting uses standard notation associated with a relation. For example,
<apply type="relation"> <ci>R</ci> <ci>x</ci> <ci>y</ci> </apply>is rendered by the stylesheet as , as opposed to
<apply> <ci>R</ci> <ci>x</ci> <ci>y</ci> </apply>which is rendered by the stylesheet in the usual functional way as .
Markup has been added for a number of special relation symbols, beyond the ones in standard Content MathML. For the most part, these relations are associated with partial orders, equivalence relations, and other transitive relations.
<preceq />
which is rendered by the stylesheet as
.
<succeq />
which is rendered by the stylesheet as
.
<prec />
which is rendered by the stylesheet as
.
<succ />
which is rendered by the stylesheet as
.
<parallel />
which is rendered by the stylesheet as
.
<perp />
which is rendered by the stylesheet as
.
<approxeq />
which is rendered by the stylesheet as
.
<congruent />
which is rendered by the stylesheet as
.
<left />
which is rendered by the stylesheet as
.
<right />
which is rendered by the stylesheet as
.
<leftright />
which is rendered by the stylesheet as
.
<up />
which is rendered by the stylesheet as
.
<down />
which is rendered by the stylesheet as
.
<updown />
which is rendered by the stylesheet as
.
<apply type="relation"></apply>
construction, with two arguments. For example,
<apply type="relation"><preeq /> <ci>x</ci> <ci>y</ci> </apply>is rendered by the stylesheet as .
The markup <equivalenceclass />
has been added to denote an equivalence class. This markup should be used with the standard <apply></apply>
construction, with one argument. For example, the markup
<apply><equivalenceclass /> <ci>x</ci> </apply>is rendered by the stylesheet as .
The <mapsto />
markup has been added for the description of functions. This markup should be used with the standard <apply></apply>
construction, with either two are three arguments. For example, the markup
<apply><mapsto /> <ci>x</ci> <apply><power /> <ci>x</ci> <cn>2</cn> </apply> </apply>is rendered by the stylesheet as , while the markup
<apply><mapsto /> <ci>f</ci> <ci>A</ci> <ci>B</ci> </apply>is rendered by the stylesheet as ,
We have added several new operations, beyond the ones in standard Content MathML.
The markup <convolve />
denotes convolution, and is rendered by the stylesheet as
. This markup is ordinarily used with the <apply></apply>
construction, with two or more arguments. For example, the markup
<apply><convolve /> <ci>f</ci> <ci>g</ci> <ci>g</ci> </apply>is rendered by the stylesheet as .
The markup <convolutionpower />
denotes convolution power (repeated covolution of a function with itself). It should be used with the <apply></apply>
construction, with two arguments. For example, the markup
<apply><convolutionpower /> <ci>f</ci> <ci>n</ci> </apply>is rendered by the stylesheet as .
The composition operation <compose />
is present in standard Content MathML. We have added <compositionpower />
to denote repeated composition of a function with itself. This markup should be used with the standard <apply></apply>
construction, with two arguments. For example, the markup
<apply><compositionpower /> <ci>f</ci> <ci>n</ci> </apply>is rendered by the stylesheet as .
The markup <plusminus />
has been added for the plus-minus operator, which is rendered by the stylesheet as
. The plus-minus operator is both unary and binary, so the markup should used with the <apply></apply>
construction, with either one or two arguments. For example, the markup
<apply><plusminus /> <ci>a</ci> </apply>is rendered by the stylesheet as , while the markup
<apply><plusminus /> <ci>a</ci> <ci>b</ci> </apply>is rendered by the stylesheet as .
The markup <powerset />
has been added for the power set operator, which is rendered by the stylesheet as
. This markup is ordinarily used with the <apply></apply>
construction, with one argeument. For example, the markup
<apply><powerset /> <ci>A</ci> </apply>is rendered by the stylesheet as .
The markup <complement />
has been added for the complement of a set. This markup is ordinarily used with the <apply></apply>
construction, with one argeument. For example, the markup
<apply><complement /> <ci>A</ci> </apply>is rendered by the stylesheet as .
The markup <symmdiff />
has been added for the symmetric difference operator, rendered by the stylesheet as
. This markup is ordinarily used with the <apply></apply>
construction, with two arguments. For example, the markup
<apply><symmdiff /> <ci>A</ci> <ci>B</ci> </apply>is rendered by the stylesheet as .
New markup expressions <Union />
and <Intersect />
have been added for unions and intersections, respectively, over collections. The distinction between the standard markup <union />
and the new markup <Union />
is analogous to the distinction between <plus />
and <sum />
in standard markup. For example, the markup
<apply><Union /> <condition> <apply><in /> <ci>i</ci> <ci>I</ci> </apply> </condition> <apply><selector /> <ci>A</ci> <ci>i</ci> </apply> </apply>is rendered by the stylesheet as , while the markup
<apply><Union /> <bvar><ci>i</ci></bvar> <lowlimit><cn>1</cn></lowlimit> <uplimit><ci>n</ci></uplimit> <apply><selector /> <ci>A</ci> <ci>i</ci> </apply> </apply>is rendered by the stylesheet as . The markup for intersection works in exactly the same way, with
<Intersect />
replacing <Union />
. Unions and intersections over collections will be a part of the new Content MathML 3.0 specification.
Standard Content MathML has markup for minimums and maximums. We have added analogous markup for infima and suprema. The markup <inf />
and <sup />
are used with the standard <apply></apply>
construction. Thus for example, the markup
<apply><inf /> <ci>a</ci> <ci>b</ci> <ci>c</ci> </apply>is rendered by the stylesheet as , and the markup
<apply><inf /> <bvar> <apply><selector /> <ci>a</ci> <ci>n</ci> </apply> </bvar> <condition> <apply><in /> <ci>n</ci> <naturalnumbers /> </apply> </condition> </apply>is rendered by the stylesheet as . Of course, the markup for suprema is entirely analogous, with
<sup />
replacing <inf />
.
Standard Content MathML has markup for limits. We have added analogous markup for limit inferior and limit superior. The markup <limitinf />
and <limitsup />
are used with the standard <apply></apply>
construction. Thus, for example, the markup
<apply><limitsup /> <condition> <apply><tendsto /> <ci>t</ci> <ci>x</ci> </apply> </condition> <apply> <ci>F</ci> <ci>t</ci> </apply> </apply>is rendered by the stylesheet as . Of course, the markup for limit inferior is entirely analogous, with
<limitinf />
replacing <limitsup />
.
Standard Content MathML has markup for several special sets of numbers. We extend this to include
<positiveintegers />
denotes the set of positive integers, rendered by the stylesheet as
. In our project, the natural numbers (which has markup in standard Content MathML) refers to the nonnegative integers.
<positiverationals />
denotes the set of positive rational numbers, rendered by the stylesheet as
.
<algebraicnumbers />
denotes the set of algebraic numbers, rendered by the stylesheet as
.
Hypothesis testing is a core procedure in inferential statistics. Thus, we have added special markup for hypothesis testing, with a type attribute to distinguish between the null and alternative hypotheses. Thus, <hypothesis type="null" />
is rendered by the stylesheet as
, while <hypothesis type="alt" />
is rendered by the stylesheet as
. This markup is ordinarily used with the <apply></apply>
construction, with one argument (representing the hypothesis). For example, the markup
<apply><hypothesis type="null" /> <apply><eq /> <ci>μ</ci> <cn>0</cn> </apply> </apply>is rendered by the stylesheet as .
Concepts and techniques in probability are often illustrated with examples involving playing cards. Such examples are useful because of their conceptual clarity and because of the rich varitey of problems that can be posed.
The markup <ace />
, <jack />
, <queen />
, and <king />
have been added to denote the denominations of ace, jack, queen, and king, respectively. The stylesheet renders these as
,
,
, and
, respectively. These should be considered as special constants. Indeed, the other denominations are ordinarily denoted by the standard numbers 2, 3, 4, 5, 6, 7, 8, 9, and 10.
The markup <spades />
, <hearts />
, <diamonds />
, and <clubs />
have been added to denote the suits. These are rendered by the stylesheet as
,
,
, and
, respectively. The markup for a suit can also be used with the <apply></apply>
construction, with one arguments, to represent a card in that suit. For example, the markup
<apply> <hearts /> <queen /> </apply>
would be rendered by the stylesheet as
The markup <etc />
has been added to denote the ubiquitous concept of and so forth
. The stylesheet renders this with three dots (an ellipsis), in either a lower position or a middle position, depending on a type attribute. For example, the markup
<vector> <apply><selector /> <ci>x</ci> <cn>1</cn> </apply> <apply><selector /> <ci>x</ci> <cn>2</cn> </apply> <etc /> <apply><selector /> <ci>x</ci> <ci>n</ci> </apply> </vector>is rendered by the stylesheet as , while the markup
<apply><plus /> <apply><selector /> <ci>x</ci> <cn>1</cn> </apply> <apply><selector /> <ci>x</ci> <cn>2</cn> </apply> <etc type="middle" /> <apply><selector /> <ci>x</ci> <ci>n</ci> </apply> </apply>is rendered by the stylesheet as .
The markup <odds />
has been added to denote odds in gambling and probability. This markup should be used with the standard <apply></apply>
construction, with two arguments. For example, the markup
<apply><odds /> <ci>a</ci> <ci>b</ci> </apply>is rendered by the stylesheet as .
The markup <ordinal />
has been added for ordinal numbers. Thie markup should be used with the standard <apply></apply>
construction, with one argument. The type of suffix is controlled by a type attribute, with th as the default. For example
<apply><ordinal /> <ci>n</ci> </apply>is rendered by the stylesheet as ;
<apply><ordinal type="st"/> <cn>1</cn> </apply>is rendered by the stylesheet as ;
<apply><ordinal type="nd"/> <cn>2</cn> </apply>is rendered by the stylesheet as ; and
<apply><ordinal type="rd"/> <cn>3</cn> </apply>is rendered by the stylesheet as .