1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137
|
<!DOCTYPE html
PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Characters, Entities and Fonts</title><style type="text/css">
.egmeta {
color:#5555AA;font-style:italic;font-family:serif;font-weight:bold;
}
table.syntax {
font-size: 75%;
background-color: #DDDDDD;
border: thin solid;
}
table.syntax td {
border: solid thin;
}
table.syntax th {
text-align: left;
}
table.attributes td { padding-left:0.5em; padding-right:0.5em; }
table.attributes td.attname { white-space:nowrap; vertical-align:top;}
table.attributes td.attdesc { background-color:#F0F0FF; padding-left:2em; padding-right:2em}
th.uname {font-size: 50%; text-align:left;}
code { font-family: monospace; }
div.constraint,
div.issue,
div.note,
div.notice { margin-left: 2em; }
li p { margin-top: 0.3em;
margin-bottom: 0.3em; }
div.exampleInner pre { margin-left: 1em;
margin-top: 0em; margin-bottom: 0em}
div.exampleOuter {border: 4px double gray;
margin: 0em; padding: 0em}
div.exampleInner { background-color: #d5dee3;
border-top-width: 4px;
border-top-style: double;
border-top-color: #d3d3d3;
border-bottom-width: 4px;
border-bottom-style: double;
border-bottom-color: #d3d3d3;
padding: 4px; margin: 0em }
div.exampleWrapper { margin: 4px }
div.exampleHeader { font-weight: bold;
margin: 4px}
a.mainindex {font-weight: bold;}
li.sitem {list-style-type: none;}
.error { color: red }
div.mathml-example {border:solid thin black;
padding: 0.5em;
margin: 0.5em 0 0.5em 0;
}
div.strict-mathml-example {border:solid thin black;
padding: 0.5em;
margin: 0.5em 0 0.5em 0;
}
div.strict-mathml-example h5 {
margin-top: -0.3em;
margin-bottom: -0.5em;}
var.meta {background-color:green}
var.transmeta {background-color:red}
pre.mathml {padding: 0.5em;
background-color: #FFFFDD;}
pre.mathml-fragment {padding: 0.5em;
background-color: #FFFFDD;}
pre.strict-mathml {padding: 0.5em;
background-color: #FFFFDD;}
.minitoc { border-style: solid;
border-color: #0050B2;
border-width: 1px ;
padding: 0.3em;}
.attention { border-style: solid;
border-width: 1px ;
color: #5D0091;
background: #F9F5DE;
border-color: red;
margin-left: 1em;
margin-right: 1em;
margin-top: 0.25em;
margin-bottom: 0.25em; }
.attribute-Name { background: #F9F5C0; }
.method-Name { background: #C0C0F9; }
.IDL-definition { border-style: solid;
border-width: 1px ;
color: #001000;
background: #E0FFE0;
border-color: #206020;
margin-left: 1em;
margin-right: 1em;
margin-top: 0.25em;
margin-bottom: 0.25em; }
.baseline {vertical-align: baseline}
#eqnoc1 {width: 10%}
#eqnoc2 {width: 80%; text-align: center; }
#eqnoc3 {width: 10%; text-align: right; }
div.div1 {margin-bottom: 1em;}
.h3style {
text-align: left;
font-family: sans-serif;
font-weight: normal;
color: #0050B2;
font-size: 125%;
}
h4 { text-align: left;
font-family: sans-serif;
font-weight: normal;
color: #0050B2; }
h5 { text-align: left;
font-family: sans-serif;
font-weight: bold;
color: #0050B2; }
th {background: #E0FFE0;}
p, blockquote, h4 { font-family: sans-serif; }
dt, dd, dl, ul, li { font-family: sans-serif; }
pre, code { font-family: monospace }
a.termref {
text-decoration: none;
color: black;
}
sub.diff-link {background-color: black; color: white; font-family:
sans-serif; font-weight: bold;}
.diff-add { background-color: #FFFF99}
.diff-del { background-color: #FF9999; text-decoration: line-through }
.diff-chg { background-color: #99FF99 }
.diff-off { }
.mathml-render {
font-family: serif;
font-size: 130%;
border: solid 4px green;
padding-left: 1em;
padding-right: 1em;
}
</style><link rel="stylesheet" type="text/css" href="../../../StyleSheets/TR/W3C-REC.css">
</head>
<body>
<h1><a name="chars" id="chars"></a>7 Characters, Entities and Fonts
</h1>
<!-- TOP NAVIGATION BAR -->
<div class="minitoc">
Overview: <a href="Overview-d.html">Mathematical Markup Language (MathML) Version 3.0</a><br>
Previous: 6 <a href="chapter6-d.html">Interactions with the Host Environment</a><br>
Next: A <a href="appendixa-d.html">Parsing MathML</a><br><br>7 <a href="chapter7-d.html">Characters, Entities and Fonts</a><br> 7.1 <a href="chapter7-d.html#chars.intro">Introduction</a><br> 7.2 <a href="chapter7-d.html#chars.unicodechars">Unicode Character Data</a><br> 7.3 <a href="chapter7-d.html#chars.entities">Entity Declarations</a><br> 7.4 <a href="chapter7-d.html#chars.mglyph">Special Characters Not in Unicode</a><br> 7.5 <a href="chapter7-d.html#chars.BMP-SMP">Mathematical Alphanumeric Symbols</a><br> 7.6 <a href="chapter7-d.html#chars.nonmark">Non-Marking Characters</a><br> 7.7 <a href="chapter7-d.html#chars.anomalous">Anomalous Mathematical Characters</a><br> 7.7.1 <a href="chapter7-d.html#chars.keyboard">Keyboard Characters</a><br> 7.7.1.1 <a href="chapter7-d.html#chars.hyph-minus">Minus</a><br> 7.7.1.2 <a href="chapter7-d.html#chars.prime-quote">Apostrophes, Quotes and Primes</a><br> 7.7.1.3 <a href="chapter7-d.html#id.7.7.1.3">Other Keyboard Substitutions</a><br> 7.7.2 <a href="chapter7-d.html#chars.pseudo-scripts">Pseudo-scripts</a><br> 7.7.3 <a href="chapter7-d.html#chars.comb-chars">Combining Characters</a><br></div>
<div class="div1">
<div class="div2">
<h2><a name="chars.intro" id="chars.intro"></a>7.1 Introduction
</h2>
<p>
Notation and symbols have proved very important for
mathematics. Mathematics has grown in part because
its notation continually changes toward being succinct and
suggestive.
Many new signs have been developed for use in mathematical notation,
and many have been adopted
that were originally introduced elsewhere.The result is
that mathematics makes use of a very large collection of
symbols. It is difficult to write mathematics fluently if these
characters are not available for use. It is difficult
to read mathematics if corresponding glyphs are not available
for presentation on specific display devices.
</p>
<p>The W3C Math Working Group therefore took on the job
of specifying part of the mechanism needed to proceed from
notation to final presentation, and has collaborated with the
<a href="http://www.unicode.org/">Unicode Technical Committee</a>
(UTC) and the <a href="http://www.stixfonts.org/">STIX Fonts Project</a>
in undertaking specification of the rest.
</p>
<p>This chapter contains discussion of
characters for use within MathML, recommendations for their use,
and warnings concerning the correct form of the
corresponding code points given in the Universal Multiple-Octet Coded Character
Set (UCS) <a href="appendixg-d.html#ISO10646">[ISO10646]</a> as codified in Unicode <a href="appendixg-d.html#Unicode">[Unicode]</a>.
For simplicity we refer to this character set by the short name Unicode.
Unless otherwise stated, the mappings discussed in this chapter and
elsewhere in the MathML 3.0 recommendation are based on Unicode 5.2.
Conformant MathML processors (see <a href="chapter2-d.html#interf.genproc">Section 2.3 Conformance</a>) are
free to use characters defined in Unicode 5.2 or later.
</p>
<p>While a long process of review and adoption by UTC and ISO/IEC
of the characters of special interest to mathematics and MathML is
now complete, more characters may be added in the future. For the latest
character tables and font information,
see the <a href="appendixg-d.html#Entities">[Entities]</a> and the <a href="http://www.unicode.org/">Unicode
Home Page</a>, notably
<a href="http://www.unicode.org/unicode/alloc/Pipeline.html">Unicode Work
in Progress</a> and
<a href="http://www.unicode.org/reports/tr25/tr25-8.html">
Unicode Technical Report #25 “Unicode Support for Mathematics”</a>.
</p>
<p>
A MathML token element (see <a href="chapter3-d.html#presm.tokel">Section 3.2 Token Elements</a>, <a href="chapter4-d.html#contm.cn">Section 4.2.1 Numbers <code><cn></code></a>,
<a href="chapter4-d.html#contm.ci">Section 4.2.2 Content Identifiers <code><ci></code></a>, <a href="chapter4-d.html#contm.csymbol">Section 4.2.3 Content Symbols <code><csymbol></code></a>) takes as content a
sequence of MathML characters or <code>mglyph</code> elements. The latter are
used to represent characters that do not have a Unicode encoding, as described in <a href="chapter3-d.html#presm.mglyph">Section 3.2.1.2 <code><mglyph/></code></a>. The need for <code>mglyph</code> should be rare because Unicode 3.1
provided approximately one thousand alphabetic characters for mathematics, and
Unicode 3.2 added over 900 more special mathematical symbols.
</p>
</div>
<div class="div2">
<h2><a name="chars.unicodechars" id="chars.unicodechars"></a>7.2 Unicode Character Data
</h2>
<p>
Any character allowed by XML may be used in MathML. More precisely,
the legal Unicode characters have the hexadecimal code
numbers 09 (tab = U+0009), 0A (line feed = U+000A), 0D (carriage
return = U+000D), 20-D7FF (U+0020..U+D7FF), E000-FFFD
(U+E000..U+FFFD), and 10000-10FFFF (U+10000..U+10FFFF).
The exclusions above code number D7FF are of the blocks used
in surrogate pairs, and the two characters guaranteed not to be
Unicode characters at all. U+FFFE is excluded to allow determination
of byte order in certain encodings.
</p>
<p>
There are essentially three different ways of encoding character data
in an XML document.
</p>
<ul>
<li>
<p>Using characters directly: For example, the 'é' (character U+00E9 [LATIN SMALL LETTER E WITH ACUTE]) may have been inserted.
This option is only useful
if the character encoding specified for the XML document includes
the character intended. Note that if the document is, for example,
encoded in
Latin-1 (ISO-8859-1) then <em>only</em> the characters in that
encoding are available directly; for instance character
U+00E9 (eacute) is, but character
U+03B1 (alpha) is not.
</p>
</li>
<li>
<p>
Using numeric XML character references: For example, 'é' may be
represented as &#233; (decimal) or &#xE9; (hex),
or &#0233; (decimal) or &#x00E9;.
Note that the numbers in the character references always refer to the Unicode encoding (and not to
the character encoding used in the XML file). By using character
references it is always possible to access the entire Unicode range.
</p>
</li>
<li>
<p>
Using entity references: The MathML DTD defines internal entities that
expand to character data. Thus for example the entity reference
&eacute; may be used rather than the character reference
&#xE9;. An XML fragment that uses an entity
reference which is not defined in a DTD is not well-formed; therefore
it will be rejected by an XML parser. For this reason
every fragment using entity references must
use a DOCTYPE declaration which specifies the MathML DTD, or a DTD
that at least declares any entity reference used in the MathML
instance. The need to use a DOCTYPE complicates inclusion of MathML in
some documents. However, entity references can be useful for small
illustrative examples.
</p>
</li>
</ul>
</div>
<div class="div2">
<h2><a name="chars.entities" id="chars.entities"></a>7.3 Entity Declarations
</h2>
<p>Earlier versions of this MathML specification included detailed
listings of the entity definitions to be used with the MathML DTD.
These entity definitions are of more general use, and have now been
separated into an ancillary document, XML Entity Definitions for
Characters <a href="appendixg-d.html#Entities">[Entities]</a>. The
tables there list the entity names and the corresponding
Unicode character references.
That document describes several entity sets; not all of them are used in
the MathML DTD. The standard MathML DTD references
the following entity sets:
</p>
<ul>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isobox.html">isobox</a> Box and Line Drawing
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isocyr1.html">isocyr1</a> Russian Cyrillic
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isocyr2.html">isocyr2</a> Non-Russian Cyrillic
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isodia.html">isodia</a> Diacritical Marks
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isolat1.html">isolat1</a> Added Latin 1
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isolat2.html">isolat2</a> Added Latin 2
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isonum.html">isonum</a> Numeric and Special Graphic
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isopub.html">isopub</a> Publishing
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamsa.html">isoamsa</a> Added Math Symbols: Arrow Relations
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamsb.html">isoamsb</a> Added Math Symbols: Binary Operators
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamsc.html">isoamsc</a> Added Math Symbols: Delimiters
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamsn.html">isoamsn</a> Added Math Symbols: Negated Relations
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamso.html">isoamso</a> Added Math Symbols: Ordinary
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isoamsr.html">isoamsr</a> Added Math Symbols: Relations
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isogrk3.html">isogrk3</a> Greek Symbols
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isomfrk.html">isomfrk</a> Math Alphabets: Fraktur
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isomopf.html">isomopf</a> Math Alphabets: Open Face
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isomscr.html">isomscr</a> Math Alphabets: Script
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/isotech.html">isotech</a> General Technical
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/mmlextra.html">mmlextra</a> Additional MathML Symbols
</p>
</li>
<li>
<p><a href="http://www.w3.org/TR/xml-entity-names/mmlalias.html">mmlalias</a> MathML Aliases
</p>
</li>
</ul>
</div>
<div class="div2">
<h2><a name="chars.mglyph" id="chars.mglyph"></a>7.4 Special Characters Not in Unicode
</h2>
<p>
For special purposes, one may need a symbol which does not have a
Unicode representation.
In these cases one may use the <a href="chapter3-d.html#presm.mglyph"><code>mglyph</code></a>
element for direct access to a glyph as an image, or (in some systems)
from a font that uses a non-Unicode encoding.
All MathML token elements accept characters in their content and
also accept an <code>mglyph</code> there.
Beware, however, that use of <code>mglyph</code> to access a font is
deprecated and the mechanism may not work in all systems. The
<code>mglyph</code> element should always supply a useful alternative
representation in its <code>alt</code> attribute.
</p>
</div>
<div class="div2">
<h2><a name="chars.BMP-SMP" id="chars.BMP-SMP"></a>7.5 Mathematical Alphanumeric Symbols
</h2>
<p>
In mathematical and scientific writing, single letters often denote
variables and constants in a given context. The increasing complexity
of science has led to the use of
certain common alphabet and font variations to provide enough special
symbols of this letter-like type. These denotations are generally
<em>not</em> letters that may be used to make up words with
recognized meanings, but individual carriers of semantics themselves.
Writing a string of such symbols is usually interpreted in terms of
some composition law, for instance, multiplication. Many letter-like
symbols may be quickly interpreted as
of a certain mathematical type by specialists in a given area:
for instance, bold symbols, whether
based on Latin or Greek letters, as vectors in physics or engineering,
or Fraktur symbols as Lie algebras in part of pure mathematics.
</p>
<p>
The additional Mathematical Alphanumeric Symbols
provided in Unicode 3.1 have
code points in the range U+1D400 to U+1D7FF in <em>Plane 1</em>, that is, in the first
plane with Unicode values higher than 2<sup>16</sup>. This plane of
characters is also known as the Secondary Multilingual Plane (SMP),
in contrast to the Basic Multilingual Plane (BMP) which
was originally the entire extent of Unicode. Support for Plane 1 characters in currently
deployed software is not always reliable, but it should be possible in
multilingual operating systems, since Plane 2 has many Chinese
characters that must be displayable in East Asian locales.
</p>
<p>
As discussed in <a href="chapter3-d.html#presm.commatt">Section 3.2.2 Mathematics style attributes common to token elements</a>, MathML offers an
alternative mechanism to specify mathematical alphanumeric characters.
This alternative mechanism spans the gap between the
specification of the mathematical alphanumeric symbols as Unicode
code points, and the deployment of software and fonts that support them.
Namely, one uses the <code>mathvariant</code> attribute on a token element
such as <code>mi</code> to indicate that the character data in the token
element selects a mathematical alphanumeric symbol.
</p>
<p>
In principle, any mathvariant value may be used with any character
data to define a specific symbolic token. In practice, only certain
combinations of character data and mathvariant values will be visually
distinguished by a given renderer.
In this section we explain the correspondence between certain characters
in Plane 0 that, when modified by the <code>mathvariant</code> attribute,
are considered equivalent to mathematical alphanumeric symbol characters.
</p>
<p>
The mathematical alphanumeric symbol characters in Plane 1 include
alphabets for Latin upper-case and lower-case letters, including
dotless i and j, Greek upper-case and lower-case letters, Greek symbols
(also known as variants), including upper-case and lower-case digamma,
and Latin digits. These alphabets provide Plane 1 Unicode code points
that differ from corresponding Plane 0 characters only by a variation
in font that carries mathematical semantics when used in a formula.
</p>
<p>
The <code>mathvariant</code> attribute uses exactly this correspondence to
provide an alternate markup encoding that selects these Plane 1 characters.
For example, the Mathematical Italic alphabet runs from U+1D434 ("A")
to U+1D467 ("z"). Thus, a typical example of an identifier for a
variable, marked up as
</p><pre class="mathml">
<mi>a</mi>
</pre><p>
and rendered in a mathematical italic font (as described in
<a href="chapter3-d.html#presm.mi">Section 3.2.3 Identifier <code><mi></code></a>) could equivalently be marked up as
</p><pre class="mathml">
<mi>&#x1D44E;<!--MATHEMATICAL ITALIC SMALL A--></mi>
</pre><p>
which invokes the Mathematical Italic lower-case a explicitly.
</p>
<p>
An important use of the mathematical alphanumeric symbols in Plane 1
is for identifiers normally printed in special mathematical fonts,
such as Fraktur, Greek, Boldface, or Script. As another example,
the Mathematical Fraktur alphabet runs from U+1D504 ("A") to U+1D537 ("z").
Thus, an identifier for a variable that uses Fraktur characters could
be marked up as
</p><pre class="mathml">
<mi>&#x1D504;<!--BLACK-LETTER CAPITAL A--></mi>
</pre><p>
An alternative, equivalent markup for this example is to use the
common upper-case A, modified by using the <code>mathvariant</code> attribute:
</p><pre class="mathml">
<mi mathvariant="fraktur">A</mi>
</pre><p>
A MathML processor must treat a mathematical alphanumeric character
(when it appears) as identical to the corresponding combination of
the unstyled character and mathvariant attribute value.
It is important to note that the mathvariant attribute specifies a
semantic class of characters, each of which has a specific appearance
that should be protected from document-wide style changes, so the
intended meaning of the character may be preserved. The use of a
mathematical alphanumeric character is also intended to preserve
this specific appearance, and so these characters are also not to
be affected by surrounding style changes.
</p>
<p>
Not all combinations of character data and mathvariant values have assigned
Unicode code points. For example, sans-serif Greek alphabets are
omitted, while bold sans-serif Greek alphabets are included, and
bold digits are included, while bold-italic digits are excluded.
A renderer should visually distinguish those combinations of character data
and mathvariant attribute values that it can subject to the
availability of font characters.
It is intended that renderers distinghish at least those combinations
that have equivalent Unicode code points, and renderers are free to
ignore those combinations that have no assigned Unicode code point
or for which adequate font support is unavailable.
</p>
<p>
The exact correspondence between a mathematical alphabetic character
and an unstyled character is complicated by the fact that certain
characters that were already present in Unicode in Plane 0 are not in
the 'expected' sequence in Plane 1. The table below shows the Plane 0
mathematical alphanumeric symbols, listing for each character its
Unicode code point, its Unicode character name, its corresponding
unstyled alphabetic character, and the code point in Plane 1 where
one might naturally have sought this character.
</p>
<table id="chars.letter-like-tables" border="1">
<thead>
<tr>
<th>Unicode code point</th>
<th>Unicode name</th>
<th>BMP code</th>
<th>Plane-1 code</th>
</tr>
</thead>
<tbody>
<tr>
<td>U+210E</td>
<td>PLANCK CONSTANT</td>
<td>U+0068</td>
<td>U+1D455</td>
</tr>
<tr>
<td>U+212C</td>
<td>SCRIPT CAPITAL B</td>
<td>U+0042</td>
<td>U+1D49D</td>
</tr>
<tr>
<td>U+2130</td>
<td>SCRIPT CAPITAL E</td>
<td>U+0045</td>
<td>U+1D4A0</td>
</tr>
<tr>
<td>U+2131</td>
<td>SCRIPT CAPITAL F</td>
<td>U+0046</td>
<td>U+1D4A1</td>
</tr>
<tr>
<td>U+210B</td>
<td>SCRIPT CAPITAL H</td>
<td>U+0048</td>
<td>U+1D4A3</td>
</tr>
<tr>
<td>U+2110</td>
<td>SCRIPT CAPITAL I</td>
<td>U+0049</td>
<td>U+1D4A4</td>
</tr>
<tr>
<td>U+2112</td>
<td>SCRIPT CAPITAL L</td>
<td>U+004C</td>
<td>U+1D4A7</td>
</tr>
<tr>
<td>U+2133</td>
<td>SCRIPT CAPITAL M</td>
<td>U+004D</td>
<td>U+1D4A8</td>
</tr>
<tr>
<td>U+211B</td>
<td>SCRIPT CAPITAL R</td>
<td>U+0052</td>
<td>U+1D4AD</td>
</tr>
<tr>
<td>U+212F</td>
<td>SCRIPT SMALL E</td>
<td>U+0065</td>
<td>U+1D4BA</td>
</tr>
<tr>
<td>U+210A</td>
<td>SCRIPT SMALL G</td>
<td>U+0067</td>
<td>U+1D4BC</td>
</tr>
<tr>
<td>U+2134</td>
<td>SCRIPT SMALL O</td>
<td>U+006F</td>
<td>U+1D4C4</td>
</tr>
<tr>
<td>U+212D</td>
<td>BLACK-LETTER CAPITAL C</td>
<td>U+0043</td>
<td>U+1D506</td>
</tr>
<tr>
<td>U+210C</td>
<td>BLACK-LETTER CAPITAL H</td>
<td>U+0048</td>
<td>U+1D50B</td>
</tr>
<tr>
<td>U+2111</td>
<td>BLACK-LETTER CAPITAL I</td>
<td>U+0049</td>
<td>U+1D50C</td>
</tr>
<tr>
<td>U+211C</td>
<td>BLACK-LETTER CAPITAL R</td>
<td>U+0052</td>
<td>U+1D515</td>
</tr>
<tr>
<td>U+2128</td>
<td>BLACK-LETTER CAPITAL Z</td>
<td>U+005A</td>
<td>U+1D51D</td>
</tr>
<tr>
<td>U+2102</td>
<td>DOUBLE-STRUCK CAPITAL C</td>
<td>U+0043</td>
<td>U+1D53A</td>
</tr>
<tr>
<td>U+210D</td>
<td>DOUBLE-STRUCK CAPITAL H</td>
<td>U+0048</td>
<td>U+1D53F</td>
</tr>
<tr>
<td>U+2115</td>
<td>DOUBLE-STRUCK CAPITAL N</td>
<td>U+004E</td>
<td>U+1D545</td>
</tr>
<tr>
<td>U+2119</td>
<td>DOUBLE-STRUCK CAPITAL P</td>
<td>U+0050</td>
<td>U+1D547</td>
</tr>
<tr>
<td>U+211A</td>
<td>DOUBLE-STRUCK CAPITAL Q</td>
<td>U+0051</td>
<td>U+1D548</td>
</tr>
<tr>
<td>U+211D</td>
<td>DOUBLE-STRUCK CAPITAL R</td>
<td>U+0052</td>
<td>U+1D549</td>
</tr>
<tr>
<td>U+2124</td>
<td>DOUBLE-STRUCK CAPITAL Z</td>
<td>U+005A</td>
<td>U+1D551</td>
</tr>
</tbody>
</table>
<p>
Mathematical Alphanumeric Symbol characters should not be used for styled prose.
For example, Mathematical Fraktur A must not be used to just select
a blackletter font for an uppercase A as it
would create problems for searching, restyling (e.g. for accessibility),
and many other kinds of processing.
</p>
</div>
<div class="div2">
<h2><a name="chars.nonmark" id="chars.nonmark"></a>7.6 Non-Marking Characters
</h2>
<p>
Some characters, although important for the quality of print or
alternative rendering, do not have glyph marks that correspond
directly to them. They are called here non-marking characters.
Their roles are
discussed in <a href="chapter3-d.html">Chapter 3 Presentation Markup</a> and <a href="chapter4-d.html">Chapter 4 Content Markup</a>.
</p>
<p>In MathML, control of page composition, such as line-breaking, is
effected by the use of the proper attributes on the <code>mo</code> and <code>mspace</code> elements.
</p>
<p>The characters below are not simple spacers. They are
especially important new additions to the UCS because they provide
textual clues which can increase the quality of print rendering,
permit correct audio rendering, and allow the unique recovery of
mathematical semantics from text which is visually ambiguous.
</p>
<table id="chars.table-white">
<thead>
<tr>
<th>Unicode code point</th>
<th>Unicode name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>U+2061</td>
<td>FUNCTION APPLICATION</td>
<td>character showing function application in presentation tagging
(<a href="chapter3-d.html#presm.mo">Section 3.2.5 Operator, Fence, Separator or Accent
<code><mo></code></a>)
</td>
</tr>
<tr>
<td>U+2062</td>
<td>INVISIBLE TIMES</td>
<td>marks multiplication when it is understood without a mark
(<a href="chapter3-d.html#presm.mo">Section 3.2.5 Operator, Fence, Separator or Accent
<code><mo></code></a>)
</td>
</tr>
<tr>
<td>U+2063</td>
<td>INVISIBLE SEPARATOR</td>
<td>used as a separator, e.g., in indices (<a href="chapter3-d.html#presm.mo">Section 3.2.5 Operator, Fence, Separator or Accent
<code><mo></code></a>)
</td>
</tr>
<tr>
<td>U+2064</td>
<td>INVISIBLE PLUS</td>
<td>marks addition, especially in constructs such as 1½
(<a href="chapter3-d.html#presm.mo">Section 3.2.5 Operator, Fence, Separator or Accent
<code><mo></code></a>)
</td>
</tr>
</tbody>
</table>
</div>
<div class="div2">
<h2><a name="chars.anomalous" id="chars.anomalous"></a>7.7 Anomalous Mathematical Characters
</h2>
<p>Some characters which occur fairly often in mathematical texts, and
have special significance there, are frequently confused with other
similar characters in the UCS. In some cases, common keyboard
characters have become entrenched as alternatives to the more appropriate
mathematical characters. In others, characters have legitimate uses in
both formulas and text, but conflicting rendering and font
conventions. All these characters are called here anomalous
characters.
</p>
<div class="div3">
<h3><a name="chars.keyboard" id="chars.keyboard"></a>7.7.1 Keyboard Characters
</h3>
<p>Typical Latin-1-based keyboards contain several characters that
are visually similar to important mathematical characters.
Consequently, these characters are frequently substituted,
intentionally or unintentionally, for their more correct mathematical
counterparts.
</p>
<div class="div4">
<h4><a name="chars.hyph-minus" id="chars.hyph-minus"></a>7.7.1.1 Minus
</h4>
<p>The most common ordinary text character which enjoys a special
mathematical use is U+002D [HYPHEN-MINUS]. As its Unicode name
suggests, it is used as a hyphen in prose contexts, and as a minus
or negative sign in formulas.
For text use, there is a specific code point U+2010 [HYPHEN] which is
intended for prose contexts, and which should render as a hyphen or
short dash.
For mathematical use, there is another code point U+2212 [MINUS SIGN]
which is intended for mathematical formulas, and which should render
as a longer minus or negative sign.
MathML renderers should treat U+002D [HYPHEN-MINUS] as equivalent to
U+2212 [MINUS SIGN] in formula contexts such as <code>mo</code>, and as
equivalent to U+2010 [HYPHEN] in text contexts such as <code>mtext</code>.
</p>
</div>
<div class="div4">
<h4><a name="chars.prime-quote" id="chars.prime-quote"></a>7.7.1.2 Apostrophes, Quotes and Primes
</h4>
<p>On a typical European keyboard there is a key available which is
viewed as an apostrophe or a single quotation mark (an upright or
right quotation mark). Thus one key is doing double duty for prose
input to enter U+0027 [APOSTROPHE] and U+2019 [RIGHT SINGLE QUOTATION
MARK]. In mathematical contexts it is also commonly used for the
prime, which should be U+2032 [PRIME]. Unicode recognizes the
overloading of this symbol and remarks that it can also signify the
units of minutes or feet. In the unstructured printed text of normal
prose the characters are placed next to one another. The U+0027
[APOSTROPHE] and U+2019 [RIGHT SINGLE QUOTATION MARK] are marked with
glyphs that are small and raised with respect to the center line of
the text. The fonts used provide small raised glyphs in the
appropriate places indexed by the Unicode codes. The U+2032 [PRIME]
of mathematics is similarly treated in fuller Unicode fonts.
</p>
<p>MathML renderers are encouraged to treat U+0027
[APOSTROPHE] as U+2032 [PRIME] when appropriate in
formula contexts.
</p>
<p>A final remark is that a ‘prime’ is often used in
transliteration of the Cyrillic character U+044C [CYRILLIC SMALL
LETTER SOFT SIGN]. This different use of primes is not part of
considerations for mathematical formulas.
</p>
</div>
<div class="div4">
<h4><a name="id.7.7.1.3" id="id.7.7.1.3"></a>7.7.1.3 Other Keyboard Substitutions
</h4>
<p>While the minus and prime characters are the most common and
important keyboard characters with more precise mathematical
counterparts, there are a number of other keyboard character
substitutions that are sometime used. For example some may expect
</p><pre class="mathml"><mo>''</mo></pre><p> to be treated as
U+2033 [DOUBLE PRIME], and analogous substitutions could perhaps be made for U+2034 [TRIPLE PRIME] and U+2057 [QUADRUPLE PRIME].
Similarly, sometimes U+007C [VERTICAL
LINE] is used for U+2223 [DIVIDES]. MathML regards these as
application-specific authoring conventions, and recommends that
authoring tools generate markup using the more precise mathematical
characters for better interoperability.
</p>
</div>
</div>
<div class="div3">
<h3><a name="chars.pseudo-scripts" id="chars.pseudo-scripts"></a>7.7.2 Pseudo-scripts
</h3>
<p>There are a number of characters in the UCS that traditionally have
been taken to have a natural ‘script’ aspect. The
visual presentation of these characters is similar to a script, that
is, raised from the baseline, and smaller than the base font size. The
degree symbol and prime characters are examples. For use in text, such
characters occur in sequence with the identifier they follow, and are
typically rendered using the same font. These characters are called
pseudo-scripts here.
</p>
<p>In almost all mathematical contexts, pseudo-script characters should
be associated
with a base expression using explicit script markup in MathML. For
example, the preferred encoding of "x prime" is
</p><pre class="mathml"><msup><mi>x</mi><mo>&#x2032;<!--PRIME--></mo></msup></pre><p>
and not
</p><pre class="mathml"><mi>x'</mi></pre><p>
or any other variants not using an explicit script construct. Note, however, that within
text contexts such as <code>mtext</code>, pseudo-scripts may be used in sequence with other character data.
</p>
<p>There are two reasons why explicit markup is preferable in
mathematical contexts. First, a problem arises with typesetting, when
pseudo-scripts are used with subscripted identifiers. Traditionally,
subscripting of x' would be rendered stacked under the prime. This is
easily accomplished with script markup, for example:
</p><pre class="mathml"><mrow><msubsup><mi>x</mi><mn>0</mn><mo>&#x2032;<!--PRIME--></mo></msubsup></mrow></pre><p>
By contrast,
</p><pre class="mathml"><mrow><msub><mi>x'</mi><mn>0</mn></msub></mrow></pre><p>
will render with staggered scripts.
</p>
<p>Note this means that a renderer of MathML will have to treat
pseudo-scripts differently from most other character codes it finds in
a superscript position; in most fonts, the glyphs for pseudo-scripts
are already shrunk and raised from the baseline.
</p>
<p>The second reason that explicit script markup is preferrable to
juxtaposition of characters is that it generally better reflects the
intended mathematical structure. For example,
</p><pre class="mathml"><msup>
<mrow><mo>(</mo><mrow><mi>f</mi><mo>+</mo><mi>g</mi></mrow><mo>)</mo></mrow>
<mo>&#x2032;<!--PRIME--></mo>
</msup></pre><p>
accurately reflects that the prime here is operating on an entire
expression, and does not suggest that the prime is acting on the final right parenthesis.
</p>
<p>However, the data model for all MathML token elements is Unicode text,
so one cannot rule out the possibility of valid MathML markup
containing constructions such as
</p><pre class="mathml"><mrow><mi>x'</mi></mrow></pre><p>
and
</p><pre class="mathml"><mrow><mi>x</mi><mo>'</mo></mrow></pre><p>
While the first form may, in some rare situations, legitmately be used
to distinguish a multi-character identifer named x' from the
derivative of a function x, such forms should generally be avoided.
Authoring and validation tools are encouraged to generate the
recommended script markup:
</p><pre class="mathml"><mrow><msup><mi>x</mi><mo>&#x2032;<!--PRIME--></mo></msup></mrow></pre><p>The U+2032 [PRIME] character is perhaps the most common
pseudo-script, but there are many others, as listed below:
</p>
<table>
<thead>
<tr>
<th colspan="2">Pseudo-script Characters</th>
</tr>
</thead>
<tbody>
<tr>
<td>U+0022</td>
<td>QUOTATION MARK</td>
</tr>
<tr>
<td>U+0027</td>
<td>APOSTROPHE</td>
</tr>
<tr>
<td>U+002A</td>
<td>ASTERISK</td>
</tr>
<tr>
<td>U+0060</td>
<td>GRAVE ACCENT</td>
</tr>
<tr>
<td>U+00AA</td>
<td>FEMININE ORDINAL INDICATOR</td>
</tr>
<tr>
<td>U+00B0</td>
<td>DEGREE SIGN</td>
</tr>
<tr>
<td>U+00B2</td>
<td>SUPERSCRIPT TWO</td>
</tr>
<tr>
<td>U+00B3</td>
<td>SUPERSCRIPT THREE</td>
</tr>
<tr>
<td>U+00B4</td>
<td>ACUTE ACCENT</td>
</tr>
<tr>
<td>U+00B9</td>
<td>SUPERSCRIPT ONE</td>
</tr>
<tr>
<td>U+00BA</td>
<td>MASCULINE ORDINAL INDICATOR</td>
</tr>
<tr>
<td>U+2018</td>
<td>LEFT SINGLE QUOTATION MARK</td>
</tr>
<tr>
<td>U+2019</td>
<td>RIGHT SINGLE QUOTATION MARK</td>
</tr>
<tr>
<td>U+201A</td>
<td>SINGLE LOW-9 QUOTATION MARK</td>
</tr>
<tr>
<td>U+201B</td>
<td>SINGLE HIGH-REVERSED-9 QUOTATION MARK</td>
</tr>
<tr>
<td>U+201C</td>
<td>LEFT DOUBLE QUOTATION MARK</td>
</tr>
<tr>
<td>U+201D</td>
<td>RIGHT DOUBLE QUOTATION MARK</td>
</tr>
<tr>
<td>U+201E</td>
<td>DOUBLE LOW-9 QUOTATION MARK</td>
</tr>
<tr>
<td>U+201F</td>
<td>DOUBLE HIGH-REVERSED-9 QUOTATION MARK</td>
</tr>
<tr>
<td>U+2032</td>
<td>PRIME</td>
</tr>
<tr>
<td>U+2033</td>
<td>DOUBLE PRIME</td>
</tr>
<tr>
<td>U+2034</td>
<td>TRIPLE PRIME</td>
</tr>
<tr>
<td>U+2035</td>
<td>REVERSED PRIME</td>
</tr>
<tr>
<td>U+2036</td>
<td>REVERSED DOUBLE PRIME</td>
</tr>
<tr>
<td>U+2037</td>
<td>REVERSED TRIPLE PRIME</td>
</tr>
<tr>
<td>U+2057</td>
<td>QUADRUPLE PRIME</td>
</tr>
</tbody>
</table>
<p>
In addition, the characters in the Unicode Superscript and Subscript block
(beginning at U+2070) should be treated as pseudo-scripts when they
appear in mathematical formulas.
</p>
<p>Note that several of these characters are common on keyboards,
including U+002A [ASTERISK], U+00B0 [DEGREE SIGN], U+2033 [DOUBLE PRIME],
and U+2035 [REVERSED PRIME] also known as a back prime.
</p>
</div>
<div class="div3">
<h3><a name="chars.comb-chars" id="chars.comb-chars"></a>7.7.3 Combining Characters
</h3>
<p>In the UCS there are many combining characters that are intended
to be used for the many accents of numerous different natural
languages. Some of them may seem to provide markup needed for
mathematical accents. They should not be used in mathematical markup.
Superscript, subscript, underscript, and overscript constructions as
just discussed above
should be used for this purpose. Of course, combining
characters may be used in multi-character identifiers as they are
needed, or in text contexts.
</p>
<p>
There is one more case where combining characters turn up naturally
in mathematical markup. Some relations have associated negations,
such as U+226F [NOT GREATER-THAN] for the negation of
U+003E [GREATER-THAN SIGN]. The glyph for U+226F [NOT GREATER-THAN]
is usually just that for U+003E [GREATER-THAN SIGN] with a slash through
it. Thus it could also be expressed by U+003E-0338 making use of
the combining slash U+0338 [COMBINING LONG SOLIDUS OVERLAY].
That is true of 25 other characters in common enough mathematical use
to merit their own Unicode code points. In the other direction there are
31 character entity names listed in <a href="appendixg-d.html#Entities">[Entities]</a> which
are to be expressed using U+0338 [COMBINING LONG SOLIDUS OVERLAY].
</p>
<p>In a similar way there are mathematical characters which have negations
given by a vertical bar overlay U+20D2 [COMBINING LONG VERTICAL LINE OVERLAY].
Some are available in pre-composed forms, and some named character entities
are given explicitly as combinations. In addition there are examples
using U+0333 [COMBINING DOUBLE LOW LINE] and
U+20E5 [COMBINING REVERSE SOLIDUS OVERLAY], and variants specified
by use of the U+FE00 [VARIATION SELECTOR-1]. For fuller listing of
these cases see the listings in <a href="appendixg-d.html#Entities">[Entities]</a>.
</p>
<p>The general rule is that a base character followed by a string of
combining characters should be treated just as though it were the
pre-composed character that results from the combination,
if such a character exists.
</p>
</div>
</div>
</div>
<div class="minitoc">
Overview: <a href="Overview-d.html">Mathematical Markup Language (MathML) Version 3.0</a><br>
Previous: 6 <a href="chapter6-d.html">Interactions with the Host Environment</a><br>
Next: A <a href="appendixa-d.html">Parsing MathML</a></div>
</body>
</html>
|