diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/isomath |
Initial commit
Diffstat (limited to 'macros/latex/contrib/isomath')
l--------- | macros/latex/contrib/isomath/README | 1 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/README.html | 880 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/README.txt | 100 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath-test.pdf | bin | 0 -> 147158 bytes | |||
-rw-r--r-- | macros/latex/contrib/isomath/isomath-test.tex | 283 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.html | 2585 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.pdf | bin | 0 -> 475097 bytes | |||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.sty | 372 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.sty.html | 1214 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.sty.txt | 372 | ||||
-rw-r--r-- | macros/latex/contrib/isomath/isomath.txt | 1113 |
11 files changed, 6920 insertions, 0 deletions
diff --git a/macros/latex/contrib/isomath/README b/macros/latex/contrib/isomath/README new file mode 120000 index 0000000000..c3ca07460a --- /dev/null +++ b/macros/latex/contrib/isomath/README @@ -0,0 +1 @@ +README.txt
\ No newline at end of file diff --git a/macros/latex/contrib/isomath/README.html b/macros/latex/contrib/isomath/README.html new file mode 100644 index 0000000000..708196e29f --- /dev/null +++ b/macros/latex/contrib/isomath/README.html @@ -0,0 +1,880 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> +<meta name="generator" content="Docutils 0.10: http://docutils.sourceforge.net/" /> +<title>isomath</title> +<meta name="date" content="2012-09-04" /> +<meta name="copyright" content="© 2008, 2012 Günter Milde <milde@users.sf.net>" /> +<style type="text/css"> + +/* +:Author: David Goodger (goodger@python.org) +:Id: $Id: html4css1.css 7434 2012-05-11 21:06:27Z milde $ +:Copyright: This stylesheet has been placed in the public domain. + +Default cascading style sheet for the HTML output of Docutils. + +See http://docutils.sf.net/docs/howto/html-stylesheets.html for how to +customize this style sheet. +*/ + +/* used to remove borders from tables and images */ +.borderless, table.borderless td, table.borderless th { + border: 0 } + +table.borderless td, table.borderless th { + /* Override padding for "table.docutils td" with "! important". + The right padding separates the table cells. */ + padding: 0 0.5em 0 0 ! important } + +.first { + /* Override more specific margin styles with "! important". */ + margin-top: 0 ! important } + +.last, .with-subtitle { + margin-bottom: 0 ! important } + +.hidden { + display: none } + +a.toc-backref { + text-decoration: none ; + color: black } + +blockquote.epigraph { + margin: 2em 5em ; } + +dl.docutils dd { + margin-bottom: 0.5em } + +object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] { + overflow: hidden; +} + +/* Uncomment (and remove this text!) to get bold-faced definition list terms +dl.docutils dt { + font-weight: bold } +*/ + +div.abstract { + margin: 2em 5em } + +div.abstract p.topic-title { + font-weight: bold ; + text-align: center } + +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + margin: 2em ; + border: medium outset ; + padding: 1em } + +div.admonition p.admonition-title, div.hint p.admonition-title, +div.important p.admonition-title, div.note p.admonition-title, +div.tip p.admonition-title { + font-weight: bold ; + font-family: sans-serif } + +div.attention p.admonition-title, div.caution p.admonition-title, +div.danger p.admonition-title, div.error p.admonition-title, +div.warning p.admonition-title { + color: red ; + font-weight: bold ; + font-family: sans-serif } + +/* Uncomment (and remove this text!) to get reduced vertical space in + compound paragraphs. +div.compound .compound-first, div.compound .compound-middle { + margin-bottom: 0.5em } + +div.compound .compound-last, div.compound .compound-middle { + margin-top: 0.5em } +*/ + +div.dedication { + margin: 2em 5em ; + text-align: center ; + font-style: italic } + +div.dedication p.topic-title { + font-weight: bold ; + font-style: normal } + +div.figure { + margin-left: 2em ; + margin-right: 2em } + +div.footer, div.header { + clear: both; + font-size: smaller } + +div.line-block { + display: block ; + margin-top: 1em ; + margin-bottom: 1em } + +div.line-block div.line-block { + margin-top: 0 ; + margin-bottom: 0 ; + margin-left: 1.5em } + +div.sidebar { + margin: 0 0 0.5em 1em ; + border: medium outset ; + padding: 1em ; + background-color: #ffffee ; + width: 40% ; + float: right ; + clear: right } + +div.sidebar p.rubric { + font-family: sans-serif ; + font-size: medium } + +div.system-messages { + margin: 5em } + +div.system-messages h1 { + color: red } + +div.system-message { + border: medium outset ; + padding: 1em } + +div.system-message p.system-message-title { + color: red ; + font-weight: bold } + +div.topic { + margin: 2em } + +h1.section-subtitle, h2.section-subtitle, h3.section-subtitle, +h4.section-subtitle, h5.section-subtitle, h6.section-subtitle { + margin-top: 0.4em } + +h1.title { + text-align: center } + +h2.subtitle { + text-align: center } + +hr.docutils { + width: 75% } + +img.align-left, .figure.align-left, object.align-left { + clear: left ; + float: left ; + margin-right: 1em } + +img.align-right, .figure.align-right, object.align-right { + clear: right ; + float: right ; + margin-left: 1em } + +img.align-center, .figure.align-center, object.align-center { + display: block; + margin-left: auto; + margin-right: auto; +} + +.align-left { + text-align: left } + +.align-center { + clear: both ; + text-align: center } + +.align-right { + text-align: right } + +/* reset inner alignment in figures */ +div.align-right { + text-align: inherit } + +/* div.align-center * { */ +/* text-align: left } */ + +ol.simple, ul.simple { + margin-bottom: 1em } + +ol.arabic { + list-style: decimal } + +ol.loweralpha { + list-style: lower-alpha } + +ol.upperalpha { + list-style: upper-alpha } + +ol.lowerroman { + list-style: lower-roman } + +ol.upperroman { + list-style: upper-roman } + +p.attribution { + text-align: right ; + margin-left: 50% } + +p.caption { + font-style: italic } + +p.credits { + font-style: italic ; + font-size: smaller } + +p.label { + white-space: nowrap } + +p.rubric { + font-weight: bold ; + font-size: larger ; + color: maroon ; + text-align: center } + +p.sidebar-title { + font-family: sans-serif ; + font-weight: bold ; + font-size: larger } + +p.sidebar-subtitle { + font-family: sans-serif ; + font-weight: bold } + +p.topic-title { + font-weight: bold } + +pre.address { + margin-bottom: 0 ; + margin-top: 0 ; + font: inherit } + +pre.literal-block, pre.doctest-block, pre.math, pre.code { + margin-left: 2em ; + margin-right: 2em } + +pre.code .ln { /* line numbers */ + color: grey; +} + +.code { + background-color: #eeeeee +} + +span.classifier { + font-family: sans-serif ; + font-style: oblique } + +span.classifier-delimiter { + font-family: sans-serif ; + font-weight: bold } + +span.interpreted { + font-family: sans-serif } + +span.option { + white-space: nowrap } + +span.pre { + white-space: pre } + +span.problematic { + color: red } + +span.section-subtitle { + /* font-size relative to parent (h1..h6 element) */ + font-size: 80% } + +table.citation { + border-left: solid 1px gray; + margin-left: 1px } + +table.docinfo { + margin: 2em 4em } + +table.docutils { + margin-top: 0.5em ; + margin-bottom: 0.5em } + +table.footnote { + border-left: solid 1px black; + margin-left: 1px } + +table.docutils td, table.docutils th, +table.docinfo td, table.docinfo th { + padding-left: 0.5em ; + padding-right: 0.5em ; + vertical-align: top } + +table.docutils th.field-name, table.docinfo th.docinfo-name { + font-weight: bold ; + text-align: left ; + white-space: nowrap ; + padding-left: 0 } + +h1 tt.docutils, h2 tt.docutils, h3 tt.docutils, +h4 tt.docutils, h5 tt.docutils, h6 tt.docutils { + font-size: 100% } + +ul.auto-toc { + list-style-type: none } + +</style> +<style type="text/css"> + +/* html4css2.css: Cascading style sheet for Docutils' html4strict writer. */ +/* */ +/* :Author: Günter Milde */ +/* :Copyright: © 2009 Günter Milde. */ +/* Released without warranties or conditions of any kind */ +/* under the terms of the Apache License, Version 2.0 */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* This stylesheet supplements the Docutils standard style 'html4css1.css'. */ +/* It uses CSS 2.1 elements (supported by up-to-date versions of popular */ +/* browsers). */ + +/* General rules */ +/* ============= */ + +body { + padding: 0 5%; + margin: 8px 0; + line-height:1.3; + /* http://ilovetypography.com/2008/02/28/a-guide-to-web-typography/ + recommends "line-spacing that’s at least 140% of your text size" */ + counter-reset: table; + /* counter-reset: figure; */ +} + +/* avoid long lines --> better reading */ +/* OTOH: lines should not be too short because of missing hyphenation, */ +div.document { + max-width: 45em; + margin: auto; +} + +/* separate items except for compact lists */ +dl > dd { + margin-bottom: 1em; +} +.compact li, .compact p, .compact ul, .compact ol +dl.simple > dd, .simple li, .simple p, .simple ul, .simple ol { + margin-top: 0; + margin-bottom: 0; +/* background: magenta; */ +} +dl.simple, dl.compact, dl.simple > dd, dl.compact > dd { + margin-top: 0; + margin-bottom: 0; +/* background: lightgreen; */ +} + +/* space around paragraphs */ +dl > dd p:first-child, td > p { + margin: 0; +} + +/* Sidebar */ +/* ------- */ + +div.sidebar { + margin-right: -5%; +} + +/* Special definition lists */ +/* ======================== */ + +/* bold definition term on the same line as the label */ +dl.field-list > dt, dl.option-list > dt, dl.docinfo > dt, +dl.footnote > dt, dl.citation > dt, dl.description > dt { + clear: left; + float: left; + margin: 0; + padding: 0; + padding-right: 0.5em; + font-weight: bold; +} +/* except for these */ +dl.option-list > dt, dl.footnote > dt { + font-weight: normal; +} + + + +/* Field Lists */ +/* ----------- */ + +/* field names followed by a colon */ +dl.field-list > dt:after, dl.docinfo > dt:after { + content: ":"; +} + +/* Offset for field content (corresponds to the --field-name-limit option) */ +dl.field-list > dd { + margin-left: 9em; /* ca. 14 chars in the test examples */ + padding-left: 0.5em; +} + +/* start field-body on a new line after long field names */ +dl.field-list > dd p { + width: 100%; +/* display: inline-block; */ +/* background: yellow; */ +} + +dl.field-list > dd > p:first-child, +/* dl.field-list > dd > ol:first-child, */ +/* dl.field-list > dd > ul:first-child, */ +dl.field-list > dd > dl:first-child { + display: inline-block; +} + +/* field-list variants:: */ + +/* example for custom field-name width */ +dl.field-list.narrow > dd { + margin-left: 5em; +} + +/* start field-body on same line after long field names */ +dl.field-list.run-in > dd p { + display: block; +} + +/* wrap or truncate long field names */ +dl.field-list.fix-labelwidth > dt { + width: 8em; /* set to dl.field-list > dd margin-left - padding-left */ + overflow: hidden; +} +dl.field-list.fix-labelwidth > dd:after { + /* a "stopper" to prevent next dd floating up too far */ + content: ''; + display: block; + clear: left; +} + +/* docinfo */ + +dl.docinfo > dd { + margin-left: 8em; +/* margin-bottom: 0.5em; */ +} + + +/* option list */ + +dl.option-list { + margin-left: 1em; + padding-left: 0; +} + +dl.option-list > dd { + margin-left: 8em; + /* margin-bottom: 0.5em; */ +} + +/* start description on a new line after long options */ +dl.option-list > dd p { + width: 100%; + display: inline-block; +} + +/* footnotes */ + +a.footnote-reference, a.fn-backref { + text-decoration: inherit; /* do not underline footnote links */ +} + +dl.footnote { + /* line on the left */ + padding-left: 1ex; + border-left: solid; + border-left-width: thin; + /* border-color: black; */ +} + +/* paragraph on same line as backrefs */ +dd > em { +/* background: green; */ + float: left; + margin-right: 1ex +} + + +/* +Ordered List (Enumeration) +-------------------------- + +Use counters to replace the deprecated start attribute. Make sure the +resulting list resembles the list-style 'outside' with a hanging indent. +*/ + +/* New ordered list: reset counter, suppress the default label */ +ol, ol.arabic, ol.loweralpha, ol.upperalpha, +ol.lowerroman, ol.upperroman { + counter-reset: item; + list-style: none +} + +/* Set the negative indent of the list label as feature of the list item */ +ol > li { + text-indent: -40px; /* Mozillas default indent */ +} +/* reset for child elements */ +ol > li > * { + text-indent: 0px; + text-indent: 0; + margin-top: 0; + /* background: lightgreen; */ +} + +/* Label */ +ol > li:before { + /* increment and typeset counter(s), */ + counter-increment: item; + content: counter(item) "."; + /* display next to the content (aligned top-right), */ + display: inline-block; + text-align: right; + vertical-align: top; + /* sum must match ol>li {text-indent:} (40px is Mozillas default) */ + width: 35px; + padding-right: 5px; +/* background: yellow; */ +} + +/* The list item's first line starts next to the label, without indent */ +ol > li > p:first-child, +ol > li > ol:first-child, +ol > li > ul:first-child, +ol > li > dl:first-child { + display: inline-block; + /* background: lightblue; */ +} + +/* default separator variants */ +ol.loweralpha > li:before { + content: counter(item, lower-alpha) ")"; +} +ol.upperalpha > li:before { + content: counter(item, upper-alpha) "."; +} +ol.lowerroman > li:before { + content: "(" counter(item, lower-roman) ")"; +} +ol.upperroman > li:before { + content: counter(item, upper-roman) ")"; +} +/* nested counters (1, 1.1, 1.1.1, etc) */ +/* nested enumerated lists "inherit" the class attribute, other lists not */ +ol.nested > li:before, ol.nested ol > li:before { + content: counters(item, ".") " "; +} + +/* lists nested in definition list */ + +dd > ul, dd > ol { + padding-left: 0pt; +} + +/* TODO: prefix, suffix? */ + +/* smaller font for super- and subscripts */ +/* sub, sup {font-size: 70%;} */ /* Mozilla default is `smaller` */ + + +/* Tables */ +/* ====== */ + +/* margins and borders for "normal" tables */ +table { +/* background: magenta; */ + margin-top: 1em ; + margin-bottom: 1em; +/* border-style: outset; */ + border-style: solid; + border-color: silver; + border-width: thin; + border-collapse: collapse; +} +blockquote > table { + margin-top: 0em ; + margin-bottom: 0em; +} + +td, th { + border-style: solid; + border-width: thin; + border-color: silver; + /* text-align: left; */ + padding: 0 1ex; +} + +td > p:first-child, th > p:first-child { + margin-top: 0; +} +td > p, th > p { + margin-bottom: 0; +} + +/* no borders for "borderless" tables */ +table.borderless, table.borderless * { + border-style: none; +} + +/* "booktabs" style (no vertical lines) */ +table.booktabs { + border: 0; + border-top: 2px solid; + border-bottom: 2px solid; +} + +table.booktabs * { + border: 0; +} +table.booktabs th { + border-bottom: thin solid; +} + +table > caption { + text-align: left; + margin-bottom: 0.25em +/* padding: 2em 0 1em 0; */ +} + +/* numbered tables*/ +table.numbered > caption:before { + counter-increment: table; /* defined/re-set in body */ + content: "Table " counter(table) ": "; + font-weight: bold; +} + + +/* literal text + ------------ +*/ +/* whitespace and wrapping in inline literals */ +/* possible values: normal, nowrap, pre, pre-wrap, pre-line */ +tt.literal { + white-space: pre-wrap; +} + +/* /* compensate for initial line-break (which is literal with XHTML 1.1) */ */ +/* pre.literal-block, pre.doctest-block { */ +/* margin-top: 0em ; */ +/* } */ + +/* Table of Contents */ + +/* don't indent like a topic */ +div.topic.contents { + margin: 0; +} +/* div.topic.contents ul { */ +/* list-style: none; */ +/* } */ + +div.topic.contents a { + text-decoration: none; /* no underline for links */ +} + +/* section numbers */ + +span.sectnum { + padding-right: 1ex; +} + +/* admonitions */ + +/* no padding for top and bottom */ +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + padding: 0px 1em } + +</style> +<style type="text/css"> + +/* Stylesheet for isomath documentation +:Copyright: 2008 G. Milde + This stylesheet is released under the GPL v. 2 +*/ + +dl.docutils dt { font-weight: bold; } + +/* docinfo */ + +dl.docinfo > dt { display: none; } +dl.docinfo > dd { + margin-left: 0; + padding: 0 5%; +} +dl.docinfo > dt.author + dd { + font-size: larger; + text-align: center; + padding-bottom: 1em; +} +dt.date { + display: none; +} +dt.date + dd { + font-weight: bold; + text-align: center; + padding-bottom: 1em; +} + +div.abstract { + padding: 0 5%; +} + +a.reference.internal { + text-decoration: none; + color: darkblue; +} + +a.reference.external { + text-decoration: underline; +} + +/* a.reference.external:after { */ +/* content: "⎘"; */ +/* font-size: x-small; */ +/* vertical-align: super; */ +/* } */ + +dl.footnote > dd { + margin-left: 1.2em; +} +dl.footnote > dt { + font-size: small; + vertical-align: super; +} + +a.footnote-reference > sup { + font-size: small; + vertical-align: super; + } + +td, th { + padding-bottom: 0.1ex; + padding-top: 0.1ex; +} + +/* let borderless overreide booktab */ +.booktabs.borderless, +table.booktabs.borderless td, table.booktabs.borderless th { + border: 0; + margin-left: 2em; + } + +table.docutils td, table.docutils th, + vertical-align: bottom; } + +</style> +</head> +<body> +<div class="document" id="isomath"> +<h1 class="title">isomath</h1> +<h2 class="subtitle" id="mathematical-style-for-science-and-technology">Mathematical style for science and technology</h2> + +<dl class="docinfo simple"> +<dt class="date">Date</dt> +<dd class="date">2012-09-04</dd> +<dt class="copyright">Copyright</dt> +<dd class="copyright">© 2008, 2012 Günter Milde <<a class="reference external" href="mailto:milde@users.sf.net">milde@users.sf.net</a>></dd> +<dt>Licence</dt> +<dd><p>This work may be distributed and/or modified under the +conditions of the <a class="reference external" href="http://www.latex-project.org/lppl.txt">LaTeX Project Public License</a>, either +version 1.3 of this license or (at your option) any later version.</p> +</dd> +</dl> +<div class="abstract topic"> +<p class="topic-title first">Abstract</p> +<p>The <cite>isomath</cite> package provides tools for a mathematical style +that conforms to the International Standard ISO 80000-2 and is +common in science and technology: capital Greek letters in italic +shape, bold italic and sans-serif bold italic math alphabets with +Latin and Greek characters, and macros for markup of vector, +matrix and tensor symbols.</p> +</div> +<div class="section" id="files"> +<h1>Files</h1> +<table class="booktabs numbered align-left"> +<colgroup> +<col width="32%" /> +<col width="68%" /> +</colgroup> +<tbody> +<tr><td><p>README.txt</p></td> +<td><p>Requirements, Installation, Usage</p></td> +</tr> +<tr><td><p>README.html</p></td> +<td><p>Requirements, Installation, Usage (HTML)</p></td> +</tr> +<tr><td><p>isomath.sty</p></td> +<td><p>literate source (the actual LaTeX package)</p></td> +</tr> +<tr><td><p>isomath.sty.txt</p></td> +<td><p>literate source (text version)</p></td> +</tr> +<tr><td><p>isomath.sty.html</p></td> +<td><p>literate source (HTML)</p></td> +</tr> +<tr><td><p>isomath.txt</p></td> +<td><p>user documentation (source)</p></td> +</tr> +<tr><td><p>isomath.html</p></td> +<td><p>user documentation (HTML)</p></td> +</tr> +<tr><td><p>isomath.pdf</p></td> +<td><p>user documentation (PDF)</p></td> +</tr> +<tr><td><p>isomath-test.tex</p></td> +<td><p>Test example (source)</p></td> +</tr> +<tr><td><p>isomath-test.pdf</p></td> +<td><p>Test example (PDF output)</p></td> +</tr> +</tbody> +</table> +<p>The bidirectional text <-> code converter <a class="reference external" href="http://pylit.berlios.de">PyLit</a> can convert between +<tt class="literal">isomath.sty</tt> and <tt class="literal">isomath.sty.txt</tt>.</p> +<p>The <a class="reference external" href="http://docutils.sourceforge.net/rst.html">Docutils</a> and pdflatex were used to generate the HTML and PDF +documentation from the <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> sources.</p> +</div> +<div class="section" id="requirements"> +<h1>Requirements</h1> +<p>This package builds on and extends <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a> by Walter Schmidt. +It also requires <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html">kvoptions</a>.</p> +<p>The <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/cmbright.html">cmbright</a> package is recommended for <em>sans-serif italic</em> and <em>sans-serif +bold italic</em> fonts matching with Computer Modern and derivatives.</p> +<p>All required packages are part of TeXLive and MikTeX.</p> +</div> +<div class="section" id="installation"> +<h1>Installation</h1> +<p>If possible, get this package from your distribution using its installation +manager.</p> +<p>Otherwise, make sure LaTeX can find the file <cite>isomath.sty</cite>:</p> +<ul class="simple"> +<li><p>Download and unpack <cite>isomath.zip</cite> or just download <cite>isomath.sty</cite>.</p></li> +<li><p>Copy/Move/Link <tt class="literal">isomath.sty</tt> to a suitable place in the <a class="reference external" href="http://www.tex.ac.uk/cgi-bin/texfaq2html?label=tds">TDS</a> and run +<tt class="literal">texhash</tt>, or place it in the current working directory (e.g. for +testing).</p></li> +</ul> +</div> +<div class="section" id="usage"> +<h1>Usage</h1> +<p>Load the package and (optionally) change the default <tt class="literal">\vec</tt> macro with:</p> +<pre class="literal-block">\usepackage{isomath} +\renewcommand{\vec}{\vectorsym} % optional +</pre> +<p>Option description, more examples and usage hints are in the <a class="reference external" href="isomath.sty.html">user +documentation</a>.</p> +<!-- References +========== --> +</div> +</div> +</body> +</html> diff --git a/macros/latex/contrib/isomath/README.txt b/macros/latex/contrib/isomath/README.txt new file mode 100644 index 0000000000..107c024a5d --- /dev/null +++ b/macros/latex/contrib/isomath/README.txt @@ -0,0 +1,100 @@ +isomath +******* +Mathematical style for science and technology +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +:Author: Günter Milde +:Date: 2012-09-10 +:Copyright: © 2008, 2012 Günter Milde <milde@users.sf.net> +:Licence: This work may be distributed and/or modified under the + conditions of the `LaTeX Project Public License`_, either + version 1.3 of this license or (at your option) any later version. + +:Abstract: The `isomath` package provides tools for a mathematical style + that conforms to the International Standard ISO 80000-2 and is + common in science and technology. It changes the default shape of + capital Greek letters to italic, sets up bold italic and + sans-serif bold italic math alphabets with Latin and Greek + characters, and defines macros for markup of vector, matrix and + tensor symbols. + +Files +===== + +==================== ================================= +README.txt Requirements, Installation, Usage +README.html Requirements, Installation, Usage (HTML) + +isomath.sty literate source (the actual LaTeX package) +isomath.sty.txt literate source (text version) +isomath.sty.html literate source (HTML) + +isomath.txt user documentation (source) +isomath.html user documentation (HTML) +isomath.pdf user documentation (PDF) + +isomath-test.tex Test example (source) +isomath-test.pdf Test example (PDF output) +==================== ================================= + +The bidirectional text <-> code converter PyLit_ can convert between +``isomath.sty`` and ``isomath.sty.txt``. + +The Docutils_ and pdflatex were used to generate the HTML and PDF +documentation from the reStructuredText_ sources. + + +Requirements +============ + +This package builds on and extends fixmath_ by Walter Schmidt. +It also requires kvoptions_. + +The cmbright_ package is recommended for *sans-serif italic* and *sans-serif +bold italic* fonts matching with Computer Modern and derivatives. + +All required packages are part of TeXLive and MikTeX. + + +Installation +============ + +If possible, get this package from your distribution using its installation +manager. + +Otherwise, make sure LaTeX can find the file `isomath.sty`: + +* Download and unpack `isomath.zip` or just download `isomath.sty`. + +* Copy/Move/Link ``isomath.sty`` to a suitable place in the TDS_ and run + ``texhash``, or place it in the current working directory (e.g. for + testing). + + + +Usage +===== + +Load the package and (optionally) change the default ``\vec`` macro with:: + + \usepackage{isomath} + \renewcommand{\vec}{\vectorsym} % optional + +Option description, more examples and usage hints are in the `user +documentation`_. + +.. References + ========== + +.. _LaTeX Project Public License: http://www.latex-project.org/lppl.txt +.. _PyLit: http://pylit.berlios.de +.. _reStructuredText: http://docutils.sourceforge.net/rst.html +.. _Docutils: http://docutils.sourceforge.net/rst.html + +.. _cmbright: http://mirror.ctan.org/help/Catalogue/entries/cmbright.html +.. _fixmath: http://mirror.ctan.org/help/Catalogue/entries/fixmath.html +.. _kvoptions: http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html + +.. _TDS: http://www.tex.ac.uk/cgi-bin/texfaq2html?label=tds + +.. _user documentation: isomath.sty.html diff --git a/macros/latex/contrib/isomath/isomath-test.pdf b/macros/latex/contrib/isomath/isomath-test.pdf Binary files differnew file mode 100644 index 0000000000..083afc40d1 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath-test.pdf diff --git a/macros/latex/contrib/isomath/isomath-test.tex b/macros/latex/contrib/isomath/isomath-test.tex new file mode 100644 index 0000000000..daed2193a5 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath-test.tex @@ -0,0 +1,283 @@ +% isomath-test.tex: test and template for isomath.sty +% =================================================== +% +% Copyright © 2008 Günter Milde +% Released under the terms of the GNU General Public License (v. 2 or later) +% +% General settings +% ---------------- +% :: + +\documentclass[a4paper]{article} +\usepackage[T1]{fontenc} +% \usepackage[utf8]{inputenc} +\usepackage{amsmath} +\pagestyle{empty} + + +% Customisation +% ------------- +% +% Font packages +% ~~~~~~~~~~~~~ +% +% (Auxiliary commands for package and option selection, so that the +% selections can be shown in the test sheet.) +% +% Uncomment the package you want to test :: + +\newcommand*{\fontsetup}{\usepackage% +% {ae}% \sfdefault is cmss +% {anttor}% \sfdefault is cmss (use iwona) +% {arev}% normal and sans identic (also in math) +% {beton}% bitmap fonts +% {concmath}% +% {cmbright}% +% {fourier}% incompatible (uses private font encoding) +% [default]{gfsneohellenic}% no bold +% {hfoldsty}% bitmap fonts +% {iwona}% sets cmss as sans font (use iwona) +% [nomathscript]{kpfonts}% "Too many math alphabets" with OMLmathsfit option +% {kerkis}% no bold math, +% {lmodern}% \sfdefault is cmss +% {lucidabr}% commercial, subset (no math) free as bitmap +% {lxfonts}% normal and sans identic, +[utopia]{mathdesign}% \sfdefault is cmss, provides roman and roman-bold in OML +% [charter]{mathdesign}% +% [garamond]{mathdesign}% +% {mathptmx}% in mathnormal, Greek is larger than Latin! +% {mbtimes}% \sfdefault is cmss +% {mathpazo}% \sfdefault is cmss +% {newcent}% \sfdefault is cmss +% {pxfonts}% needs reuseMathAlphabets, no sans-serif +% {tgcursor}% avoid bitmap tt +% {tgheros}% avoid bitmap sf +% {tgpagella}% \sfdefault is cmss +% {tgtermes}% \sfdefault is cmss +% {txfonts}% no sans-serif +} + +% Isomath setup +% ~~~~~~~~~~~~~ +% +% Uncomment the option(s) you want to test :: + +\newcommand*{\isomathsetup}{\usepackage[% +% reuseMathAlphabets,% +OMLmathrm,% +OMLmathbf,% +% OMLmathsf,% +% OMLmathsfit,% +% OMLmathtt,% +% OMLmathsans,% backwards compatibility option alias +% rmdefault=zpple,% Mathpazo alternative +% rmdefault=qtxmia,% TeX Gyre Termes math with alternative glyphs +% sfdefault=cmbr,% default +% sfdefault=iwona,% Iwona sans (Greek glyphs too close to roman) +sfdefault=fav,% Arev sans (scale down (ca. 0.87)) +scaled=0.875% scaling for Arev (small letters) +% sfdefault=llcmss,% LX sans (glyphs too close to italic, scale down) +% sfdefault=jkpss,% Kepler Sans +% scaled=0.95% scaling for Kepler Sans (small letters) +]{isomath}% +} + +% Load customisable packages +% -------------------------- +% :: + +\fontsetup +\isomathsetup + +% Auxiliary definitions +% --------------------- +% +% Re-define \vec to comply with ISO 31:: + +\renewcommand*{\vec}{\vectorsym} + +% Fall-back definition for \mathsfit:: + +\providecommand*{\mathsfit}[1]% +{\emph{mathsfit not defined (requires \texttt{OMLmathsfit} option)}} + + +% use Arev as "heavy" sans serif font:: + +\DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [0.875] zavmbi7m}{} +\SetMathAlphabet{\mathsfbfit}{bold}{OML}{fav}{bx}{it} + + +% Test sheet +% ---------- +% :: + +\begin{document} + +\section*{Test the isomath Package} + + +% Print font package, isomath options, and resulting font families:: + +Font Setup: \detokenize\expandafter{\fontsetup}\\ +Isomath: \detokenize\expandafter{\isomathsetup}\\ +Default font families: +\makeatletter +\begin{tabular}[t]{lrlrl} + Text & serif & \textsf{\rmdefault} & + sans-serif & \textsf{\sfdefault}\\ + Math & serif & \textsf{\isomath@rmdefault} & + sans-serif & \textsf{\isomath@sfdefault}\\ +\end{tabular} +\makeatother + +% A teststring with Latin and Greek letters:: + +\newcommand{\teststring}{% +% capital Latin letters +A,B,C, +% capital Greek letters +\Gamma,\Delta,\Theta,\Lambda,\Xi,\Pi,\Sigma,\Upsilon,\Phi,\Psi,\Omega, +% small Greek letters +\alpha,\beta,\pi,\nu,\omega, +% small Latin letters: +% compare \nu, \omega, v, and w +v,w, +% is there a true italic form of a and g? +a,g, +% digits +0,1,9 +} + +\subsection*{Math alphabets} + +If there are other symbols in place of Greek letters in a math +alphabet, it uses T1 or OT1 font encoding instead of OML. + +\begin{eqnarray*} +\mbox{mathnormal} & & \teststring \\ +\mbox{mathit} & & \mathit{\teststring}\\ +\mbox{mathrm} & & \mathrm{\teststring}\\ +\mbox{mathbf} & & \mathbf{\teststring}\\ +\mbox{mathsf} & & \mathsf{\teststring}\\ +\mbox{mathtt} & & \mathtt{\teststring} +\end{eqnarray*} + New alphabets bold-italic, sans-serif-italic, and sans-serif-bold-italic. +\begin{eqnarray*} +\mbox{mathbfit} & & \mathbfit{\teststring}\\ +\mbox{mathsfit} & & \mathsfit{\teststring}\\ +\mbox{mathsfbfit} & & \mathsfbfit{\teststring} +\end{eqnarray*} +% +Do the math alphabets match? + +$ +\mathnormal {a x \alpha \omega} +\mathbfit {a x \alpha \omega} +\mathsfbfit{a x \alpha \omega} +\quad +\mathsfbfit{T C \Theta \Gamma} +\mathbfit {T C \Theta \Gamma} +\mathnormal {T C \Theta \Gamma} +$ + +\subsection*{Vector symbols} + +Alphabetic symbols for vectors are boldface italic, +$\vec{\lambda}=\vec{e}_{1}\cdot\vec{a}$, +while numeric ones (e.g. the zero vector) are bold upright, +$\vec{a} + \vec{0} = \vec{a}$. + +\subsection*{Matrix symbols} + +Symbols for matrices are boldface italic, too:% +\footnote{However, matrix symbols are usually capital letters whereas vectors +are small ones. Exceptions are physical Quantities like the force +vector $\vec{F}$ or the electrical field $\vec{E}$.% +} +$\matrixsym{\Lambda}=\matrixsym{E}\cdot\matrixsym{A}.$ + + +\subsection*{Tensor symbols} + +Symbols for tensors are sans-serif bold italic, + +\[ + \tensorsym{\alpha} = \tensorsym{e}\cdot\tensorsym{a} + \quad \Longleftrightarrow \quad + \alpha_{ijl} = e_{ijk}\cdot a_{kl}. +\] + + +The permittivity tensor describes the coupling of electric field and +displacement: \[ +\vec{D}=\epsilon_{0}\tensorsym{\epsilon}_{\mathrm{r}}\vec{E}\] + + +\subsection*{Bold math version} + +The ``bold'' math version is selected with the commands +\verb+\boldmath+ or \verb+\mathversion{bold}+ +\boldmath + + +\begin{eqnarray*} +\mbox{mathnormal} & & \teststring \\ +\mbox{mathit} & & \mathit{\teststring}\\ +\mbox{mathrm} & & \mathrm{\teststring}\\ +\mbox{mathbf} & & \mathbf{\teststring}\\ +\mbox{mathsf} & & \mathsf{\teststring}\\ +\mbox{mathtt} & & \mathtt{\teststring} +\end{eqnarray*} + New alphabets bold-italic, sans-serif-italic, and sans-serif-bold-italic. +\begin{eqnarray*} +\mbox{mathbfit} & & \mathbfit{\teststring}\\ +\mbox{mathsfit} & & \mathsfit{\teststring}\\ +\mbox{mathsfbfit} & & \mathsfbfit{\teststring} +\end{eqnarray*} +% +Do the math alphabets match? + +$ +\mathnormal {a x \alpha \omega} +\mathbfit {a x \alpha \omega} +\mathsfbfit{a x \alpha \omega} +\quad +\mathsfbfit{T C \Theta \Gamma} +\mathbfit {T C \Theta \Gamma} +\mathnormal {T C \Theta \Gamma} +$ + +\subsection*{Vector symbols} + +Alphabetic symbols for vectors are boldface italic, +$\vec{\lambda}=\vec{e}_{1}\cdot\vec{a}$, +while numeric ones (e.g. the zero vector) are bold upright, +$\vec{a} + \vec{0} = \vec{a}$. + + +\subsection*{Matrix symbols} + +Symbols for matrices are boldface italic, too:% +\footnote{However, matrix symbols are usually capital letters whereas vectors +are small ones. Exceptions are physical Quantities like the force +vector $\vec{F}$ or the electrical field $\vec{E}$.% +} +$\matrixsym{\Lambda}=\matrixsym{E}\cdot\matrixsym{A}.$ + + +\subsection*{Tensor symbols} + +Symbols for tensors are sans-serif bold italic, + +\[ + \tensorsym{\alpha} = \tensorsym{e}\cdot\tensorsym{a} + \quad \Longleftrightarrow \quad + \alpha_{ijl} = e_{ijk}\cdot a_{kl}. +\] + +The permittivity tensor describes the coupling of electric field and +displacement: \[ +\vec{D}=\epsilon_{0}\tensorsym{\epsilon}_{\mathrm{r}}\vec{E}\] + +\end{document} diff --git a/macros/latex/contrib/isomath/isomath.html b/macros/latex/contrib/isomath/isomath.html new file mode 100644 index 0000000000..1d31f461d7 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.html @@ -0,0 +1,2585 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> +<meta name="generator" content="Docutils 0.10: http://docutils.sourceforge.net/" /> +<title>isomath</title> +<meta name="author" content="Günter Milde" /> +<meta name="date" content="2012-09-04" /> +<meta name="copyright" content="© 2008, 2012 Günter Milde" /> +<style type="text/css"> + +/* +:Author: David Goodger (goodger@python.org) +:Id: $Id: html4css1.css 7434 2012-05-11 21:06:27Z milde $ +:Copyright: This stylesheet has been placed in the public domain. + +Default cascading style sheet for the HTML output of Docutils. + +See http://docutils.sf.net/docs/howto/html-stylesheets.html for how to +customize this style sheet. +*/ + +/* used to remove borders from tables and images */ +.borderless, table.borderless td, table.borderless th { + border: 0 } + +table.borderless td, table.borderless th { + /* Override padding for "table.docutils td" with "! important". + The right padding separates the table cells. */ + padding: 0 0.5em 0 0 ! important } + +.first { + /* Override more specific margin styles with "! important". */ + margin-top: 0 ! important } + +.last, .with-subtitle { + margin-bottom: 0 ! important } + +.hidden { + display: none } + +a.toc-backref { + text-decoration: none ; + color: black } + +blockquote.epigraph { + margin: 2em 5em ; } + +dl.docutils dd { + margin-bottom: 0.5em } + +object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] { + overflow: hidden; +} + +/* Uncomment (and remove this text!) to get bold-faced definition list terms +dl.docutils dt { + font-weight: bold } +*/ + +div.abstract { + margin: 2em 5em } + +div.abstract p.topic-title { + font-weight: bold ; + text-align: center } + +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + margin: 2em ; + border: medium outset ; + padding: 1em } + +div.admonition p.admonition-title, div.hint p.admonition-title, +div.important p.admonition-title, div.note p.admonition-title, +div.tip p.admonition-title { + font-weight: bold ; + font-family: sans-serif } + +div.attention p.admonition-title, div.caution p.admonition-title, +div.danger p.admonition-title, div.error p.admonition-title, +div.warning p.admonition-title { + color: red ; + font-weight: bold ; + font-family: sans-serif } + +/* Uncomment (and remove this text!) to get reduced vertical space in + compound paragraphs. +div.compound .compound-first, div.compound .compound-middle { + margin-bottom: 0.5em } + +div.compound .compound-last, div.compound .compound-middle { + margin-top: 0.5em } +*/ + +div.dedication { + margin: 2em 5em ; + text-align: center ; + font-style: italic } + +div.dedication p.topic-title { + font-weight: bold ; + font-style: normal } + +div.figure { + margin-left: 2em ; + margin-right: 2em } + +div.footer, div.header { + clear: both; + font-size: smaller } + +div.line-block { + display: block ; + margin-top: 1em ; + margin-bottom: 1em } + +div.line-block div.line-block { + margin-top: 0 ; + margin-bottom: 0 ; + margin-left: 1.5em } + +div.sidebar { + margin: 0 0 0.5em 1em ; + border: medium outset ; + padding: 1em ; + background-color: #ffffee ; + width: 40% ; + float: right ; + clear: right } + +div.sidebar p.rubric { + font-family: sans-serif ; + font-size: medium } + +div.system-messages { + margin: 5em } + +div.system-messages h1 { + color: red } + +div.system-message { + border: medium outset ; + padding: 1em } + +div.system-message p.system-message-title { + color: red ; + font-weight: bold } + +div.topic { + margin: 2em } + +h1.section-subtitle, h2.section-subtitle, h3.section-subtitle, +h4.section-subtitle, h5.section-subtitle, h6.section-subtitle { + margin-top: 0.4em } + +h1.title { + text-align: center } + +h2.subtitle { + text-align: center } + +hr.docutils { + width: 75% } + +img.align-left, .figure.align-left, object.align-left { + clear: left ; + float: left ; + margin-right: 1em } + +img.align-right, .figure.align-right, object.align-right { + clear: right ; + float: right ; + margin-left: 1em } + +img.align-center, .figure.align-center, object.align-center { + display: block; + margin-left: auto; + margin-right: auto; +} + +.align-left { + text-align: left } + +.align-center { + clear: both ; + text-align: center } + +.align-right { + text-align: right } + +/* reset inner alignment in figures */ +div.align-right { + text-align: inherit } + +/* div.align-center * { */ +/* text-align: left } */ + +ol.simple, ul.simple { + margin-bottom: 1em } + +ol.arabic { + list-style: decimal } + +ol.loweralpha { + list-style: lower-alpha } + +ol.upperalpha { + list-style: upper-alpha } + +ol.lowerroman { + list-style: lower-roman } + +ol.upperroman { + list-style: upper-roman } + +p.attribution { + text-align: right ; + margin-left: 50% } + +p.caption { + font-style: italic } + +p.credits { + font-style: italic ; + font-size: smaller } + +p.label { + white-space: nowrap } + +p.rubric { + font-weight: bold ; + font-size: larger ; + color: maroon ; + text-align: center } + +p.sidebar-title { + font-family: sans-serif ; + font-weight: bold ; + font-size: larger } + +p.sidebar-subtitle { + font-family: sans-serif ; + font-weight: bold } + +p.topic-title { + font-weight: bold } + +pre.address { + margin-bottom: 0 ; + margin-top: 0 ; + font: inherit } + +pre.literal-block, pre.doctest-block, pre.math, pre.code { + margin-left: 2em ; + margin-right: 2em } + +pre.code .ln { /* line numbers */ + color: grey; +} + +.code { + background-color: #eeeeee +} + +span.classifier { + font-family: sans-serif ; + font-style: oblique } + +span.classifier-delimiter { + font-family: sans-serif ; + font-weight: bold } + +span.interpreted { + font-family: sans-serif } + +span.option { + white-space: nowrap } + +span.pre { + white-space: pre } + +span.problematic { + color: red } + +span.section-subtitle { + /* font-size relative to parent (h1..h6 element) */ + font-size: 80% } + +table.citation { + border-left: solid 1px gray; + margin-left: 1px } + +table.docinfo { + margin: 2em 4em } + +table.docutils { + margin-top: 0.5em ; + margin-bottom: 0.5em } + +table.footnote { + border-left: solid 1px black; + margin-left: 1px } + +table.docutils td, table.docutils th, +table.docinfo td, table.docinfo th { + padding-left: 0.5em ; + padding-right: 0.5em ; + vertical-align: top } + +table.docutils th.field-name, table.docinfo th.docinfo-name { + font-weight: bold ; + text-align: left ; + white-space: nowrap ; + padding-left: 0 } + +h1 tt.docutils, h2 tt.docutils, h3 tt.docutils, +h4 tt.docutils, h5 tt.docutils, h6 tt.docutils { + font-size: 100% } + +ul.auto-toc { + list-style-type: none } + +</style> +<style type="text/css"> + +/* html4css2.css: Cascading style sheet for Docutils' html4strict writer. */ +/* */ +/* :Author: Günter Milde */ +/* :Copyright: © 2009 Günter Milde. */ +/* Released without warranties or conditions of any kind */ +/* under the terms of the Apache License, Version 2.0 */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* This stylesheet supplements the Docutils standard style 'html4css1.css'. */ +/* It uses CSS 2.1 elements (supported by up-to-date versions of popular */ +/* browsers). */ + +/* General rules */ +/* ============= */ + +body { + padding: 0 5%; + margin: 8px 0; + line-height:1.3; + /* http://ilovetypography.com/2008/02/28/a-guide-to-web-typography/ + recommends "line-spacing that’s at least 140% of your text size" */ + counter-reset: table; + /* counter-reset: figure; */ +} + +/* avoid long lines --> better reading */ +/* OTOH: lines should not be too short because of missing hyphenation, */ +div.document { + max-width: 45em; + margin: auto; +} + +/* separate items except for compact lists */ +dl > dd { + margin-bottom: 1em; +} +.compact li, .compact p, .compact ul, .compact ol +dl.simple > dd, .simple li, .simple p, .simple ul, .simple ol { + margin-top: 0; + margin-bottom: 0; +/* background: magenta; */ +} +dl.simple, dl.compact, dl.simple > dd, dl.compact > dd { + margin-top: 0; + margin-bottom: 0; +/* background: lightgreen; */ +} + +/* space around paragraphs */ +dl > dd p:first-child, td > p { + margin: 0; +} + +/* Sidebar */ +/* ------- */ + +div.sidebar { + margin-right: -5%; +} + +/* Special definition lists */ +/* ======================== */ + +/* bold definition term on the same line as the label */ +dl.field-list > dt, dl.option-list > dt, dl.docinfo > dt, +dl.footnote > dt, dl.citation > dt, dl.description > dt { + clear: left; + float: left; + margin: 0; + padding: 0; + padding-right: 0.5em; + font-weight: bold; +} +/* except for these */ +dl.option-list > dt, dl.footnote > dt { + font-weight: normal; +} + + + +/* Field Lists */ +/* ----------- */ + +/* field names followed by a colon */ +dl.field-list > dt:after, dl.docinfo > dt:after { + content: ":"; +} + +/* Offset for field content (corresponds to the --field-name-limit option) */ +dl.field-list > dd { + margin-left: 9em; /* ca. 14 chars in the test examples */ + padding-left: 0.5em; +} + +/* start field-body on a new line after long field names */ +dl.field-list > dd p { + width: 100%; +/* display: inline-block; */ +/* background: yellow; */ +} + +dl.field-list > dd > p:first-child, +/* dl.field-list > dd > ol:first-child, */ +/* dl.field-list > dd > ul:first-child, */ +dl.field-list > dd > dl:first-child { + display: inline-block; +} + +/* field-list variants:: */ + +/* example for custom field-name width */ +dl.field-list.narrow > dd { + margin-left: 5em; +} + +/* start field-body on same line after long field names */ +dl.field-list.run-in > dd p { + display: block; +} + +/* wrap or truncate long field names */ +dl.field-list.fix-labelwidth > dt { + width: 8em; /* set to dl.field-list > dd margin-left - padding-left */ + overflow: hidden; +} +dl.field-list.fix-labelwidth > dd:after { + /* a "stopper" to prevent next dd floating up too far */ + content: ''; + display: block; + clear: left; +} + +/* docinfo */ + +dl.docinfo > dd { + margin-left: 8em; +/* margin-bottom: 0.5em; */ +} + + +/* option list */ + +dl.option-list { + margin-left: 1em; + padding-left: 0; +} + +dl.option-list > dd { + margin-left: 8em; + /* margin-bottom: 0.5em; */ +} + +/* start description on a new line after long options */ +dl.option-list > dd p { + width: 100%; + display: inline-block; +} + +/* footnotes */ + +a.footnote-reference, a.fn-backref { + text-decoration: inherit; /* do not underline footnote links */ +} + +dl.footnote { + /* line on the left */ + padding-left: 1ex; + border-left: solid; + border-left-width: thin; + /* border-color: black; */ +} + +/* paragraph on same line as backrefs */ +dd > em { +/* background: green; */ + float: left; + margin-right: 1ex +} + + +/* +Ordered List (Enumeration) +-------------------------- + +Use counters to replace the deprecated start attribute. Make sure the +resulting list resembles the list-style 'outside' with a hanging indent. +*/ + +/* New ordered list: reset counter, suppress the default label */ +ol, ol.arabic, ol.loweralpha, ol.upperalpha, +ol.lowerroman, ol.upperroman { + counter-reset: item; + list-style: none +} + +/* Set the negative indent of the list label as feature of the list item */ +ol > li { + text-indent: -40px; /* Mozillas default indent */ +} +/* reset for child elements */ +ol > li > * { + text-indent: 0px; + text-indent: 0; + margin-top: 0; + /* background: lightgreen; */ +} + +/* Label */ +ol > li:before { + /* increment and typeset counter(s), */ + counter-increment: item; + content: counter(item) "."; + /* display next to the content (aligned top-right), */ + display: inline-block; + text-align: right; + vertical-align: top; + /* sum must match ol>li {text-indent:} (40px is Mozillas default) */ + width: 35px; + padding-right: 5px; +/* background: yellow; */ +} + +/* The list item's first line starts next to the label, without indent */ +ol > li > p:first-child, +ol > li > ol:first-child, +ol > li > ul:first-child, +ol > li > dl:first-child { + display: inline-block; + /* background: lightblue; */ +} + +/* default separator variants */ +ol.loweralpha > li:before { + content: counter(item, lower-alpha) ")"; +} +ol.upperalpha > li:before { + content: counter(item, upper-alpha) "."; +} +ol.lowerroman > li:before { + content: "(" counter(item, lower-roman) ")"; +} +ol.upperroman > li:before { + content: counter(item, upper-roman) ")"; +} +/* nested counters (1, 1.1, 1.1.1, etc) */ +/* nested enumerated lists "inherit" the class attribute, other lists not */ +ol.nested > li:before, ol.nested ol > li:before { + content: counters(item, ".") " "; +} + +/* lists nested in definition list */ + +dd > ul, dd > ol { + padding-left: 0pt; +} + +/* TODO: prefix, suffix? */ + +/* smaller font for super- and subscripts */ +/* sub, sup {font-size: 70%;} */ /* Mozilla default is `smaller` */ + + +/* Tables */ +/* ====== */ + +/* margins and borders for "normal" tables */ +table { +/* background: magenta; */ + margin-top: 1em ; + margin-bottom: 1em; +/* border-style: outset; */ + border-style: solid; + border-color: silver; + border-width: thin; + border-collapse: collapse; +} +blockquote > table { + margin-top: 0em ; + margin-bottom: 0em; +} + +td, th { + border-style: solid; + border-width: thin; + border-color: silver; + /* text-align: left; */ + padding: 0 1ex; +} + +td > p:first-child, th > p:first-child { + margin-top: 0; +} +td > p, th > p { + margin-bottom: 0; +} + +/* no borders for "borderless" tables */ +table.borderless, table.borderless * { + border-style: none; +} + +/* "booktabs" style (no vertical lines) */ +table.booktabs { + border: 0; + border-top: 2px solid; + border-bottom: 2px solid; +} + +table.booktabs * { + border: 0; +} +table.booktabs th { + border-bottom: thin solid; +} + +table > caption { + text-align: left; + margin-bottom: 0.25em +/* padding: 2em 0 1em 0; */ +} + +/* numbered tables*/ +table.numbered > caption:before { + counter-increment: table; /* defined/re-set in body */ + content: "Table " counter(table) ": "; + font-weight: bold; +} + + +/* literal text + ------------ +*/ +/* whitespace and wrapping in inline literals */ +/* possible values: normal, nowrap, pre, pre-wrap, pre-line */ +tt.literal { + white-space: pre-wrap; +} + +/* /* compensate for initial line-break (which is literal with XHTML 1.1) */ */ +/* pre.literal-block, pre.doctest-block { */ +/* margin-top: 0em ; */ +/* } */ + +/* Table of Contents */ + +/* don't indent like a topic */ +div.topic.contents { + margin: 0; +} +/* div.topic.contents ul { */ +/* list-style: none; */ +/* } */ + +div.topic.contents a { + text-decoration: none; /* no underline for links */ +} + +/* section numbers */ + +span.sectnum { + padding-right: 1ex; +} + +/* admonitions */ + +/* no padding for top and bottom */ +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + padding: 0px 1em } + +</style> +<style type="text/css"> + +/* Stylesheet for isomath documentation +:Copyright: 2008 G. Milde + This stylesheet is released under the GPL v. 2 +*/ + +dl.docutils dt { font-weight: bold; } + +/* docinfo */ + +dl.docinfo > dt { display: none; } +dl.docinfo > dd { + margin-left: 0; + padding: 0 5%; +} +dl.docinfo > dt.author + dd { + font-size: larger; + text-align: center; + padding-bottom: 1em; +} +dt.date { + display: none; +} +dt.date + dd { + font-weight: bold; + text-align: center; + padding-bottom: 1em; +} + +div.abstract { + padding: 0 5%; +} + +a.reference.internal { + text-decoration: none; + color: darkblue; +} + +a.reference.external { + text-decoration: underline; +} + +/* a.reference.external:after { */ +/* content: "⎘"; */ +/* font-size: x-small; */ +/* vertical-align: super; */ +/* } */ + +dl.footnote > dd { + margin-left: 1.2em; +} +dl.footnote > dt { + font-size: small; + vertical-align: super; +} + +a.footnote-reference > sup { + font-size: small; + vertical-align: super; + } + +td, th { + padding-bottom: 0.1ex; + padding-top: 0.1ex; +} + +/* let borderless overreide booktab */ +.booktabs.borderless, +table.booktabs.borderless td, table.booktabs.borderless th { + border: 0; + margin-left: 2em; + } + +table.docutils td, table.docutils th, + vertical-align: bottom; } + +</style> +</head> +<body> +<div class="document" id="isomath"> +<h1 class="title">isomath</h1> +<h2 class="subtitle" id="mathematical-style-for-science-and-technology">Mathematical style for science and technology</h2> + +<dl class="docinfo simple"> +<dt class="author">Author</dt> +<dd class="author">Günter Milde</dd> +<dt class="date">Date</dt> +<dd class="date">2012-09-04</dd> +<dt class="copyright">Copyright</dt> +<dd class="copyright">© 2008, 2012 Günter Milde</dd> +<dt>Licence</dt> +<dd><p>This work may be distributed and/or modified under the +conditions of the <a class="reference external" href="http://www.latex-project.org/lppl.txt">LaTeX Project Public License</a>, either +version 1.3 of this license or (at your option) any later version.</p> +</dd> +</dl> +<div class="abstract topic"> +<p class="topic-title first">Abstract</p> +<p>The <cite>isomath</cite> package provides tools for a mathematical style +that conforms to the International Standard ISO 80000-2 and is +common in science and technology. It changes the default shape of +capital Greek letters to italic, sets up bold italic and +sans-serif bold italic math alphabets with Latin and Greek +characters, and defines macros for markup of vector, matrix and +tensor symbols.</p> +</div> +<!-- -*- rst-mode -*- --> +<div class="contents topic" id="contents"> +<p class="topic-title first">Contents</p> +<ul class="auto-toc simple"> +<li><p><a class="reference internal" href="#features" id="id36"><span class="sectnum">1</span> Features</a></p> +<ul class="auto-toc"> +<li><p><a class="reference internal" href="#iso-math-style" id="id37"><span class="sectnum">1.1</span> “ISO” math style</a></p></li> +<li><p><a class="reference internal" href="#new-math-alphabets" id="id38"><span class="sectnum">1.2</span> New math alphabets</a></p></li> +<li><p><a class="reference internal" href="#semantic-markup" id="id39"><span class="sectnum">1.3</span> Semantic markup</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#usage" id="id40"><span class="sectnum">2</span> Usage</a></p> +<ul class="auto-toc"> +<li><p><a class="reference internal" href="#options" id="id41"><span class="sectnum">2.1</span> Options</a></p></li> +<li><p><a class="reference internal" href="#examples" id="id42"><span class="sectnum">2.2</span> Examples</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#related-packages" id="id43"><span class="sectnum">3</span> Related packages</a></p> +<ul class="auto-toc"> +<li><p><a class="reference internal" href="#requirements" id="id44"><span class="sectnum">3.1</span> Requirements</a></p></li> +<li><p><a class="reference internal" href="#recommendations" id="id45"><span class="sectnum">3.2</span> Recommendations</a></p></li> +<li><p><a class="reference internal" href="#alternatives" id="id46"><span class="sectnum">3.3</span> Alternatives</a></p></li> +<li><p><a class="reference internal" href="#conflicts" id="id47"><span class="sectnum">3.4</span> Conflicts</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#background" id="id48"><span class="sectnum">4</span> Background</a></p> +<ul class="auto-toc"> +<li><p><a class="reference internal" href="#math-font-selection" id="id49"><span class="sectnum">4.1</span> Math font selection</a></p></li> +<li><p><a class="reference internal" href="#oml-font-encoding" id="id50"><span class="sectnum">4.2</span> OML font encoding</a></p></li> +<li><p><a class="reference internal" href="#unicode-mathematical-typesetting" id="id51"><span class="sectnum">4.3</span> Unicode mathematical typesetting</a></p></li> +<li><p><a class="reference internal" href="#conclusions-and-outlook" id="id52"><span class="sectnum">4.4</span> Conclusions and outlook</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#references" id="id53"><span class="sectnum">5</span> References</a></p></li> +</ul> +</div> +<div class="section" id="features"> +<h1><a class="toc-backref" href="#id36"><span class="sectnum">1</span> Features</a></h1> +<!-- How do you write the stress tensor ``$\sigma$`` in a +*sans-serif bold italic* typeface, as recommended by [typefaces]_? --> +<p>In their style guides, e. g. <a class="citation-reference" href="#typefaces" id="id1">[typefaces]</a>, <a class="citation-reference" href="#checklist" id="id2">[checklist]</a>, <a class="citation-reference" href="#si" id="id3">[SI]</a>, +<a class="citation-reference" href="#fonts-for-symbols" id="id4">[fonts_for_symbols]</a>, <a class="citation-reference" href="#red-book" id="id5">[Red-Book]</a>, <a class="citation-reference" href="#green-book" id="id6">[Green-Book]</a>, many international +scientific organisations recommend layout rules for mathematics in line with +the International Standard <a class="citation-reference" href="#iso-80000-2" id="id7">[ISO-80000-2]</a>.</p> +<div class="admonition-international-standard-layout-rules admonition"> +<p class="admonition-title">International standard layout rules</p> +<ul class="simple"> +<li><p>The overall rule is that symbols representing physical quantities +(or variables) are italic, but symbols representing units, or +labels, are roman.</p></li> +<li><p>Symbols for vectors and matrices are bold italic, symbols for tensors +are sans-serif bold italic.</p></li> +<li><p>The above rules apply equally to letter symbols from the Greek and the +Latin alphabet.</p></li> +</ul> +</div> +<!-- The recommendations in this standard are intended mainly for use in the +natural sciences and technology, but also apply to other areas where +mathematics is used. --> +<p>TeX's default mathematical style deviates from this rules in several +points:</p> +<ul class="simple"> +<li><p>Capital Greek letters default to upright shape,</p></li> +<li><p>small Greek letters are excluded from font changes with the <a class="reference internal" href="#math-alphabet">math +alphabet</a> commands, and</p></li> +<li><p>the <tt class="literal">\vec</tt> command produces an arrow accent.</p></li> +</ul> +<p>The <cite>isomath</cite> package implements an <a class="reference internal" href="#iso-math-style">“ISO” math style</a>, provides <a class="reference internal" href="#new-math-alphabets">new math +alphabets</a> with <em>bold italic</em> and <em>sans-serif bold italic</em> type and macros +for <a class="reference internal" href="#semantic-markup">semantic markup</a> of vector, matrix and tensor symbols. It can be +combined with most packages for mathematical typesetting (see +<a class="reference external" href="isomath-test.tex">isomath-test.tex</a> and the sections on <a class="reference internal" href="#alternatives">alternatives</a> and <a class="reference internal" href="#conflicts">conflicts</a>).</p> +<div class="section" id="iso-math-style"> +<h2><a class="toc-backref" href="#id37"><span class="sectnum">1.1</span> “ISO” math style</a></h2> +<p>Isomath builds on the package <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a> by Walter Schmidt to change the +default mathematics layout to the “ISO” <a class="reference internal" href="#math-style">math style</a>:</p> +<ul class="simple"> +<li><p>Capital Greek letters are typeset in italic shape by default.</p></li> +<li><p>Both, Greek and Latin letters change shape if a different +<a class="reference internal" href="#math-alphabet">math alphabet</a> is used.</p></li> +</ul> +<div class="caution"> +<p class="admonition-title">Caution!</p> +<p>Be careful with Greek letters in the argument of <tt class="literal">\mathit</tt>, <tt class="literal">\mathrm</tt>, +<tt class="literal">\mathbf</tt>, <tt class="literal">\mathsf</tt>, and <tt class="literal">\mathtt</tt>. By default, these <a class="reference internal" href="#math-alphabets">math +alphabets</a> use text fonts. Fonts in OT1 text font encoding have capital +(but not small) Greek letters at the expected places, T1 encoded text fonts +have no Greek letters at all.</p> +<p>See the <a class="reference internal" href="#examples">examples</a> section on <a class="reference internal" href="#how-to-get-upright-small-greek-letters">how to get upright small Greek letters</a> in +mathematical context.</p> +</div> +</div> +<div class="section" id="new-math-alphabets"> +<h2><a class="toc-backref" href="#id38"><span class="sectnum">1.2</span> New math alphabets</a></h2> +<p><cite>Isomath</cite> defines the new <a class="reference internal" href="#math-alphabets">math alphabets</a>:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="21%" /> +<col width="31%" /> +<col width="47%" /> +</colgroup> +<tbody> +<tr><td><p><tt class="literal">\mathbfit</tt></p></td> +<td><p>boldface italic</p></td> +<td><p>vector and matrix symbols</p></td> +</tr> +<tr><td><p><tt class="literal">\mathsfit</tt></p></td> +<td><p>sans-serif italic</p></td> +<td><p>optional (see OMLmath*_ options)</p></td> +</tr> +<tr><td><p><tt class="literal">\mathsfbfit</tt></p></td> +<td><p>sans-serif bold italic</p></td> +<td><p>tensor symbols</p></td> +</tr> +</tbody> +</table> +<p>For compatibility with earlier versions and <a class="reference internal" href="#related-packages">related packages</a>, the +new math alphabets are also available under the aliases +<tt class="literal">\mathbold</tt>, <tt class="literal">\mathsans</tt>, and <tt class="literal">\mathboldsans</tt>.</p> +<p>The <a class="reference internal" href="#rmdefault">rmdefault</a> and <a class="reference internal" href="#sfdefault">sfdefault</a> <a class="reference internal" href="#options">options</a> set the font family used for +these alphabets.</p> +<div class="caution"> +<p class="admonition-title">Caution!</p> +<p>Using the new math alphabets for numbers can result in upright old-style +numbers instead of italic ones, because some italic math fonts (e. g., +<tt class="literal">cmr</tt>, <tt class="literal">cmbr</tt>) contain old-style in place of italic digits.</p> +</div> +</div> +<div class="section" id="semantic-markup"> +<h2><a class="toc-backref" href="#id39"><span class="sectnum">1.3</span> Semantic markup</a></h2> +<p>The following commands set the argument in an ISO-conforming <a class="reference internal" href="#math-alphabet">math alphabet</a>:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="39%" /> +<col width="61%" /> +</colgroup> +<tbody> +<tr><td><p><tt class="literal">\vectorsym, \matrixsym</tt></p></td> +<td><p>bold italic for Greek and Latin letters, +bold upright for numbers</p></td> +</tr> +<tr><td><p><tt class="literal">\tensorsym</tt></p></td> +<td><p>sans-serif bold italic</p></td> +</tr> +</tbody> +</table> +</div> +</div> +<div class="section" id="usage"> +<h1><a class="toc-backref" href="#id40"><span class="sectnum">2</span> Usage</a></h1> +<p>Make sure that LaTeX can find <tt class="literal">isomath.sty</tt> and load it with:</p> +<pre class="literal-block">\usepackage{isomath} +</pre> +<p>Optionally redefine the standard vector macro <tt class="literal">\vec</tt>:</p> +<pre class="literal-block">\renewcommand{\vec}{\vectorsym} +</pre> +<p>(see also <a class="reference internal" href="#options">Options</a>, <a class="reference internal" href="#examples">Examples</a>, and <a class="reference external" href="isomath-test.tex">isomath-test.tex</a>).</p> +<div class="section" id="options"> +<h2><a class="toc-backref" href="#id41"><span class="sectnum">2.1</span> Options</a></h2> +<div class="section" id="rmdefault"> +<h3><span class="sectnum">2.1.1</span> rmdefault</h3> +<p>Family for serif math fonts (<tt class="literal">\mathrm</tt>, <tt class="literal">\mathbf</tt>, <tt class="literal">\mathit</tt>, +<tt class="literal">\mathbfit</tt>). The default is to use the corresponding text font +family (the value of <tt class="literal">\rmdefault</tt>). The font must be available in +<a class="reference internal" href="#oml-font-encoding">OML font encoding</a> (cf. <a class="reference internal" href="#table-3">Table 3</a>).</p> +</div> +<div class="section" id="sfdefault"> +<h3><span class="sectnum">2.1.2</span> sfdefault</h3> +<p>Family for sans-serif math fonts. The default is <tt class="literal">cmbr</tt> because most +sans-serif fonts define the Computer Roman font <cite>cmm</cite> as OML substitution +(see <a class="reference internal" href="#table-4">Table 4</a>).</p> +<p>There are only few sans serif fonts in <a class="reference internal" href="#oml-font-encoding">OML font encoding</a>:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="14%" /> +<col width="15%" /> +<col width="72%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>Name</p></th> +<th class="head"><p>Package</p></th> +<th class="head"><p>Comment</p></th> +</tr> +</thead> +<tbody> +<tr><td><p><tt class="literal">cmbr</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/cmbright.html">cmbright</a></p></td> +<td><p><cite>Computer Modern Bright</cite>, bitmap, slightly lighter +than cmss (Type 1 fonts with <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/hfbright.html">hfbright</a>)</p></td> +</tr> +<tr><td><p><tt class="literal">fav</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/arev.html">arev</a></p></td> +<td><p><cite>Arev</cite> (<cite>Vera Sans</cite>), large x-height</p></td> +</tr> +<tr><td><p><tt class="literal">hvm</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/hvmath.html">hvmath</a></p></td> +<td><p><cite>Helvetica Math</cite>, commercial, free bitmap version</p></td> +</tr> +<tr><td><p><tt class="literal">iwona</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/iwona.html">iwona</a></p></td> +<td><p><cite>Iwona</cite>, humanistic sans serif, +some shapes very similar to roman</p></td> +</tr> +<tr><td><p><tt class="literal">jkpss</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a></p></td> +<td><p><cite>Kepler Sans</cite>, quite light</p></td> +</tr> +<tr><td><p><tt class="literal">llcmss</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/lxfonts.html">lxfonts</a></p></td> +<td><p><cite>LX Fonts</cite>, “slide fonts”, very wide, large x-height</p></td> +</tr> +</tbody> +</table> +</div> +<div class="section" id="scaled"> +<h3><span class="sectnum">2.1.3</span> scaled</h3> +<p>To improve the chances of finding a matching sans serif math font, the +fonts <tt class="literal">fav</tt>, <tt class="literal">iwona</tt>, <tt class="literal">jkpss</tt>, and <tt class="literal">llcmss</tt> can be scaled with the +<tt class="literal">scaled</tt> option (cf. <a class="reference internal" href="#examples">Examples</a>). For other fonts, the option is ignored.</p> +</div> +<div class="section" id="reusemathalphabets"> +<h3><span class="sectnum">2.1.4</span> reuseMathAlphabets</h3> +<p>The definition of new math alphabets can lead to a “<a class="reference internal" href="#too-many-math-alphabets-used-in-version-normal">too many math +alphabets used in version normal</a>” error. As a workaround, this +option tells <cite>isomath</cite> to re-use the existing <tt class="literal">\mathbf</tt> and +<tt class="literal">\mathsf</tt> alphabets for italic bold and sans-serif bold.<a class="footnote-reference" href="#id9" id="id8"><sup>1</sup></a></p> +<dl class="footnote"><dt class="label"><a class="fn-backref" href="#id8">1</a></dt> +<dd id="id9"> +<p class="first last">To access the upright shapes, the corresponding <tt class="literal">\textbf</tt> and +<tt class="literal">\textsf</tt> commands might be used. Watch for side-effects, as these +commands switch to text mode so that the font settings in the embedding +text apply.</p> +</dd> +</dl> +</div> +<div class="section" id="omlmathrm-omlmathbf-omlmathsf-omlmathsfit-omlmathtt"> +<span id="omlmath"></span><h3><span class="sectnum">2.1.5</span> OMLmathrm, OMLmathbf, OMLmathsf, OMLmathsfit, OMLmathtt</h3> +<p>The <tt class="literal">OMLmath*</tt> options bind the corresponding <tt class="literal">\math*</tt> command to an +OML-encoded font.</p> +<p>The <tt class="literal">\mathsfit</tt> alphabet is not required for ISO conforming mathematical +layout and therefore only defined if the <tt class="literal">OMLmathsfit</tt> argument is used.</p> +<p>The predefined <a class="reference internal" href="#math-alphabets">math alphabets</a> <tt class="literal">\mathrm</tt>, <tt class="literal">\mathbf</tt>, and <tt class="literal">\mathtt</tt> +use OT1 encoded text fonts with ligatures and accents in place of the small +Greek letters. The <tt class="literal">OMLmath*</tt> options enable the use of small Greek +letters in <a class="reference internal" href="#math-alphabet">math alphabet</a> commands, e. g. <tt class="literal"><span class="pre">\mathrm{\pi}</span></tt>, if the +corresponding font is available in <a class="reference internal" href="#oml-font-encoding">OML font encoding</a>. <a class="reference internal" href="#table-3">Table 3</a> lists +font families supporting the OML encoding.</p> +<div class="caution"> +<p class="admonition-title">Caution!</p> +<p>If no matching OML encoded font is found, LaTeX's substitute mechanism +selects a font with different font attributes (for all letters, not only +Greek). Currently, only the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a> package provides upright fonts in +OML encoding. Many font packages define an <em>italic</em> font as OML substitute +for roman fonts.</p> +<p>With some packages, these options can result in a “<a class="reference internal" href="#too-many-math-alphabets-used-in-version-normal">too many math +alphabets used in version normal</a>” error.</p> +</div> +</div> +</div> +<div class="section" id="examples"> +<h2><a class="toc-backref" href="#id42"><span class="sectnum">2.2</span> Examples</a></h2> +<ul> +<li><p>Use scaled <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/arev.html">arev</a> fonts for the sans serif math alphabets +(adapt the scaling factor to your needs):</p> +<pre class="literal-block">\usepackage[sfdefault=fav,scaled=0.875]{isomath} +</pre> +</li> +<li><p>Define the <tt class="literal">\mathsfit</tt> sans-serif italic math alphabet:</p> +<pre class="literal-block">\usepackage[OMLmathsfit]{isomath} +</pre> +</li> +<li><p>The <tt class="literal">\mathbfit</tt> and <tt class="literal">\mathsfbfit</tt> alphabets do not have a different +weight in the <tt class="literal">bold</tt> <a class="reference internal" href="#math-version">math version</a> because the number of LaTeX math +fonts providing <cite>extrabold</cite> or <cite>ultrabold</cite> series is negligible.</p> +<p>As a workaround, use the heavier <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/arev.html">arev</a> font, scaled to 0,875, in the +bold version of <tt class="literal">\mathsfbfit</tt>:</p> +<pre class="literal-block">\usepackage{isomath} +\DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [0.875] zavmbi7m}{} +\SetMathAlphabet{\mathsfbfit}{bold}{OML}{fav}{bx}{it} +</pre> +</li> +</ul> +<p>See also the <a class="reference external" href="isomath-test.tex">isomath-test.tex</a> test document.</p> +<div class="section" id="how-to-get-upright-small-greek-letters"> +<h3><span class="sectnum">2.2.1</span> How to get upright small Greek letters</h3> +<p>Of the following methods, only the first requires <cite>isomath</cite>:</p> +<ol class="loweralpha"> +<li><p>Use <cite>isomath</cite> and the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a> package:</p> +<pre class="literal-block">\usepackage[utopia]{mathdesign} +\usepackage[OMLmathrm,OMLmathbf]{isomath} +</pre> +<p>Now, e. g., <tt class="literal"><span class="pre">\mathrm{\pi}</span></tt> and <tt class="literal"><span class="pre">\mathbf{\pi}</span></tt> work as +expected.</p> +</li> +<li><p>To get upright small Greek letters without affecting other fonts, +set the math alphabet manually to one of the three <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a> +fonts, e. g.:</p> +<pre class="literal-block">\SetMathAlphabet{\mathbf}{normal}{OML}{mdput}{b}{n} +</pre> +<p>(check if the letter shapes match with the rest of the document).</p> +</li> +<li><p>Use a package that provides macros for upright Greek letters +in math mode:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="26%" /> +<col width="74%" /> +</colgroup> +<tbody> +<tr><td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fourier.html">fourier</a></p></td> +<td><p><tt class="literal">\otheralpha ... \otherOmega</tt></p></td> +</tr> +<tr><td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a></p></td> +<td><p><tt class="literal">\alphaup ... \Omegaup</tt></p></td> +</tr> +<tr><td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a></p></td> +<td><p><tt class="literal">\alphaup ... \Omegaup</tt></p></td> +</tr> +<tr><td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/upgreek.html">upgreek</a></p></td> +<td><p><tt class="literal">\upalpha ... \upOmega</tt></p></td> +</tr> +</tbody> +</table> +</li> +<li><p>Use an upright text character (requires a matching LGR-encoded +Greek text font). The following lines redefine <tt class="literal">\pi</tt> to set +the mathematical constant pi upright:</p> +<pre class="literal-block">\usepackage[LGR,T1]{fontenc} +\usepackage[greek,british]{babel} +\usepackage{amsmath} +\let\mathpi\pi +\renewcommand{\pi}{\text{\textrm{\greektext p }}} +</pre> +</li> +<li><p>Use the text character with the <cite>alphabeta</cite> package from the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/lgrx.html">lgrx</a> +bundle:</p> +<pre class="literal-block">\usepackage{amsmath} +\usepackage{alphabeta} +</pre> +<p>and in the body</p> +<pre class="literal-block">$ u = 2 \text{\pi} r $ +</pre> +</li> +</ol> +</div> +</div> +</div> +<div class="section" id="related-packages"> +<h1><a class="toc-backref" href="#id43"><span class="sectnum">3</span> Related packages</a></h1> +<div class="section" id="requirements"> +<h2><a class="toc-backref" href="#id44"><span class="sectnum">3.1</span> Requirements</a></h2> +<dl class="docutils"> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a></dt> +<dd><p>by Walter Schmidt defines Greek letters as alphabetic symbols.</p> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html">kvoptions</a></dt> +<dd><p>by Heiko Oberdiek facilitates the setup of package options +and provides a key=value interface (based on <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/keyval.html">keyval</a>).</p> +</dd> +</dl> +</div> +<div class="section" id="recommendations"> +<h2><a class="toc-backref" href="#id45"><span class="sectnum">3.2</span> Recommendations</a></h2> +<dl class="docutils"> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/cmbright.html">cmbright</a></dt> +<dd><p>by Walter Schmidt provides sans serif and sans-serif bold fonts +for the <tt class="literal">\mathsfit</tt> and <tt class="literal">\mathsfbfit</tt> alphabets that match +with Computer Modern and derivatives. Free Type 1 versions of the +fonts are provided by <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/hfbright.html">hfbright</a>.</p> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/arev.html">arev</a></dt> +<dd><p>by Stephen Hartke provides the not-so-light <cite>Arev</cite> sans serif font +with letters that are clearly distinguishable from the roman or +italic counterparts (important if used to distinguish vectors and +tensors).</p> +<p><cite>Arev</cite> has a large x-height. For many fonts, either small or capital +letters will not match in size.</p> +</dd> +</dl> +</div> +<div class="section" id="alternatives"> +<h2><a class="toc-backref" href="#id46"><span class="sectnum">3.3</span> Alternatives</a></h2> +<p>The TUGboat article by Claudio Beccari <a class="citation-reference" href="#becc97" id="id10">[becc97]</a> discusses tricks and +commands for physicists and engineers in order to satisfy the international +regulations and to distinguish similar symbols with different meanings.</p> +<p>See <a class="reference internal" href="#table-2">Table 2</a> for other packages that implement the “ISO” <a class="reference internal" href="#math-style">math style</a> and +<a class="reference internal" href="#table-6">Table 6</a> for packages that provide bold italic math fonts.</p> +<dl class="docutils"> +<dt><a class="reference internal" href="#in-line-math-versions">“In-line math versions”</a></dt> +<dd><p>can be used as ISO-conforming replacement for <tt class="literal">\vec</tt>:</p> +<ul class="simple"> +<li><p><tt class="literal">\bm</tt> from the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bm.html">bm</a> package. Combining <cite>bm</cite> and <cite>isomath</cite> may +lead to the <a class="reference internal" href="#too-many-math-alphabets-used-in-version-normal">too many math alphabets used in version normal</a> error.</p></li> +<li><p><tt class="literal">\boldsymbol</tt> from <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsbsy.html">amsbsy</a> (part of <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsmath.html">amsmath</a>, the +near-indispensable adjunct to serious mathematical typesetting in +LaTeX),</p></li> +</ul> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsmath.html">amsmath</a></dt> +<dd><p>provides the command <tt class="literal">\text</tt>, that can be used to get, e. g., upright or +sans-serif bold italic Greek symbols from a text font into a formula (see +<a class="reference internal" href="#how-to-get-upright-small-greek-letters">How to get upright small Greek letters</a>).</p> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></dt> +<dd><p>for XeTeX and LuaTeX allows mathematical typesetting using OpenType +math fonts. It supports the “ISO” <a class="reference internal" href="#math-style">math style</a> and all mathematical +characters in the Unicode standard.</p> +<p><cite>unicode-math</cite> cannot be used together with <cite>isomath</cite>. It can, however, +replace all of isomath's functionality. See the discussion of <a class="reference internal" href="#the-unicode-math-package">the +unicode-math package</a> below.</p> +</dd> +</dl> +</div> +<div class="section" id="conflicts"> +<h2><a class="toc-backref" href="#id47"><span class="sectnum">3.4</span> Conflicts</a></h2> +<dl class="docutils"> +<dt>“<span class="target" id="too-many-math-alphabets-used-in-version-normal">too many math alphabets used in version normal</span>”</dt> +<dd><p>This error occurs if the combination of packages tries to load more +than 16 fonts into the <tt class="literal">normal</tt> <a class="reference internal" href="#math-version">math version</a>.</p> +<p><cite>Isomath</cite> can reduce the number of math alphabet definitions with the +<a class="reference internal" href="#reusemathalphabets">reuseMathAlphabets</a> option (see there for side-effects).</p> +<p>Examples for problematic combinations:</p> +<ul class="simple"> +<li><p>The <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/pxfonts.html">pxfonts</a>, and <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/txfonts.html">txfonts</a> packages define many +additional math alphabets (<cite>kpfonts</cite> works with <cite>isomath</cite>, if +it is loaded with <tt class="literal"><span class="pre">\usepackage[nomathscript]{kpfonts}</span></tt>).</p></li> +<li><p>The <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bm.html">bm</a> package normally allocates several symbol fonts for bold +and heavy fonts. Their number can be customised by defining +<tt class="literal">\bmmax</tt> and <tt class="literal">\hmmax</tt> before loading the package.</p></li> +</ul> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fourier.html">fourier</a></dt> +<dd><p>provides upright and italic Greek letters, but uses non-standard +math font encodings. It cannot be used with <cite>isomath</cite>.</p> +<p>However, it is possible to use the non-alphanumeric symbols from +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fourier.html">fourier</a> together with math alphabets from another package, e.g +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a>:</p> +<pre class="literal-block">\usepackage{fourier} +\usepackage[OMLmathbf,rmdefault=mdput, + sfdefault=arev,scaled=0.85]{isomath} +</pre> +</dd> +<dt><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/sansmath.html">sansmath</a></dt> +<dd><p>defines a <cite>sans</cite> <a class="reference internal" href="#math-version">math version</a> using <strong>text</strong> fonts in OT1 or T1 font +encoding. As fixmath/isomath expect math fonts in <a class="reference internal" href="#oml-font-encoding">OML font encoding</a>, +Greek letters will not work inside the sans math version defined by +sansmath.</p> +</dd> +</dl> +</div> +</div> +<div class="section" id="background"> +<h1><a class="toc-backref" href="#id48"><span class="sectnum">4</span> Background</a></h1> +<p>This section discusses LaTeX <a class="reference internal" href="#math-font-selection">math font selection</a>, the <a class="reference internal" href="#oml-font-encoding">OML font +encoding</a>, and the relation of LaTeX and <a class="reference internal" href="#unicode-mathematical-typesetting">Unicode mathematical +typesetting</a>.</p> +<div class="section" id="math-font-selection"> +<h2><a class="toc-backref" href="#id49"><span class="sectnum">4.1</span> Math font selection</a></h2> +<p>There are three complementary methods to set font attributes in LaTeX +math mode: <cite>LaTeX 2e font selection</cite> <a class="citation-reference" href="#fntguide" id="id11">[fntguide]</a> describes <a class="reference internal" href="#math-alphabets">math +alphabets</a> and <a class="reference internal" href="#math-versions">math versions</a>, several extension packages +provide alternative <a class="reference internal" href="#math-styles">math styles</a>.</p> +<div class="section" id="math-alphabets"> +<span id="math-alphabet"></span><h3><span class="sectnum">4.1.1</span> Math alphabets</h3> +<p>TeX's <em>math alphabets</em> correspond to the <a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric +symbols</a> block in Unicode. Both are “to be used for mathematical +variables where style variations are important semantically”. +The font guide <a class="citation-reference" href="#fntguide" id="id12">[fntguide]</a> defines in +section 3:</p> +<blockquote> +<p>Some math fonts are selected explicitly by one-argument commands +such as <tt class="literal">\mathsf{max}</tt> or <tt class="literal">\mathbf{vec}</tt>; such fonts are called +<em>math alphabets</em>.</p> +<p>Math fonts [...] have the same five attributes as text fonts: +encoding, family, series, shape and size. However, there are no +commands that allow the attributes to be individually changed. +Instead, the conversion from math fonts to these five attributes is +controlled by the <a class="reference internal" href="#math-version">math version</a>.</p> +<p>The <span class="target" id="predefined-math-alphabets">predefined math alphabets</span> are:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="43%" /> +<col width="58%" /> +</colgroup> +<tbody> +<tr><td><p><tt class="literal">\mathnormal</tt></p></td> +<td><p>default<a class="footnote-reference" href="#mathnormal" id="id13"><sup>2</sup></a></p></td> +</tr> +<tr><td><p><tt class="literal">\mathrm</tt></p></td> +<td><p>roman<a class="footnote-reference" href="#roman" id="id14"><sup>3</sup></a></p></td> +</tr> +<tr><td><p><tt class="literal">\mathbf</tt></p></td> +<td><p>bold roman</p></td> +</tr> +<tr><td><p><tt class="literal">\mathsf</tt></p></td> +<td><p>sans serif</p></td> +</tr> +<tr><td><p><tt class="literal">\mathit</tt></p></td> +<td><p>text italic</p></td> +</tr> +<tr><td><p><tt class="literal">\mathtt</tt></p></td> +<td><p>typewriter</p></td> +</tr> +<tr><td><p><tt class="literal">\mathcal</tt></p></td> +<td><p>calligraphic</p></td> +</tr> +</tbody> +</table> +</blockquote> +<dl class="footnote"><dt class="label"><a class="fn-backref" href="#id13">2</a></dt> +<dd id="mathnormal"> +<p class="first last"><tt class="literal">\mathnormal</tt> is used by default for alphanumeric +characters in math mode. It sets the letter shape according to +character class and <a class="reference internal" href="#math-style">math style</a>. (<a class="reference internal" href="#table-1">Table 1</a> shows the default +letter shapes for common math styles).</p> +</dd> +<dt class="label"><a class="fn-backref" href="#id14">3</a></dt> +<dd id="roman"> +<p class="first last">The specifier “roman” is ambiguous: roman shape +stands for <em>upright</em>, while roman type stands for <em>serif</em> (as +opposed to sans serif).</p> +</dd> +</dl> +<p>Many packages define additional math alphabets (cf. <a class="reference internal" href="#table-6">Table 6</a>).</p> +<p>In contrast to the similar named text commands, math alphabets are +<em>not</em> orthogonal, e. g., the code <tt class="literal"><span class="pre">$\mathit{\mathbf{a}}$</span></tt> sets the +letter <tt class="literal">a</tt> in <strong>upright</strong> bold type.</p> +</div> +<div class="section" id="math-versions"> +<span id="math-version"></span><h3><span class="sectnum">4.1.2</span> Math versions</h3> +<p><em>Math versions</em> specify the mapping from commands for mathematical +symbols and <a class="reference internal" href="#math-alphabets">math alphabets</a> to a set of mathematical fonts<a class="footnote-reference" href="#id17" id="id15"><sup>4</sup></a>. +They are intended for mathematical content in a special context like a +bold section heading. Selecting a math version resembles +the individual selection of text font attributes.</p> +<dl class="docutils"> +<dt>Example:</dt> +<dd><p>Some alternatives to set the letter <tt class="literal">a</tt> in a bold upright sans-serif +font:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="44%" /> +<col width="56%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>Text</p></th> +<th class="head"><p>Math</p></th> +</tr> +</thead> +<tbody> +<tr><td><p><tt class="literal"><span class="pre">\textbf{\textsf{a}}</span></tt></p></td> +<td><p><tt class="literal"><span class="pre">$\bm{\mathsf{a}}$</span></tt></p></td> +</tr> +<tr><td><p><tt class="literal">\bfseries \textsf{a}</tt></p></td> +<td><p><tt class="literal">\mathversion{bold} $\mathsf{a}$</tt></p></td> +</tr> +<tr><td><p><tt class="literal">\bfseries \sffamily a</tt></p></td> +<td><p><tt class="literal">$\mathsfbf{a}$</tt></p></td> +</tr> +</tbody> +</table> +</dd> +</dl> +<p>The predefined math versions are <tt class="literal">normal</tt> and <tt class="literal">bold</tt> with the +following defaults for non-specified font attributes:</p> +<blockquote> +<table class="booktabs numbered align-left"> +<colgroup> +<col width="33%" /> +<col width="37%" /> +<col width="30%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>attribute</p></th> +<th class="head"><p><tt class="literal">normal</tt></p></th> +<th class="head"><p><tt class="literal">bold</tt></p></th> +</tr> +</thead> +<tbody> +<tr><td><p><em>type</em></p></td> +<td><p>serif</p></td> +<td><p>serif</p></td> +</tr> +<tr><td><p><em>weight</em></p></td> +<td><p>medium</p></td> +<td><p>bold</p></td> +</tr> +<tr><td><p><em>shape</em></p></td> +<td><p>upright</p></td> +<td><p>upright</p></td> +</tr> +</tbody> +</table> +</blockquote> +<p>Packages can define additional math versions, e. g., the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a> package +defines a <tt class="literal">sans</tt> math version (another <tt class="literal">sans</tt> math version example is +available from a <a class="reference external" href="http://newsgroups.derkeiler.com/Archive/Comp/comp.text.tex/2007-09/msg00181.html">comp.text.tex post`</a>) and the <a class="reference external" href="http://phong.informatik.uni-leipzig.de/~kuska/wri_texmf_4.2.zip">wrisym</a> package defines a +<tt class="literal">mono</tt> math version.</p> +<p>Math versions can only be changed outside of math mode. The commands +<tt class="literal">\boldsymbol</tt> (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsmath.html">amsmath</a>) and <tt class="literal">\bm</tt> (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bm.html">bm</a>) behave like <span class="target" id="in-line-math-versions">“in-line +math versions”</span>: they typeset their argument using the fonts of the +<tt class="literal">bold</tt> math version but can be used inside math mode.</p> +<dl class="footnote"><dt class="label"><a class="fn-backref" href="#id15">4</a></dt> +<dd id="id17"> +<p class="first last">The number of mathematical symbols exceeds the maximal number of +characters in a TeX font file by an order of magnitude: Unicode +defines about 2500 mathematical characters <a class="citation-reference" href="#tr25" id="id18">[tr25]</a>, font files used by +8-bit TeX engines are limited to 256 characters. The standard math +fonts adhere to the original limit of 128 characters. Grouping math +fonts with common characteristics in math versions simplifies the +setting of font attributes for mathematical expressions. TeX limits +the number of (symbol + alphanumeric) fonts per math version to 16.</p> +</dd> +</dl> +</div> +<div class="section" id="math-styles"> +<span id="math-style"></span><h3><span class="sectnum">4.1.3</span> Math styles</h3> +<p>A <em>math style</em> is a document-level feature that determines the default +letter shape in math mode (i. e. the shape attribute of letters in the +<tt class="literal">\mathnormal</tt> <a class="reference internal" href="#math-alphabet">math alphabet</a>).<a class="footnote-reference" href="#id20" id="id19"><sup>5</sup></a> +LaTeX defaults to the “TeX” math style (without naming it such). +Alternative math styles are introduced by extension packages +(<a class="reference internal" href="#table-2">Table 2</a>).</p> +<dl class="footnote"><dt class="label"><a class="fn-backref" href="#id19">5</a></dt> +<dd id="id20"> +<p class="first last">The <tt class="literal"><span class="pre">math-style</span></tt> option of <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a> changes also the shape +attribute of other math alphabets (see also section +<a class="reference internal" href="#the-unicode-math-package">the unicode-math package</a>).</p> +</dd> +</dl> +<table class="booktabs numbered align-left" id="table-1"> +<caption>Default letter shapes for common math styles</caption> +<colgroup> +<col width="30%" /> +<col width="18%" /> +<col width="18%" /> +<col width="18%" /> +<col width="18%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>math style</p></th> +<th class="head"><p>latin</p></th> +<th class="head"><p>Latin</p></th> +<th class="head"><p>greek</p></th> +<th class="head"><p>Greek</p></th> +</tr> +</thead> +<tbody> +<tr><td><p>TeX</p></td> +<td><p>it</p></td> +<td><p>it</p></td> +<td><p>it</p></td> +<td><p>up</p></td> +</tr> +<tr><td><p>ISO</p></td> +<td><p>it</p></td> +<td><p>it</p></td> +<td><p>it</p></td> +<td><p>it</p></td> +</tr> +<tr><td><p>French</p></td> +<td><p>it</p></td> +<td><p>up</p></td> +<td><p>up</p></td> +<td><p>up</p></td> +</tr> +<tr><td><p>upright</p></td> +<td><p>up</p></td> +<td><p>up</p></td> +<td><p>up</p></td> +<td><p>up</p></td> +</tr> +</tbody> +</table> +<table class="booktabs numbered align-left" id="table-2"> +<caption>Packages providing alternative math styles</caption> +<colgroup> +<col width="18%" /> +<col width="20%" /> +<col width="62%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>math style</p></th> +<th class="head"><p>Package</p></th> +<th class="head"><p>Option(s)</p></th> +</tr> +</thead> +<tbody> +<tr><td><p>ISO</p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a></p></td> +<td> </td> +</tr> +<tr><td><!-- --> +</td> +<td><p>isomath</p></td> +<td> </td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a></p></td> +<td><p>slantedGreeks</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://pctex.com/files/managed/b/bf/lucimatxAbbrev.pdf">lucimatx</a></p></td> +<td><p>math-style=iso</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a></p></td> +<td><p>greekuppercase=italicized</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathpazo.html">mathpazo</a></p></td> +<td><p>slantedGreek</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathptmx.html">mathptmx</a></p></td> +<td><p>slantedGreek</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +<td><p>math-style=ISO</p></td> +</tr> +<tr><td><p>French</p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fourier.html">fourier</a></p></td> +<td><p>upright</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a></p></td> +<td><p>frenchstyle (or upright)</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://pctex.com/files/managed/b/bf/lucimatxAbbrev.pdf">lucimatx</a></p></td> +<td><p>math-style=french</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a></p></td> +<td><p>uppercase=upright, greeklowercase=upright</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +<td><p>math-style=french</p></td> +</tr> +<tr><td><p>upright</p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/eulervm.html">eulervm</a></p></td> +<td> </td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://pctex.com/files/managed/b/bf/lucimatxAbbrev.pdf">lucimatx</a></p></td> +<td><p>math-style=upright</p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +<td><p>math-style=upright</p></td> +</tr> +</tbody> +</table> +</div> +</div> +<div class="section" id="oml-font-encoding"> +<h2><a class="toc-backref" href="#id50"><span class="sectnum">4.2</span> OML font encoding</a></h2> +<p>The equal treatment of Latin and Greek letters in the <a class="reference internal" href="#iso-math-style">“ISO” math +style</a> is best achieved with a font that contains all required +letters in one file.</p> +<p>There is only one established LaTeX font encoding that contains Latin and +Greek letters, the <a class="reference internal" href="#oml-font-encoding">OML font encoding</a>. The standard Greek font +encoding <cite>T7</cite> is just a “reserved name” and the de-facto standard +Greek text font encoding <cite>LGR</cite> has no Latin letters. Unfortunately, +<a class="reference internal" href="#oml-support">OML support</a> is limited to a few (mostly italic) fonts.</p> +<div class="section" id="discussion"> +<h3><span class="sectnum">4.2.1</span> Discussion</h3> +<p>The <cite>LaTeX font encodings</cite> guide <a class="citation-reference" href="#encguide" id="id21">[encguide]</a> names the OML encoding +<cite>TeX math italic</cite> and defines:</p> +<blockquote> +<p>The OML encoding contains italic Latin and Greek letters for use in +mathematical formulae (typically used for variables) together with some +symbols.</p> +</blockquote> +<p>The reference to <em>italic</em> shape is odd:</p> +<ul class="simple"> +<li><p>No other font encoding is specific to a font shape.</p></li> +<li><p>The different font selection and the semantic of font features in +mathematical formulae do not interfere with the font <em>encoding</em>: Both, +<tt class="literal">\DeclareSymbolFont</tt> and <tt class="literal">\DeclareMathAlphabet</tt> require a +shape argument. Thus it is possible to set up OML encoded math +alphabets in roman {n} as well as italic {it} shape without +conflicts.</p></li> +</ul> +<p>This seems to be more a remnant of pre-NFSS times than a necessary +restriction – there is only one OML encoded font in Knuth's Computer +Modern fonts: <cite>Computer Modern Math Italic</cite> (cmmi).</p> +<p>Proposals:</p> +<ul> +<li><p>Drop the <em>italic</em> from the definition. Optionally add an explanation:</p> +<blockquote> +<p>The OML encoding contains Latin and Greek letters for use in +mathematical formulae (typically used for variables) together with +some symbols. It first appeared in the <cite>Computer Modern Math +Italic</cite> (cmmi) font.</p> +</blockquote> +</li> +<li><p>The name <cite>TeX math italic</cite> can be interpreted as “the encoding +<strong>of</strong> <cite>Computer Modern Math Italic</cite>” rather than “an encoding +<strong>for</strong> math italic” fonts.</p> +<p>A less confusing name would be <cite>TeX math letters</cite> or <cite>Original/Old +Math Letters</cite>. The latter would also explain the acronym OML.</p> +</li> +</ul> +</div> +<div class="section" id="oml-support"> +<h3><span class="sectnum">4.2.2</span> OML Support</h3> +<p>Unfortunately, support for the OML encoding is missing for many font +families even if the text font defines Greek letters. +Supported font families can be found searching for <tt class="literal"><span class="pre">oml*.fd</span></tt> files +and grepping for <tt class="literal"><span class="pre">DeclareFont.*OML</span></tt> in <tt class="literal">*.sty</tt> files.</p> +<p><a class="reference internal" href="#table-3">Table 3</a> lists the findings for a selection of TeXLive 2012 + some +additionally installed font packages.</p> +<ul class="simple"> +<li><p>If there is an alias (substitution) from the text font to a +math-variant, only the text font is listed.</p></li> +<li><p>Many text fonts define substitutions also for upright shape, +however mapping to an italic variant of the OML encoded font. These +are not listed as supporting <tt class="literal">m/n</tt> or <tt class="literal">bx/n</tt> here.</p></li> +</ul> +<p><a class="reference internal" href="#table-4">Table 4</a> lists some fonts that define <tt class="literal">cmm</tt> as OML substitution. +With <cite>isomath</cite>, a better matching substitution can be set using the +<a class="reference internal" href="#rmdefault">rmdefault</a> or <a class="reference internal" href="#sfdefault">sfdefault</a> options.</p> +<table class="booktabs numbered align-left" id="table-3"> +<caption>Font families supporting the OML encoding</caption> +<colgroup> +<col width="18%" /> +<col width="45%" /> +<col width="9%" /> +<col width="11%" /> +<col width="8%" /> +<col width="9%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>Name</p></th> +<th class="head"><p>Family (package)</p></th> +<th class="head"><p>m/it</p></th> +<th class="head"><p>bx/it</p></th> +<th class="head"><p>m/n</p></th> +<th class="head"><p>bx/n</p></th> +</tr> +</thead> +<tbody> +<tr><td><p>antt</p></td> +<td><p>Antykwa Torunska (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/anttor.html">anttor</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>cmr</p></td> +<td><p>Computer Modern</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ccr</p></td> +<td><p>Concrete Roman (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/concmath.html">concmath</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>cmbr</p></td> +<td><p>CM Bright (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/cmbright.html">cmbright</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>hlh</p></td> +<td><p>Lucida</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>hfor</p></td> +<td><p>CM with old-style digits</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>iwona</p></td> +<td><p>Iwona (sans serif) (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/iwona.html">iwona</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>iwonal</p></td> +<td><p>Iwona light</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>iwonac</p></td> +<td><p>Iwona condensed</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>iwonalc</p></td> +<td><p>Iwona light condensed</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkp</p></td> +<td><p>Kepler Serif (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpw</p></td> +<td><p>Kepler Serif wide</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpvos</p></td> +<td><p>Kepler Serif oldstyle</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpvosw</p></td> +<td><p>Kepler Serif oldstyle wide</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpl</p></td> +<td><p>Kepler Serif light</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkplw</p></td> +<td><p>Kepler Serif light wide</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkplvos</p></td> +<td><p>Kepler Serif light oldstyle</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkplvosw</p></td> +<td><p>Kepler Serif light os wide</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpss</p></td> +<td><p>Kepler Sans (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jkpssvos</p></td> +<td><p>Kepler Sans oldstyle</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>jtm</p></td> +<td><p>expanded Times (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/jamtimes.html">jamtimes</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>llcmm</p></td> +<td><p>LX Fonts (sans serif) (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/lxfonts.html">lxfonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>lmr</p></td> +<td><p>Latin Modern Roman (lmodern)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>mak</p></td> +<td><p>Kerkis (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kerkis.html">kerkis</a>)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>kurier</p></td> +<td><p>Kurier (sans serif) (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kurier.html">kurier</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>kurierc</p></td> +<td><p>Kurier condensed</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>kurierl</p></td> +<td><p>Kurier light</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>kurierlc</p></td> +<td><p>Kurier light condensed</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>mdbch</p></td> +<td><p>Math Design Charter (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +</tr> +<tr><td><p>mdput</p></td> +<td><p>Math Design Utopia</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +</tr> +<tr><td><p>mdugm</p></td> +<td><p>Math Design Garamond</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +</tr> +<tr><td><p>neohellenic</p></td> +<td><p>Neohellenic (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/gfsneohellenic.html">gfsneohellenic</a>)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ntxmi</p></td> +<td><p>Times (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/newtx.html">newtx</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>nxlmi</p></td> +<td><p>Libertine (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/newtx.html">newtx</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>plcm</p></td> +<td><p>CM (PLaTeX)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ptmom</p></td> +<td><p>Times (Omega or MB-Times)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ptmomu</p></td> +<td><p>Times (Omega or MB-Times)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ptmcm</p></td> +<td><p>Times (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathptmx.html">mathptmx</a>)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>pxr</p></td> +<td><p>Palatino (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/pxfonts.html">pxfonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>qpl</p></td> +<td><p>Palatino/Pagella (qpxmath)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>qtm</p></td> +<td><p>Times/Termes (qtxmath)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>txr</p></td> +<td><p>Times (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/txfonts.html">txfonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>udidot</p></td> +<td><p>Didot (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/gfsdidot.html">gfsdidot</a>)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ywclm</p></td> +<td><p>(<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/greektex.html">greektex</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>zavm</p></td> +<td><p>Arev (Vera Sans-Serif)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>zplm</p></td> +<td><p>Palatino (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathpazo.html">mathpazo</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>zpple</p></td> +<td><p>Palatino</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>ztmcm</p></td> +<td><p>Times (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathptmx.html">mathptmx</a>)</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +<td> </td> +</tr> +<tr><td><p>zer</p></td> +<td><p>Computer Modern (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/zefonts.html">zefonts</a>)</p></td> +<td><p>✓</p></td> +<td><p>✓</p></td> +<td> </td> +<td> </td> +</tr> +</tbody> +</table> +<table class="booktabs numbered align-left" id="table-4"> +<caption>Non-CM fonts with <tt class="literal">cmm</tt> as OML substitution</caption> +<colgroup> +<col width="30%" /> +<col width="70%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>Family</p></th> +<th class="head"><p>Name</p></th> +</tr> +</thead> +<tbody> +<tr><td><p>bch</p></td> +<td><p>Charter (psnfss)</p></td> +</tr> +<tr><td><p>pag</p></td> +<td><p>Avant Garde (psnfss)</p></td> +</tr> +<tr><td><p>pbk</p></td> +<td><p>Bookman (psnfss)</p></td> +</tr> +<tr><td><p>pcr</p></td> +<td><p>Courier (psnfss)</p></td> +</tr> +<tr><td><p>phv</p></td> +<td><p>Helvetica (psnfss)</p></td> +</tr> +<tr><td><p>pnc</p></td> +<td><p>New Century Schoolbook (psnfss)</p></td> +</tr> +<tr><td><p>ppl</p></td> +<td><p>Palatino (psnfss)</p></td> +</tr> +<tr><td><p>ptm</p></td> +<td><p>Times Roman (psnfss)</p></td> +</tr> +<tr><td><p>put</p></td> +<td><p>Utopia (psnfss)</p></td> +</tr> +<tr><td><p>pzc</p></td> +<td><p>Zapf Chancery (psnfss)</p></td> +</tr> +<tr><td><p>uag</p></td> +<td><p>Avant Garde (avantgar)</p></td> +</tr> +<tr><td><p>ubk</p></td> +<td><p>Bookman (bookman)</p></td> +</tr> +<tr><td><p>ucr</p></td> +<td><p>Courier (courier)</p></td> +</tr> +<tr><td><p>ucrs</p></td> +<td><p>Courier</p></td> +</tr> +<tr><td><p>unc</p></td> +<td><p>New Century Schoolbook (psnfss)</p></td> +</tr> +<tr><td><p>uni</p></td> +<td><p>Universal (universa)</p></td> +</tr> +<tr><td><p>uhv</p></td> +<td><p>Helvetica (helvetic)</p></td> +</tr> +<tr><td><p>upl</p></td> +<td><p>Palatino (palatino)</p></td> +</tr> +<tr><td><p>utm</p></td> +<td><p>Times (times)</p></td> +</tr> +<tr><td><p>uzc</p></td> +<td><p>Zapf Chancery (zapfchan)</p></td> +</tr> +</tbody> +</table> +</div> +</div> +<div class="section" id="unicode-mathematical-typesetting"> +<h2><a class="toc-backref" href="#id51"><span class="sectnum">4.3</span> Unicode mathematical typesetting</a></h2> +<p>This section compares <a class="reference internal" href="#math-font-selection">math font selection</a> in LaTeX and Unicode. It +suggests a set of 14 math alphabet commands that covers all Unicode +<a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric symbols</a> and discusses compatibility issues +between math typesetting with traditional (8-bit) TeX engines versus <a class="reference internal" href="#the-unicode-math-package">the +unicode-math package</a> for Unicode-enabled TeX engines (XeTeX, LuaTeX).</p> +<p>The technical report <a class="citation-reference" href="#tr25" id="id22">[tr25]</a> presents an in-depth discussion of the +mathematical character repertoire of the Unicode Standard as well as +mathematical notation in general.</p> +<div class="section" id="unicode-mathematical-alphabets"> +<span id="mathematical-alphanumeric-symbols"></span><h3><span class="sectnum">4.3.1</span> Unicode mathematical alphabets</h3> +<p>Chapter 2 <cite>Mathematical Character Repertoire</cite> of <a class="citation-reference" href="#tr25" id="id23">[tr25]</a> lists 14 +<cite>Mathematical Alphabets</cite> in Table 2.1. These mathematical alphabets are a +superset of the predefined <a class="reference internal" href="#math-alphabets">math alphabets</a> in the LaTeX core.</p> +<p>Unicode assigns code points to most letters of the mathematical +alphabets in the <a class="reference external" href="http://www.unicode.org/charts/PDF/U1D400.pdf">mathematical alphanumeric symbols Unicode block</a>. +The plain (upright) letters have been unified with the +existing characters in the Basic Latin and Greek blocks.</p> +<p><a class="reference internal" href="#table-5">Table 5</a> maps the 14 Unicode mathematical alphabets to LaTeX commands +according to the <a class="reference internal" href="#naming-scheme">naming scheme</a> below. <a class="reference internal" href="#table-6">Table 6</a> lists the status of +LaTeX support for the mathematical alphanumeric symbols.</p> +<div class="section" id="naming-scheme"> +<h4><span class="sectnum">4.3.1.1</span> Naming scheme</h4> +<p>The naming scheme is an extension of the predefined <a class="reference internal" href="#math-alphabet">math alphabet</a> +commands with the established short-cuts:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="14%" /> +<col width="86%" /> +</colgroup> +<tbody> +<tr><td><p>bf</p></td> +<td><p>bold</p></td> +</tr> +<tr><td><p>it</p></td> +<td><p>italic</p></td> +</tr> +<tr><td><p>cal</p></td> +<td><p>script (calligraphic)</p></td> +</tr> +<tr><td><p>frak</p></td> +<td><p>fraktur</p></td> +</tr> +<tr><td><p>bb</p></td> +<td><p>double-struck (blackboard bold)</p></td> +</tr> +<tr><td><p>sf</p></td> +<td><p>sans serif</p></td> +</tr> +</tbody> +</table> +<p>combined to commands in the form <tt class="literal"><span class="pre">\math<type><weight><shape></span></tt>.</p> +<p>The <<em>type</em>>, <<em>weight</em>>, and <<em>shape</em>> specifiers are optional +(defaults depend on the <a class="reference internal" href="#math-version">math version</a>). Their order matches the +names of Unicode <a class="reference internal" href="#mathematical-alphanumeric-symbols">Mathematical Alphanumeric Symbols</a>.</p> +<p>Examples:</p> +<pre class="literal-block">\mathbf{d} % MATHEMATICAL BOLD SMALL D +\mathsfbfit{d} % MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL D. +</pre> +<table class="booktabs numbered align-left" id="table-5"> +<caption>Mapping Unicode <a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric symbols</a> to LaTeX +math alphabets.</caption> +<colgroup> +<col width="16%" /> +<col width="13%" /> +<col width="20%" /> +<col width="28%" /> +<col width="23%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>serifs</p></th> +<th class="head"><p>weight</p></th> +<th class="head"><p>shape</p></th> +<th class="head"><p>symbols</p></th> +<th class="head"><p>math alphabet</p></th> +</tr> +</thead> +<tbody> +<tr><td><p><em>serif</em></p></td> +<td><p><em>medium</em></p></td> +<td><p><em>upright</em></p></td> +<td><p>Latin/Greek/digits<a class="footnote-reference" href="#up" id="id24"><sup>6</sup></a></p></td> +<td><p><tt class="literal">\mathrm</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p>bold</p></td> +<td> </td> +<td><p>Latin/Greek/digits</p></td> +<td><p><tt class="literal">\mathbf</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td> </td> +<td><p>italic</p></td> +<td><p>Latin/Greek</p></td> +<td><p><tt class="literal">\mathit</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p>bold</p></td> +<td><p>italic</p></td> +<td><p>Latin/Greek</p></td> +<td><p><tt class="literal">\mathbfit</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td> </td> +<td><p>script</p></td> +<td><p>Latin</p></td> +<td><p><tt class="literal">\mathcal</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p>bold</p></td> +<td><p>script</p></td> +<td><p>Latin</p></td> +<td><p><tt class="literal">\mathbfcal</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td> </td> +<td><p>fraktur</p></td> +<td><p>Latin</p></td> +<td><p><tt class="literal">\mathfrak</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td> </td> +<td><p>double-struck</p></td> +<td><p>Latin/digits</p></td> +<td><p><tt class="literal">\mathbb</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p>bold</p></td> +<td><p>fraktur</p></td> +<td><p>Latin</p></td> +<td><p><tt class="literal">\mathbffrak</tt></p></td> +</tr> +<tr><td><p>sans serif</p></td> +<td> </td> +<td> </td> +<td><p>Latin/digits</p></td> +<td><p><tt class="literal">\mathsf</tt></p></td> +</tr> +<tr><td><p>sans serif</p></td> +<td><p>bold</p></td> +<td> </td> +<td><p>Latin/Greek/digits</p></td> +<td><p><tt class="literal">\mathsfbf</tt></p></td> +</tr> +<tr><td><p>sans serif</p></td> +<td> </td> +<td><p>italic</p></td> +<td><p>Latin</p></td> +<td><p><tt class="literal">\mathsfit</tt></p></td> +</tr> +<tr><td><p>sans serif</p></td> +<td><p>bold</p></td> +<td><p>italic</p></td> +<td><p>Latin/Greek</p></td> +<td><p><tt class="literal">\mathsfbfit</tt></p></td> +</tr> +<tr><td><!-- --> +</td> +<td> </td> +<td><p>monospace</p></td> +<td><p>Latin/digits</p></td> +<td><p><tt class="literal">\mathtt</tt></p></td> +</tr> +</tbody> +</table> +<dl class="footnote"><dt class="label">6</dt> +<dd id="up"> +<em>(<a class="fn-backref" href="#id24">1</a>, <a class="fn-backref" href="#id25">2</a>)</em> <p class="last">plain standard characters outside the +<cite>mathematical alphanumeric symbols</cite> Unicode block.</p> +</dd> +</dl> +</div> +<div class="section" id="latex-support"> +<h4><span class="sectnum">4.3.1.2</span> LaTeX support</h4> +<p>Most commonly used math alphabets are supported either by the TeX kernel +or additional packages. Full support is only provided by <a class="reference internal" href="#the-unicode-math-package">the unicode-math +package</a>.</p> +<table class="booktabs numbered align-left" id="table-6"> +<caption>LaTeX support for <a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric symbols</a>.</caption> +<colgroup> +<col width="18%" /> +<col width="38%" /> +<col width="43%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>style</p></th> +<th class="head"><p>math alphabet</p></th> +<th class="head"><p>package, comment</p></th> +</tr> +</thead> +<tbody> +<tr><td><p>plain<a class="footnote-reference" href="#up" id="id25"><sup>6</sup></a></p></td> +<td><p><tt class="literal">\mathrm</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#no-g" id="id26"><sup>7</sup></a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathup</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html">kpfonts</a></p></td> +</tr> +<tr><td><p>bf</p></td> +<td><p><tt class="literal">\mathbf</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#no-g" id="id27"><sup>7</sup></a></p></td> +</tr> +<tr><td><p>it</p></td> +<td><p><tt class="literal">\mathit</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#no-g" id="id28"><sup>7</sup></a></p></td> +</tr> +<tr><td><p>bf it</p></td> +<td><p><tt class="literal">\mathbfit</tt></p></td> +<td><p>isomath<a class="footnote-reference" href="#digits" id="id29"><sup>8</sup></a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathbold</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathpazo.html">mathpazo</a>, +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathptmx.html">mathptmx</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/tmmath.html">tmmath</a><a class="footnote-reference" href="#digits" id="id30"><sup>8</sup></a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\boldsymbol</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsmath.html">amsmath</a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\bm</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bm.html">bm</a></p></td> +</tr> +<tr><td><p>cal</p></td> +<td><p><tt class="literal">\mathcal</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#script" id="id31"><sup>9</sup></a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathscr</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathrsfs.html">mathrsfs</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/euscript.html">euscript</a>, +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a></p></td> +</tr> +<tr><td><p>bf cal</p></td> +<td><p><tt class="literal">\mathbfscr</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +</tr> +<tr><td><p>frak</p></td> +<td><p><tt class="literal">\mathfrak</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amssymb.html">amssymb</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amsfonts.html">amsfonts</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/eufrak.html">eufrak</a></p></td> +</tr> +<tr><td><p>bf frak</p></td> +<td><p><tt class="literal">\mathbffrak</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +</tr> +<tr><td><p>bb</p></td> +<td><p><tt class="literal">\mathbb</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/amssymb.html">amssymb</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bbold.html">bbold</a>, +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathbbol.html">mathbbol</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mbboard.html">mbboard</a>, +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathpazo.html">mathpazo</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/sbbm.html">sbbm</a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathbbm</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/bbm.html">bbm</a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathds</tt></p></td> +<td><p>dsfont (<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/doublestoke.html">doublestoke</a>)</p></td> +</tr> +<tr><td><p>sf</p></td> +<td><p><tt class="literal">\mathsf</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#no-g" id="id32"><sup>7</sup></a></p></td> +</tr> +<tr><td><p>sf bf</p></td> +<td><p><tt class="literal">\mathbfsfup</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +</tr> +<tr><td><p>sf it</p></td> +<td><p><tt class="literal">\mathsfit</tt></p></td> +<td><p>isomath<a class="footnote-reference" href="#digits" id="id33"><sup>8</sup></a></p></td> +</tr> +<tr><td><p>sf bf it</p></td> +<td><p><tt class="literal">\mathsfbfit</tt></p></td> +<td><p>isomath<a class="footnote-reference" href="#digits" id="id34"><sup>8</sup></a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathbold</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/cmbright.html">cmbright</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/hvmath.html">hvmath</a></p></td> +</tr> +<tr><td><!-- --> +</td> +<td><p><tt class="literal">\mathbfsfit</tt></p></td> +<td><p><a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a></p></td> +</tr> +<tr><td><p>tt</p></td> +<td><p><tt class="literal">\mathtt</tt></p></td> +<td><p>predefined<a class="footnote-reference" href="#no-g" id="id35"><sup>7</sup></a></p></td> +</tr> +</tbody> +</table> +<dl class="footnote"><dt class="label">7</dt> +<dd id="no-g"> +<em>(<a class="fn-backref" href="#id26">1</a>, <a class="fn-backref" href="#id27">2</a>, <a class="fn-backref" href="#id28">3</a>, <a class="fn-backref" href="#id32">4</a>, <a class="fn-backref" href="#id35">5</a>)</em> <p class="last">no small Greek, full Greek with <a class="reference internal" href="#omlmath">OMLmath*</a> options and +OML-encoded fonts</p> +</dd> +<dt class="label">8</dt> +<dd id="digits"> +<em>(<a class="fn-backref" href="#id29">1</a>, <a class="fn-backref" href="#id30">2</a>, <a class="fn-backref" href="#id33">3</a>, <a class="fn-backref" href="#id34">4</a>)</em> <p class="last">Some italic math fonts (e. g., cmr, cmbr) have old-style +numbers in place of italic digits.</p> +</dd> +<dt class="label"><a class="fn-backref" href="#id31">9</a></dt> +<dd id="script"> +<p class="first last">formal script with <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/calrsfs.html">calrsfs</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/eucal.html">eucal</a>, <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fourier.html">fourier</a>, +small Latin letters only with <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/urwchancal.html">urwchancal</a></p> +</dd> +</dl> +</div> +</div> +<div class="section" id="the-unicode-math-package"> +<h3><span class="sectnum">4.3.2</span> The unicode-math package</h3> +<p>Users of UTF-8 enabled TeX engines (XeTeX, LuaTeX) can typeset +mathematics with the experimental <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a> package by Will +Robertson. It provides a LaTeX interface to OpenType fonts with math +support, e. g., <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/asana-math.html">Asana Math</a>, Cambria Math, <a class="reference external" href="https://github.com/khaledhosny/euler-otf">New Euler</a> or <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/xits.html">XITS</a>, with +commands to access the complete mathematical character repertoire of the +Unicode Standard.</p> +<p>LaTeX <a class="reference internal" href="#math-font-selection">math font selection</a> methods with unicode-math:</p> +<ul> +<li><p><a class="reference internal" href="#math-alphabets">Math alphabets</a> map to a range of the <a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric +symbols</a> block in the current font (or a substitution defined with the +<tt class="literal">range</tt> math font option).</p> +<p>Some command names differ from the <a class="reference internal" href="#predefined-math-alphabets">predefined math alphabets</a> or the +above <a class="reference internal" href="#naming-scheme">naming scheme</a>:</p> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="50%" /> +<col width="50%" /> +</colgroup> +<thead valign="bottom"> +<tr><th class="head"><p>LaTeX</p></th> +<th class="head"><p>unicode-math</p></th> +</tr> +</thead> +<tbody> +<tr><td><p><tt class="literal">\mathbf</tt></p></td> +<td><p><tt class="literal">\mathbfup</tt></p></td> +</tr> +<tr><td><p><tt class="literal">\mathsf</tt></p></td> +<td><p><tt class="literal">\mathsfup</tt></p></td> +</tr> +<tr><td><p><tt class="literal">\mathsfbf</tt></p></td> +<td><p><tt class="literal">\mathbfsfup</tt></p></td> +</tr> +<tr><td><p><tt class="literal">\mathsfbfit</tt></p></td> +<td><p><tt class="literal">\mathbfsfit</tt></p></td> +</tr> +</tbody> +</table> +<p>With unicode-math, <tt class="literal">\mathbf</tt>, <tt class="literal">\mathsf</tt>, and <tt class="literal">\mathsfbf</tt> +behave similar to <a class="reference internal" href="#in-line-math-versions">“in-line math versions”</a>: they consider the +<a class="reference internal" href="#math-style">math style</a> for upright vs. italic shape. Compatibility can be +achieved via the options <tt class="literal"><span class="pre">bold-style=upright</span></tt> and +<tt class="literal"><span class="pre">sans-style=upright</span></tt>.</p> +<p><tt class="literal">\mathbfsfit</tt> reverses the order of the <tt class="literal">sf</tt> and <tt class="literal">bf</tt> selectors, +so that, e. g., the Unicode character MATHEMATICAL SANS-SERIF BOLD +ITALIC CAPITAL A is selected by the non-mnemonic <tt class="literal">\mathbfsfit{A}</tt>.</p> +</li> +<li><p><a class="reference internal" href="#math-versions">Math versions</a> can be set up using the syntax +<tt class="literal"><span class="pre">\setmathfont[version=<version</span> <span class="pre">name>,<font</span> <span class="pre">features>]{<font</span> name>}</tt></p></li> +<li><p>Several <a class="reference internal" href="#math-styles">math styles</a> are supported with the <tt class="literal"><span class="pre">math-style</span></tt> package +option that accepts the values <tt class="literal">TeX</tt>, <tt class="literal">ISO</tt>, <tt class="literal">french</tt>, <tt class="literal">upright</tt>, +and <tt class="literal">literal</tt>.</p></li> +</ul> +</div> +</div> +<div class="section" id="conclusions-and-outlook"> +<h2><a class="toc-backref" href="#id52"><span class="sectnum">4.4</span> Conclusions and outlook</a></h2> +<p>It is hoped, that in the future more font families will support the +OML encoding in normal and bold weight as well as upright and italic +shape. This would be a major step towards a LaTeX equivalent of the +<a class="reference internal" href="#mathematical-alphanumeric-symbols">mathematical alphanumeric symbols</a> Unicode block.</p> +<p>This should be (relatively) easy to achieve via virtual fonts when the +glyphs for the Greek letters already exist. Examples are Latin Modern, +Kerkis, GFS Neohellenic, LX Fonts and KP-Serif.</p> +<p>Upright small Greek letters in <tt class="literal">\mathrm</tt> would enable the +specification of the constant pi, Myons, Pions, alpha-particles, +photons, and neutrinos with <a class="reference internal" href="#math-alphabets">math alphabets</a>. (With <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a> +fonts, this is already possible today.)</p> +<p>With the development of the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a> package, an interesting +alternative for ISO-conforming math typesetting became available to +users of Unicode-enabled TeX engines (XeTeX or LuaTeX).</p> +</div> +</div> +<div class="section" id="references"> +<h1><a class="toc-backref" href="#id53"><span class="sectnum">5</span> References</a></h1> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id7">[ISO-80000-2]</a></dt> +<dd id="iso-80000-2"> +<p class="first last"><cite>Quantities and units – Part 2: Mathematical signs +and symbols to be used in the natural sciences and technology</cite>: +<a class="reference external" href="http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?csnumber=31887">http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?csnumber=31887</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label">[ISO-31]</dt> +<dd id="iso-31"> +<p class="first last"><cite>Quantities and units</cite>, Superseded by [ISO-80000].</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id1">[typefaces]</a></dt> +<dd id="typefaces"> +<p class="first last">National Institute of Standards and Technology (<a class="reference external" href="http://physics.nist.gov/">NIST</a>), +<cite>Typefaces for Symbols in Scientific Manuscripts</cite>: +<a class="reference external" href="http://physics.nist.gov/cuu/pdf/typefaces.pdf">http://physics.nist.gov/cuu/pdf/typefaces.pdf</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id2">[checklist]</a></dt> +<dd id="checklist"> +<p class="first last">National Institute of Standards and Technology (<a class="reference external" href="http://physics.nist.gov/">NIST</a>), +<cite>SI Unit rules and style conventions</cite> +Check List for Reviewing Manuscripts: +<a class="reference external" href="http://physics.nist.gov/cuu/Units/checklist.html">http://physics.nist.gov/cuu/Units/checklist.html</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id4">[fonts_for_symbols]</a></dt> +<dd id="fonts-for-symbols"> +<p class="first last">International Union of Pure and Applied +Chemistry (<a class="reference external" href="http://iupac.org/">IUPAC</a>), <cite>On the use of italic and roman fonts for symbols +in scientific text</cite>, (Revised December 1999): +<a class="reference external" href="http://old.iupac.org/standing/idcns/fonts_for_symbols.html">http://old.iupac.org/standing/idcns/fonts_for_symbols.html</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id3">[SI]</a></dt> +<dd id="si"> +<p class="first last">Bureau international des poids et mesures (<a class="reference external" href="http://www.bipm.org/">BIPM</a>), +<cite>The International System of Units (SI)</cite>: +<a class="reference external" href="http://www.bipm.org/en/si/si_brochure/">http://www.bipm.org/en/si/si_brochure/</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id6">[Green-Book]</a></dt> +<dd id="green-book"> +<p class="first last">International Union of Pure and Applied Chemistry (<a class="reference external" href="http://iupac.org/">IUPAC</a>), +<cite>Quantities, Units and Symbols in Physical Chemistry</cite>, +3rd edition, RSC Publishing, Cambridge 2007: +[ISBN 0 85404 433 7; ISBN-13 978 0 85404 433 7].</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id5">[Red-Book]</a></dt> +<dd id="red-book"> +<p class="first last">International Union of Pure and Applied Physics (<a class="reference external" href="http://www.iupap.org/">IUPAP</a>), +<cite>Symbols, Units, Nomenclature and Fundamental Constants in Physics</cite>: +<a class="reference external" href="http://metrology.wordpress.com/measurement-process-index/iupap-red-book/index-iupap-red-book/">http://metrology.wordpress.com/measurement-process-index/iupap-red-book/index-iupap-red-book/</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id10">[becc97]</a></dt> +<dd id="becc97"> +<p class="first last">Claudio Beccari, <cite>Typesetting mathematics for science and +technology according to ISO 31 XI</cite>, TUGboat, Volume 18, 1997, No. 1: +<a class="reference external" href="http://www.tug.org/TUGboat/tb18-1/tb54becc.pdf">http://www.tug.org/TUGboat/tb18-1/tb54becc.pdf</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label"><a class="fn-backref" href="#id21">[encguide]</a></dt> +<dd id="encguide"> +<p class="first last">Frank Mittelbach, Robin Fairbairns, Werner Lemberg, +LaTeX3 Project Team, <cite>LaTeX font encodings</cite>: +<a class="reference external" href="http://mirror.ctan.org/macros/latex/doc/encguide.pdf">http://mirror.ctan.org/macros/latex/doc/encguide.pdf</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label">[fntguide]</dt> +<dd id="fntguide"> +<em>(<a class="fn-backref" href="#id11">1</a>, <a class="fn-backref" href="#id12">2</a>)</em> <p class="last">LaTeX3 Project Team, <cite>LaTeX 2e font selection</cite>: +<a class="reference external" href="http://mirror.ctan.org/macros/latex/doc/fntguide.pdf">http://mirror.ctan.org/macros/latex/doc/fntguide.pdf</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label">[tr25]</dt> +<dd id="tr25"> +<em>(<a class="fn-backref" href="#id18">1</a>, <a class="fn-backref" href="#id22">2</a>, <a class="fn-backref" href="#id23">3</a>)</em> <p class="last">Barbara Beeton, Asmus Freytag, Murray Sargent III, +<cite>Unicode Support for Mathematics</cite>, Unicode Technical Report #25: +<a class="reference external" href="http://www.unicode.org/reports/tr25/">http://www.unicode.org/reports/tr25/</a>.</p> +</dd> +</dl> +<dl class="citation"><dt class="label">[beeton:2000]</dt> +<dd id="beeton-2000"> +<p class="first last">Barbara Beeton: +<cite>Unicode and math, a combination whose time has come – Finally!</cite>, +TUGBoat, 21#3, 2000: +<a class="reference external" href="http://www.tug.org/TUGboat/Articles/tb21-3/tb68beet.pdf">http://www.tug.org/TUGboat/Articles/tb21-3/tb68beet.pdf</a>.</p> +</dd> +</dl> +<!-- see also +[koma-mail] Custom font substitution: http://www.komascript.de/node/823. --> +<!-- Links +===== --> +</div> +</div> +</body> +</html> diff --git a/macros/latex/contrib/isomath/isomath.pdf b/macros/latex/contrib/isomath/isomath.pdf Binary files differnew file mode 100644 index 0000000000..803a6f6fd2 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.pdf diff --git a/macros/latex/contrib/isomath/isomath.sty b/macros/latex/contrib/isomath/isomath.sty new file mode 100644 index 0000000000..97a6ee32bd --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.sty @@ -0,0 +1,372 @@ +% isomath +% ******* +% Mathematical style for science and technology +% ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +% +% :Date: 2012-09-10 +% :Copyright: © 2008, 2012 Günter Milde +% :Licence: This work may be distributed and/or modified under the +% conditions of the `LaTeX Project Public License`_, either +% version 1.3 of this license or (at your option) any later version. +% +% :Abstract: The `isomath` package provides tools for a mathematical style +% that conforms to the International Standard ISO 80000-2 and is +% common in science and technology. It changes the default shape of +% capital Greek letters to italic, sets up bold italic and +% sans-serif bold italic math alphabets with Latin and Greek +% characters, and defines macros for markup of vector, matrix and +% tensor symbols. +% +% :Identification: +% :: + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{isomath} +[2012/09/04 v0.6.1 ISO math style] + +% .. contents:: +% +% History +% ======= +% +% .. class:: borderless +% +% ===== =========== ======================================================== +% 0.1 2008-09-25 first public version. +% 0.2 2008-10-02 bugfix: a usage example was uncommented; +% \ updated documentation; +% \ define \mathsans only if OMLmathsans is true; +% \ option reuseMathalphabets -> reuseMathAlphabets. +% 0.3 2009-06-19 documentation update; +% \ fix OMLmathrm and OMLmathsans definitions; +% \ switch license to LPP. +% 0.4 2010-08-23 split user documentation from literate source; +% \ option ``scaled``; +% \ documentation update. +% 0.5 2011-01-04 math alphabet names matching Unicode; +% \ documentation review and extension; +% \ bold alphabet variants in ``bold`` math version; +% \ upright numbers with ``\vectorsym``. +% 0.6 2012-09-10 Scaling for Kepler Sans (``sfdefault=jkpss``); +% \ documentation update, new caption and abstract. +% ===== =========== ======================================================== +% +% +% Requirements +% ============ +% +% fixmath.sty +% ----------- +% The package fixmath_ by Walter Schmidt defines Greek letters as symbols +% of type ``\mathalpha`` and takes them from the ``letters`` symbol font in +% ``\mathnormal`` (as opposed to ``operators`` in ``fontmath.ltx``). +% +% `fixmath` also defines the ``\mathbold`` alphabet, setting it to ``cmm``. +% `isomath` overwrites this definition with a configurable value for +% the font family. :: + +\RequirePackage{fixmath} + + +% kvoptions.sty +% ------------- +% The kvoptions_ package in the oberdiek_ bundle facilitates the setup of +% package options and provides a key=value interface (based on keyval_):: + +\RequirePackage{kvoptions} + + +% Options +% ======= +% +% rmdefault +% --------- +% Family for roman math fonts. Must be available in OML +% encoding. The default is to use the corresponding text font family +% (``\rmdefault``). :: + +\DeclareStringOption[\rmdefault]{rmdefault} + +% sfdefault +% --------- +% Family for sans-serif math fonts. The default selects `CM Bright`, as +% most sans serif fonts are not available in OML encoding:: + +\DeclareStringOption[cmbr]{sfdefault} + +% scaled +% ------ +% The sans-serif fonts, ``fav`` (Arev), ``llcmss`` (LX Fonts), +% ``jkpss`` (Kepler Serif) and ``iwona`` can be scaled +% with the ``scaled`` option. :: + +\DeclareStringOption[1.0]{scaled} + +% reuseMathAlphabets +% ------------------ +% The definition of new `math alphabets`_ can lead to a “too many math +% alphabets used in version normal” error. +% +% As a workaround, this option tells `isomath` to re-use the existing +% ``\mathbf`` and ``\mathsf`` alphabets for *italic* bold and sans-serif +% bold. :: + +\DeclareBoolOption{reuseMathAlphabets} + +% OMLmath* +% -------- +% The following options cause `isomath` to (re)define the corresponding +% `math alphabets`_ in OML encoding:: + +\DeclareBoolOption{OMLmathrm} +\DeclareBoolOption{OMLmathbf} +\DeclareBoolOption{OMLmathsf} +\DeclareBoolOption{OMLmathsfit} +\DeclareBoolOption{OMLmathtt} +% backwards compatibility option alias +\DeclareVoidOption{OMLmathsans}{\isomath@OMLmathsfittrue} + +% Setting these options enables access to small Greek letters in different +% shapes with e.g. ``\mathrm{\pi}`` but only *if an OML encoded font is +% available*. Currently, only the mathdesign_ fonts support roman in OML +% encoding. +% +% With some packages, these options can result in a “too many math alphabets +% used in version normal” error. +% +% -------------------------------------------------------- +% +% Process the options with ``kvoptions`` extensions:: + +\ProcessKeyvalOptions* + + +% Declarations +% ============ +% +% Math alphabets +% -------------- +% +% In math, LaTeX uses “absolute” fontnames instead of a selection by +% family, shape, and weight because typefaces have a semantic meaning +% [fntguide]_. +% +% `isomath` defines a math alphabet for every required font variant and +% optionally re-defines the standard math alphabets in `OML` font encoding. +% +% Unfortunately, the number of math alphabets in one math version is +% limited to 16, so we have to be careful not to exceed this. The +% ``reuseMathAlphabets`` option reduces the number of math alphabet +% definitions by two, with the side effect of italic shape with +% ``\mathbf`` and ``\mathsf`` commands:: + +\ifisomath@reuseMathAlphabets + \PackageWarningNoLine{isomath}{% + Re-using math alphabet `mathsf' for \protect \mathsfbfit + \MessageBreak and `mathbf' for \protect \mathbfit + } +\fi + +% mathbfit +% ~~~~~~~~ +% The *bold italic* math alphabet is named ``\mathbfit`` like in +% unicode-math_ (with an alias ``\mathbold`` like in fixmath_ and +% related packages). With the reuseMathAlphabets_ option, the roman bold +% math alphabet ``\mathbf`` is redefined and ``\mathbfit`` made an +% alias. The series selector ``bx`` (bold extended) is used, because it +% is better supported than ``b``. (Is there any LaTeX math font +% distinguishing between ``b`` and ``bx``?) :: + +\ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathbf}{OML}{\isomath@rmdefault}{bx}{it} + \def\mathbfit{\mathbf} +\else + \DeclareMathAlphabet{\mathbfit}{OML}{\isomath@rmdefault}{bx}{it} +\fi + +% alias (overwriting the definition from fixmath):: + +\renewcommand*{\mathbold}{\mathbfit} + +% mathsfit +% ~~~~~~~~ +% For *sans-serif italic*, we define a new alphabet ``\mathsfit`` (with +% the alias ``\mathsans`` in analogy to ``\mathbold``). As this typeface +% is not required by ISO 80000-2 and TeX limits the number of math alphabets +% to 16 per math version, it is only defined if the ``OMLmathsfit`` or +% ``OMLmathsans`` option is set:: + +\ifisomath@OMLmathsfit + \DeclareMathAlphabet{\mathsfit}{OML}{\isomath@sfdefault}{m}{it} + \SetMathAlphabet{\mathsfit}{bold}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsans{\mathsfit} +\fi + +% mathsfbfit +% ~~~~~~~~~~~~ +% The *sans serif bold italic* alphabet is used for tensor symbols. +% Following the Unicode naming scheme it is called +% ``\mathsfbfit``(with the backwards compatibility alias ``\mathboldsans``). +% With the reuseMathAlphabets_ option, the upright sans serif math +% alphabet ``\mathsf`` is redefined and ``\mathsfbfit`` made an +% alias to it:: + +\ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathsf}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsfbfit{\mathsf} +\else + \DeclareMathAlphabet{\mathsfbfit}{OML}{\isomath@sfdefault}{bx}{it} +\fi +\def\mathboldsans{\mathsfbfit} + +% Redefine standard alphabets +% ~~~~~~~~~~~~~~~~~~~~~~~~~~~ +% +% Redefine standard alphabets in `OML` font encoding +% if the corresponding `OMLmath*`_ option is true:: + +\ifisomath@OMLmathrm + \SetMathAlphabet{\mathrm}{normal}{OML}{\isomath@rmdefault}{m}{n} + \SetMathAlphabet{\mathrm}{bold}{OML}{\isomath@rmdefault}{bx}{n} +\fi +\ifisomath@OMLmathbf + \SetMathAlphabet{\mathbf}{normal}{OML}{\isomath@rmdefault}{bx}{n} +\fi +\ifisomath@OMLmathsf + \SetMathAlphabet{\mathsf}{normal}{OML}{\isomath@sfdefault}{m}{n} + \SetMathAlphabet{\mathsf}{bold}{OML}{\isomath@sfdefault}{bx}{n} +\fi +\ifisomath@OMLmathtt + \SetMathAlphabet{\mathtt}{normal}{OML}{\ttdefault}{m}{n} + \SetMathAlphabet{\mathtt}{bold}{OML}{\ttdefault}{bx}{n} +\fi + +% Command aliases +% --------------- +% +% The following macros allow semantic markup of mathematical symbols. +% The argument is typeset as proposed by ISO 80000-2 and +% `Typefaces for Symbols in Scientific Manuscripts`_. +% +% \\vectorsym +% ~~~~~~~~~~~ +% Alphabetic vectors symbols are typeset *boldface italic* while numeric +% ones (e.g. zero vector) are typeset *boldface upright*. The number +% test is a simplified version from the LaTeX FAQ "`Is the argument a number?`__" +% It fails if a number is followed by a non-number, e.g. ``\vectorsym{1a}``, +% but this is no valid vector symbol and would look strange with the +% ``\vec`` accent, too. :: + +\providecommand*{\vectorsym}[1]{% + \ifnum9<1#1% + \mathbf{#1}% + \else% + \mathbfit{#1}% + \fi} + +% For easier writing or to make existing documents conform to the standard, +% you might want to re-define the standard ``\vec`` command after loading this +% package. +% +% __ http://www.tex.ac.uk/cgi-bin/texfaq2html?label=isitanum +% +% \\matrixsym +% ~~~~~~~~~~~ +% Symbols for matrices are typeset *boldface italic*, i. e. in the same face +% as vectors. :: + +\providecommand*{\matrixsym}{\vectorsym} + +% \\tensorsym +% ~~~~~~~~~~~ +% Symbols for tensors are *sans-serif bold italic*:: + +\providecommand*{\tensorsym}{\mathsfbfit} + + +% Font setup fixes +% ---------------- +% +% Substitutions needed for the math alphabet definitions and setup for +% scaled fonts. For details about the font definition macros see +% [fntguide]_. +% +% Unknown makro in font definition file +% ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +% The `Kepler Sans` font definition file ``omljkpss.fd`` contains a boolean +% that is defined in ``kpfonts.sty``. This leads to errors if the fonts are +% used from another package. Provide a dummy definition:: + +\newif\ifkp@upRm + + +% Common family name for text and math fonts +% ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +% Some font packages provide matching text and math font but do not +% define a substitution in their ``*.fd`` files. Ideally, the following +% mappings should be moved there. +% +% Mathpazo (Palatino) ppl ↔ zplm :: + +\DeclareFontFamily{OML}{ppl}{\skewchar\font127} +\DeclareFontShape{OML}{ppl}{m}{it}{<-> ssub * zplm/m/it}{} +\DeclareFontShape{OML}{ppl}{bx}{it}{<-> ssub * zplm/b/it}{} + + +% Scaling +% ~~~~~~~ +% Scale the ``fav`` (Arev), ``iwona``, ``jkpss`` (Kepler Sans) and +% ``llcmss`` (LX Fonts) sans serif fonts by the value of the scaled_ option. +% +% To get scaled versions of a font, you cannot use the ``ssub`` +% `size function`, but must use the empty function or ``s`` with the font +% file as argument [found by experiment, GM 2010-01-28]. +% +% Arev (see ``omlzavm.fd``) fav ↔ zavm:: + +\DeclareFontFamily{OML}{fav}{\skewchar\font127} +\DeclareFontShape{OML}{fav}{m}{it}{<-> s * [\isomath@scaled] zavmri7m}{} +\DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [\isomath@scaled] zavmbi7m}{} + +% Iwona (see ``omliwona.fd``) iwona ↔ mi-iwona:: + +\DeclareFontFamily{OML}{iwona}{} +\DeclareFontShape{OML}{iwona}{m}{it}{<-> s * [\isomath@scaled] mi-iwonari}{} +\DeclareFontShape{OML}{iwona}{bx}{it}{<-> s * [\isomath@scaled] mi-iwonabi}{} + +% Kepler Serif (see ``omljkpss.fd``):: + +\DeclareFontFamily{OML}{jkpss}{\skewchar\font127 } +\DeclareFontShape{OML}{jkpss}{m}{it}{<-> s * [\isomath@scaled] jkpssmi}{} +\DeclareFontShape{OML}{jkpss}{bx}{it}{<-> s * [\isomath@scaled] jkpssbmi}{} + +% LX Fonts (see ``lxfonts.sty``) llcmss ↔ llcmm:: + +\DeclareFontFamily{OML}{llcmss}{\skewchar\font'177} +\DeclareFontShape{OML}{llcmss}{m}{it}{<-> s * [\isomath@scaled] lcmmi8}{} +\DeclareFontShape{OML}{llcmss}{bx}{it}{<-> s * [\isomath@scaled] lcmmib8}{} + + +% References +% ========== +% +% .. [fntguide] `LaTeX 2e font selection`: +% http://mirror.ctan.org/macros/latex/doc/fntguide.pdf. +% +% .. _LaTeX Project Public License: http://www.latex-project.org/lppl.txt +% .. _arev: http://mirror.ctan.org/help/Catalogue/entries/arev.html +% .. _cmbright: http://mirror.ctan.org/help/Catalogue/entries/cmbright.html +% .. _fixmath: http://mirror.ctan.org/help/Catalogue/entries/fixmath.html +% .. _hvmath: http://mirror.ctan.org/help/Catalogue/entries/hvmath.html +% .. _iwona: http://mirror.ctan.org/help/Catalogue/entries/iwona.html +% .. _keyval: http://mirror.ctan.org/help/Catalogue/entries/keyval.html +% .. _kvoptions: http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html +% .. _lxfonts: http://mirror.ctan.org/help/Catalogue/entries/lxfonts.html +% .. _mathdesign: http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html +% .. _mathematical alphanumeric symbols: +% http://www.unicode.org/charts/PDF/U1D400.pdf +% .. _oberdiek: http://mirror.ctan.org/help/Catalogue/entries/oberdiek.html +% .. _`Typefaces for Symbols in Scientific Manuscripts`: +% http://physics.nist.gov/cuu/pdf/typefaces.pdf +% .. _unicode-math: +% http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html diff --git a/macros/latex/contrib/isomath/isomath.sty.html b/macros/latex/contrib/isomath/isomath.sty.html new file mode 100644 index 0000000000..86244f53e7 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.sty.html @@ -0,0 +1,1214 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> +<meta name="generator" content="Docutils 0.10: http://docutils.sourceforge.net/" /> +<title>isomath</title> +<meta name="date" content="2012-09-10" /> +<meta name="copyright" content="© 2008, 2012 Günter Milde" /> +<style type="text/css"> + +/* +:Author: David Goodger (goodger@python.org) +:Id: $Id: html4css1.css 7434 2012-05-11 21:06:27Z milde $ +:Copyright: This stylesheet has been placed in the public domain. + +Default cascading style sheet for the HTML output of Docutils. + +See http://docutils.sf.net/docs/howto/html-stylesheets.html for how to +customize this style sheet. +*/ + +/* used to remove borders from tables and images */ +.borderless, table.borderless td, table.borderless th { + border: 0 } + +table.borderless td, table.borderless th { + /* Override padding for "table.docutils td" with "! important". + The right padding separates the table cells. */ + padding: 0 0.5em 0 0 ! important } + +.first { + /* Override more specific margin styles with "! important". */ + margin-top: 0 ! important } + +.last, .with-subtitle { + margin-bottom: 0 ! important } + +.hidden { + display: none } + +a.toc-backref { + text-decoration: none ; + color: black } + +blockquote.epigraph { + margin: 2em 5em ; } + +dl.docutils dd { + margin-bottom: 0.5em } + +object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] { + overflow: hidden; +} + +/* Uncomment (and remove this text!) to get bold-faced definition list terms +dl.docutils dt { + font-weight: bold } +*/ + +div.abstract { + margin: 2em 5em } + +div.abstract p.topic-title { + font-weight: bold ; + text-align: center } + +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + margin: 2em ; + border: medium outset ; + padding: 1em } + +div.admonition p.admonition-title, div.hint p.admonition-title, +div.important p.admonition-title, div.note p.admonition-title, +div.tip p.admonition-title { + font-weight: bold ; + font-family: sans-serif } + +div.attention p.admonition-title, div.caution p.admonition-title, +div.danger p.admonition-title, div.error p.admonition-title, +div.warning p.admonition-title { + color: red ; + font-weight: bold ; + font-family: sans-serif } + +/* Uncomment (and remove this text!) to get reduced vertical space in + compound paragraphs. +div.compound .compound-first, div.compound .compound-middle { + margin-bottom: 0.5em } + +div.compound .compound-last, div.compound .compound-middle { + margin-top: 0.5em } +*/ + +div.dedication { + margin: 2em 5em ; + text-align: center ; + font-style: italic } + +div.dedication p.topic-title { + font-weight: bold ; + font-style: normal } + +div.figure { + margin-left: 2em ; + margin-right: 2em } + +div.footer, div.header { + clear: both; + font-size: smaller } + +div.line-block { + display: block ; + margin-top: 1em ; + margin-bottom: 1em } + +div.line-block div.line-block { + margin-top: 0 ; + margin-bottom: 0 ; + margin-left: 1.5em } + +div.sidebar { + margin: 0 0 0.5em 1em ; + border: medium outset ; + padding: 1em ; + background-color: #ffffee ; + width: 40% ; + float: right ; + clear: right } + +div.sidebar p.rubric { + font-family: sans-serif ; + font-size: medium } + +div.system-messages { + margin: 5em } + +div.system-messages h1 { + color: red } + +div.system-message { + border: medium outset ; + padding: 1em } + +div.system-message p.system-message-title { + color: red ; + font-weight: bold } + +div.topic { + margin: 2em } + +h1.section-subtitle, h2.section-subtitle, h3.section-subtitle, +h4.section-subtitle, h5.section-subtitle, h6.section-subtitle { + margin-top: 0.4em } + +h1.title { + text-align: center } + +h2.subtitle { + text-align: center } + +hr.docutils { + width: 75% } + +img.align-left, .figure.align-left, object.align-left { + clear: left ; + float: left ; + margin-right: 1em } + +img.align-right, .figure.align-right, object.align-right { + clear: right ; + float: right ; + margin-left: 1em } + +img.align-center, .figure.align-center, object.align-center { + display: block; + margin-left: auto; + margin-right: auto; +} + +.align-left { + text-align: left } + +.align-center { + clear: both ; + text-align: center } + +.align-right { + text-align: right } + +/* reset inner alignment in figures */ +div.align-right { + text-align: inherit } + +/* div.align-center * { */ +/* text-align: left } */ + +ol.simple, ul.simple { + margin-bottom: 1em } + +ol.arabic { + list-style: decimal } + +ol.loweralpha { + list-style: lower-alpha } + +ol.upperalpha { + list-style: upper-alpha } + +ol.lowerroman { + list-style: lower-roman } + +ol.upperroman { + list-style: upper-roman } + +p.attribution { + text-align: right ; + margin-left: 50% } + +p.caption { + font-style: italic } + +p.credits { + font-style: italic ; + font-size: smaller } + +p.label { + white-space: nowrap } + +p.rubric { + font-weight: bold ; + font-size: larger ; + color: maroon ; + text-align: center } + +p.sidebar-title { + font-family: sans-serif ; + font-weight: bold ; + font-size: larger } + +p.sidebar-subtitle { + font-family: sans-serif ; + font-weight: bold } + +p.topic-title { + font-weight: bold } + +pre.address { + margin-bottom: 0 ; + margin-top: 0 ; + font: inherit } + +pre.literal-block, pre.doctest-block, pre.math, pre.code { + margin-left: 2em ; + margin-right: 2em } + +pre.code .ln { /* line numbers */ + color: grey; +} + +.code { + background-color: #eeeeee +} + +span.classifier { + font-family: sans-serif ; + font-style: oblique } + +span.classifier-delimiter { + font-family: sans-serif ; + font-weight: bold } + +span.interpreted { + font-family: sans-serif } + +span.option { + white-space: nowrap } + +span.pre { + white-space: pre } + +span.problematic { + color: red } + +span.section-subtitle { + /* font-size relative to parent (h1..h6 element) */ + font-size: 80% } + +table.citation { + border-left: solid 1px gray; + margin-left: 1px } + +table.docinfo { + margin: 2em 4em } + +table.docutils { + margin-top: 0.5em ; + margin-bottom: 0.5em } + +table.footnote { + border-left: solid 1px black; + margin-left: 1px } + +table.docutils td, table.docutils th, +table.docinfo td, table.docinfo th { + padding-left: 0.5em ; + padding-right: 0.5em ; + vertical-align: top } + +table.docutils th.field-name, table.docinfo th.docinfo-name { + font-weight: bold ; + text-align: left ; + white-space: nowrap ; + padding-left: 0 } + +h1 tt.docutils, h2 tt.docutils, h3 tt.docutils, +h4 tt.docutils, h5 tt.docutils, h6 tt.docutils { + font-size: 100% } + +ul.auto-toc { + list-style-type: none } + +</style> +<style type="text/css"> + +/* html4css2.css: Cascading style sheet for Docutils' html4strict writer. */ +/* */ +/* :Author: Günter Milde */ +/* :Copyright: © 2009 Günter Milde. */ +/* Released without warranties or conditions of any kind */ +/* under the terms of the Apache License, Version 2.0 */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* This stylesheet supplements the Docutils standard style 'html4css1.css'. */ +/* It uses CSS 2.1 elements (supported by up-to-date versions of popular */ +/* browsers). */ + +/* General rules */ +/* ============= */ + +body { + padding: 0 5%; + margin: 8px 0; + line-height:1.3; + /* http://ilovetypography.com/2008/02/28/a-guide-to-web-typography/ + recommends "line-spacing that’s at least 140% of your text size" */ + counter-reset: table; + /* counter-reset: figure; */ +} + +/* avoid long lines --> better reading */ +/* OTOH: lines should not be too short because of missing hyphenation, */ +div.document { + max-width: 45em; + margin: auto; +} + +/* separate items except for compact lists */ +dl > dd { + margin-bottom: 1em; +} +.compact li, .compact p, .compact ul, .compact ol +dl.simple > dd, .simple li, .simple p, .simple ul, .simple ol { + margin-top: 0; + margin-bottom: 0; +/* background: magenta; */ +} +dl.simple, dl.compact, dl.simple > dd, dl.compact > dd { + margin-top: 0; + margin-bottom: 0; +/* background: lightgreen; */ +} + +/* space around paragraphs */ +dl > dd p:first-child, td > p { + margin: 0; +} + +/* Sidebar */ +/* ------- */ + +div.sidebar { + margin-right: -5%; +} + +/* Special definition lists */ +/* ======================== */ + +/* bold definition term on the same line as the label */ +dl.field-list > dt, dl.option-list > dt, dl.docinfo > dt, +dl.footnote > dt, dl.citation > dt, dl.description > dt { + clear: left; + float: left; + margin: 0; + padding: 0; + padding-right: 0.5em; + font-weight: bold; +} +/* except for these */ +dl.option-list > dt, dl.footnote > dt { + font-weight: normal; +} + + + +/* Field Lists */ +/* ----------- */ + +/* field names followed by a colon */ +dl.field-list > dt:after, dl.docinfo > dt:after { + content: ":"; +} + +/* Offset for field content (corresponds to the --field-name-limit option) */ +dl.field-list > dd { + margin-left: 9em; /* ca. 14 chars in the test examples */ + padding-left: 0.5em; +} + +/* start field-body on a new line after long field names */ +dl.field-list > dd p { + width: 100%; +/* display: inline-block; */ +/* background: yellow; */ +} + +dl.field-list > dd > p:first-child, +/* dl.field-list > dd > ol:first-child, */ +/* dl.field-list > dd > ul:first-child, */ +dl.field-list > dd > dl:first-child { + display: inline-block; +} + +/* field-list variants:: */ + +/* example for custom field-name width */ +dl.field-list.narrow > dd { + margin-left: 5em; +} + +/* start field-body on same line after long field names */ +dl.field-list.run-in > dd p { + display: block; +} + +/* wrap or truncate long field names */ +dl.field-list.fix-labelwidth > dt { + width: 8em; /* set to dl.field-list > dd margin-left - padding-left */ + overflow: hidden; +} +dl.field-list.fix-labelwidth > dd:after { + /* a "stopper" to prevent next dd floating up too far */ + content: ''; + display: block; + clear: left; +} + +/* docinfo */ + +dl.docinfo > dd { + margin-left: 8em; +/* margin-bottom: 0.5em; */ +} + + +/* option list */ + +dl.option-list { + margin-left: 1em; + padding-left: 0; +} + +dl.option-list > dd { + margin-left: 8em; + /* margin-bottom: 0.5em; */ +} + +/* start description on a new line after long options */ +dl.option-list > dd p { + width: 100%; + display: inline-block; +} + +/* footnotes */ + +a.footnote-reference, a.fn-backref { + text-decoration: inherit; /* do not underline footnote links */ +} + +dl.footnote { + /* line on the left */ + padding-left: 1ex; + border-left: solid; + border-left-width: thin; + /* border-color: black; */ +} + +/* paragraph on same line as backrefs */ +dd > em { +/* background: green; */ + float: left; + margin-right: 1ex +} + + +/* +Ordered List (Enumeration) +-------------------------- + +Use counters to replace the deprecated start attribute. Make sure the +resulting list resembles the list-style 'outside' with a hanging indent. +*/ + +/* New ordered list: reset counter, suppress the default label */ +ol, ol.arabic, ol.loweralpha, ol.upperalpha, +ol.lowerroman, ol.upperroman { + counter-reset: item; + list-style: none +} + +/* Set the negative indent of the list label as feature of the list item */ +ol > li { + text-indent: -40px; /* Mozillas default indent */ +} +/* reset for child elements */ +ol > li > * { + text-indent: 0px; + text-indent: 0; + margin-top: 0; + /* background: lightgreen; */ +} + +/* Label */ +ol > li:before { + /* increment and typeset counter(s), */ + counter-increment: item; + content: counter(item) "."; + /* display next to the content (aligned top-right), */ + display: inline-block; + text-align: right; + vertical-align: top; + /* sum must match ol>li {text-indent:} (40px is Mozillas default) */ + width: 35px; + padding-right: 5px; +/* background: yellow; */ +} + +/* The list item's first line starts next to the label, without indent */ +ol > li > p:first-child, +ol > li > ol:first-child, +ol > li > ul:first-child, +ol > li > dl:first-child { + display: inline-block; + /* background: lightblue; */ +} + +/* default separator variants */ +ol.loweralpha > li:before { + content: counter(item, lower-alpha) ")"; +} +ol.upperalpha > li:before { + content: counter(item, upper-alpha) "."; +} +ol.lowerroman > li:before { + content: "(" counter(item, lower-roman) ")"; +} +ol.upperroman > li:before { + content: counter(item, upper-roman) ")"; +} +/* nested counters (1, 1.1, 1.1.1, etc) */ +/* nested enumerated lists "inherit" the class attribute, other lists not */ +ol.nested > li:before, ol.nested ol > li:before { + content: counters(item, ".") " "; +} + +/* lists nested in definition list */ + +dd > ul, dd > ol { + padding-left: 0pt; +} + +/* TODO: prefix, suffix? */ + +/* smaller font for super- and subscripts */ +/* sub, sup {font-size: 70%;} */ /* Mozilla default is `smaller` */ + + +/* Tables */ +/* ====== */ + +/* margins and borders for "normal" tables */ +table { +/* background: magenta; */ + margin-top: 1em ; + margin-bottom: 1em; +/* border-style: outset; */ + border-style: solid; + border-color: silver; + border-width: thin; + border-collapse: collapse; +} +blockquote > table { + margin-top: 0em ; + margin-bottom: 0em; +} + +td, th { + border-style: solid; + border-width: thin; + border-color: silver; + /* text-align: left; */ + padding: 0 1ex; +} + +td > p:first-child, th > p:first-child { + margin-top: 0; +} +td > p, th > p { + margin-bottom: 0; +} + +/* no borders for "borderless" tables */ +table.borderless, table.borderless * { + border-style: none; +} + +/* "booktabs" style (no vertical lines) */ +table.booktabs { + border: 0; + border-top: 2px solid; + border-bottom: 2px solid; +} + +table.booktabs * { + border: 0; +} +table.booktabs th { + border-bottom: thin solid; +} + +table > caption { + text-align: left; + margin-bottom: 0.25em +/* padding: 2em 0 1em 0; */ +} + +/* numbered tables*/ +table.numbered > caption:before { + counter-increment: table; /* defined/re-set in body */ + content: "Table " counter(table) ": "; + font-weight: bold; +} + + +/* literal text + ------------ +*/ +/* whitespace and wrapping in inline literals */ +/* possible values: normal, nowrap, pre, pre-wrap, pre-line */ +tt.literal { + white-space: pre-wrap; +} + +/* /* compensate for initial line-break (which is literal with XHTML 1.1) */ */ +/* pre.literal-block, pre.doctest-block { */ +/* margin-top: 0em ; */ +/* } */ + +/* Table of Contents */ + +/* don't indent like a topic */ +div.topic.contents { + margin: 0; +} +/* div.topic.contents ul { */ +/* list-style: none; */ +/* } */ + +div.topic.contents a { + text-decoration: none; /* no underline for links */ +} + +/* section numbers */ + +span.sectnum { + padding-right: 1ex; +} + +/* admonitions */ + +/* no padding for top and bottom */ +div.admonition, div.attention, div.caution, div.danger, div.error, +div.hint, div.important, div.note, div.tip, div.warning { + padding: 0px 1em } + +</style> +<style type="text/css"> + +/* Stylesheet for isomath documentation +:Copyright: 2008 G. Milde + This stylesheet is released under the GPL v. 2 +*/ + +dl.docutils dt { font-weight: bold; } + +/* docinfo */ + +dl.docinfo > dt { display: none; } +dl.docinfo > dd { + margin-left: 0; + padding: 0 5%; +} +dl.docinfo > dt.author + dd { + font-size: larger; + text-align: center; + padding-bottom: 1em; +} +dt.date { + display: none; +} +dt.date + dd { + font-weight: bold; + text-align: center; + padding-bottom: 1em; +} + +div.abstract { + padding: 0 5%; +} + +a.reference.internal { + text-decoration: none; + color: darkblue; +} + +a.reference.external { + text-decoration: underline; +} + +/* a.reference.external:after { */ +/* content: "⎘"; */ +/* font-size: x-small; */ +/* vertical-align: super; */ +/* } */ + +dl.footnote > dd { + margin-left: 1.2em; +} +dl.footnote > dt { + font-size: small; + vertical-align: super; +} + +a.footnote-reference > sup { + font-size: small; + vertical-align: super; + } + +td, th { + padding-bottom: 0.1ex; + padding-top: 0.1ex; +} + +/* let borderless overreide booktab */ +.booktabs.borderless, +table.booktabs.borderless td, table.booktabs.borderless th { + border: 0; + margin-left: 2em; + } + +table.docutils td, table.docutils th, + vertical-align: bottom; } + +</style> +</head> +<body> +<div class="document" id="isomath"> +<h1 class="title">isomath</h1> +<h2 class="subtitle" id="mathematical-style-for-science-and-technology">Mathematical style for science and technology</h2> + +<dl class="docinfo"> +<dt class="date">Date</dt> +<dd class="date">2012-09-10</dd> +<dt class="copyright">Copyright</dt> +<dd class="copyright">© 2008, 2012 Günter Milde</dd> +<dt>Licence</dt> +<dd><p>This work may be distributed and/or modified under the +conditions of the <a class="reference external" href="http://www.latex-project.org/lppl.txt">LaTeX Project Public License</a>, either +version 1.3 of this license or (at your option) any later version.</p> +</dd> +<dt>Identification</dt> +<dd><pre class="literal-block">\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{isomath} +[2012/09/04 v0.6.1 ISO math style] +</pre> +</dd> +</dl> +<div class="abstract topic"> +<p class="topic-title first">Abstract</p> +<p>The <cite>isomath</cite> package provides tools for a mathematical style +that conforms to the International Standard ISO 80000-2 and is +common in science and technology. It changes the default shape of +capital Greek letters to italic, sets up bold italic and +sans-serif bold italic math alphabets with Latin and Greek +characters, and defines macros for markup of vector, matrix and +tensor symbols.</p> +</div> +<div class="contents topic" id="contents"> +<p class="topic-title first">Contents</p> +<ul class="simple"> +<li><p><a class="reference internal" href="#history" id="id4">History</a></p></li> +<li><p><a class="reference internal" href="#requirements" id="id5">Requirements</a></p> +<ul> +<li><p><a class="reference internal" href="#fixmath-sty" id="id6">fixmath.sty</a></p></li> +<li><p><a class="reference internal" href="#kvoptions-sty" id="id7">kvoptions.sty</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#options" id="id8">Options</a></p> +<ul> +<li><p><a class="reference internal" href="#rmdefault" id="id9">rmdefault</a></p></li> +<li><p><a class="reference internal" href="#sfdefault" id="id10">sfdefault</a></p></li> +<li><p><a class="reference internal" href="#scaled" id="id11">scaled</a></p></li> +<li><p><a class="reference internal" href="#reusemathalphabets" id="id12">reuseMathAlphabets</a></p></li> +<li><p><a class="reference internal" href="#omlmath" id="id13">OMLmath*</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#declarations" id="id14">Declarations</a></p> +<ul> +<li><p><a class="reference internal" href="#math-alphabets" id="id15">Math alphabets</a></p> +<ul> +<li><p><a class="reference internal" href="#mathbfit" id="id16">mathbfit</a></p></li> +<li><p><a class="reference internal" href="#mathsfit" id="id17">mathsfit</a></p></li> +<li><p><a class="reference internal" href="#mathsfbfit" id="id18">mathsfbfit</a></p></li> +<li><p><a class="reference internal" href="#redefine-standard-alphabets" id="id19">Redefine standard alphabets</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#command-aliases" id="id20">Command aliases</a></p> +<ul> +<li><p><a class="reference internal" href="#vectorsym" id="id21">\vectorsym</a></p></li> +<li><p><a class="reference internal" href="#matrixsym" id="id22">\matrixsym</a></p></li> +<li><p><a class="reference internal" href="#tensorsym" id="id23">\tensorsym</a></p></li> +</ul> +</li> +<li><p><a class="reference internal" href="#font-setup-fixes" id="id24">Font setup fixes</a></p> +<ul> +<li><p><a class="reference internal" href="#unknown-makro-in-font-definition-file" id="id25">Unknown makro in font definition file</a></p></li> +<li><p><a class="reference internal" href="#common-family-name-for-text-and-math-fonts" id="id26">Common family name for text and math fonts</a></p></li> +<li><p><a class="reference internal" href="#scaling" id="id27">Scaling</a></p></li> +</ul> +</li> +</ul> +</li> +<li><p><a class="reference internal" href="#references" id="id28">References</a></p></li> +</ul> +</div> +<div class="section" id="history"> +<h1><a class="toc-backref" href="#id4">History</a></h1> +<table class="borderless booktabs numbered align-left"> +<colgroup> +<col width="7%" /> +<col width="15%" /> +<col width="78%" /> +</colgroup> +<tbody> +<tr><td><p>0.1</p></td> +<td><p>2008-09-25</p></td> +<td><p>first public version.</p></td> +</tr> +<tr><td><p>0.2</p></td> +<td><p>2008-10-02</p></td> +<td><p>bugfix: a usage example was uncommented;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>updated documentation;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>define mathsans only if OMLmathsans is true;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>option reuseMathalphabets -> reuseMathAlphabets.</p></td> +</tr> +<tr><td><p>0.3</p></td> +<td><p>2009-06-19</p></td> +<td><p>documentation update;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>fix OMLmathrm and OMLmathsans definitions;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>switch license to LPP.</p></td> +</tr> +<tr><td><p>0.4</p></td> +<td><p>2010-08-23</p></td> +<td><p>split user documentation from literate source;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>option <tt class="literal">scaled</tt>;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>documentation update.</p></td> +</tr> +<tr><td><p>0.5</p></td> +<td><p>2011-01-04</p></td> +<td><p>math alphabet names matching Unicode;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>documentation review and extension;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>bold alphabet variants in <tt class="literal">bold</tt> math version;</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>upright numbers with <tt class="literal">\vectorsym</tt>.</p></td> +</tr> +<tr><td><p>0.6</p></td> +<td><p>2012-09-10</p></td> +<td><p>Scaling for Kepler Sans (<tt class="literal">sfdefault=jkpss</tt>);</p></td> +</tr> +<tr><td><p></p></td> +<td> </td> +<td><p>documentation update, new caption and abstract.</p></td> +</tr> +</tbody> +</table> +</div> +<div class="section" id="requirements"> +<h1><a class="toc-backref" href="#id5">Requirements</a></h1> +<div class="section" id="fixmath-sty"> +<h2><a class="toc-backref" href="#id6">fixmath.sty</a></h2> +<p>The package <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a> by Walter Schmidt defines Greek letters as symbols +of type <tt class="literal">\mathalpha</tt> and takes them from the <tt class="literal">letters</tt> symbol font in +<tt class="literal">\mathnormal</tt> (as opposed to <tt class="literal">operators</tt> in <tt class="literal">fontmath.ltx</tt>).</p> +<p><cite>fixmath</cite> also defines the <tt class="literal">\mathbold</tt> alphabet, setting it to <tt class="literal">cmm</tt>. +<cite>isomath</cite> overwrites this definition with a configurable value for +the font family.</p> +<pre class="literal-block">\RequirePackage{fixmath} +</pre> +</div> +<div class="section" id="kvoptions-sty"> +<h2><a class="toc-backref" href="#id7">kvoptions.sty</a></h2> +<p>The <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html">kvoptions</a> package in the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/oberdiek.html">oberdiek</a> bundle facilitates the setup of +package options and provides a key=value interface (based on <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/keyval.html">keyval</a>):</p> +<pre class="literal-block">\RequirePackage{kvoptions} +</pre> +</div> +</div> +<div class="section" id="options"> +<h1><a class="toc-backref" href="#id8">Options</a></h1> +<div class="section" id="rmdefault"> +<h2><a class="toc-backref" href="#id9">rmdefault</a></h2> +<p>Family for roman math fonts. Must be available in OML +encoding. The default is to use the corresponding text font family +(<tt class="literal">\rmdefault</tt>).</p> +<pre class="literal-block">\DeclareStringOption[\rmdefault]{rmdefault} +</pre> +</div> +<div class="section" id="sfdefault"> +<h2><a class="toc-backref" href="#id10">sfdefault</a></h2> +<p>Family for sans-serif math fonts. The default selects <cite>CM Bright</cite>, as +most sans serif fonts are not available in OML encoding:</p> +<pre class="literal-block">\DeclareStringOption[cmbr]{sfdefault} +</pre> +</div> +<div class="section" id="scaled"> +<h2><a class="toc-backref" href="#id11">scaled</a></h2> +<p>The sans-serif fonts, <tt class="literal">fav</tt> (Arev), <tt class="literal">llcmss</tt> (LX Fonts), +<tt class="literal">jkpss</tt> (Kepler Serif) and <tt class="literal">iwona</tt> can be scaled +with the <tt class="literal">scaled</tt> option.</p> +<pre class="literal-block">\DeclareStringOption[1.0]{scaled} +</pre> +</div> +<div class="section" id="reusemathalphabets"> +<h2><a class="toc-backref" href="#id12">reuseMathAlphabets</a></h2> +<p>The definition of new <a class="reference internal" href="#math-alphabets">math alphabets</a> can lead to a “too many math +alphabets used in version normal” error.</p> +<p>As a workaround, this option tells <cite>isomath</cite> to re-use the existing +<tt class="literal">\mathbf</tt> and <tt class="literal">\mathsf</tt> alphabets for <em>italic</em> bold and sans-serif +bold.</p> +<pre class="literal-block">\DeclareBoolOption{reuseMathAlphabets} +</pre> +</div> +<div class="section" id="omlmath"> +<h2><a class="toc-backref" href="#id13">OMLmath*</a></h2> +<p>The following options cause <cite>isomath</cite> to (re)define the corresponding +<a class="reference internal" href="#math-alphabets">math alphabets</a> in OML encoding:</p> +<pre class="literal-block">\DeclareBoolOption{OMLmathrm} +\DeclareBoolOption{OMLmathbf} +\DeclareBoolOption{OMLmathsf} +\DeclareBoolOption{OMLmathsfit} +\DeclareBoolOption{OMLmathtt} +% backwards compatibility option alias +\DeclareVoidOption{OMLmathsans}{\isomath@OMLmathsfittrue} +</pre> +<p>Setting these options enables access to small Greek letters in different +shapes with e.g. <tt class="literal"><span class="pre">\mathrm{\pi}</span></tt> but only <em>if an OML encoded font is +available</em>. Currently, only the <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html">mathdesign</a> fonts support roman in OML +encoding.</p> +<p>With some packages, these options can result in a “too many math alphabets +used in version normal” error.</p> +<hr class="docutils" /> +<p>Process the options with <tt class="literal">kvoptions</tt> extensions:</p> +<pre class="literal-block">\ProcessKeyvalOptions* +</pre> +</div> +</div> +<div class="section" id="declarations"> +<h1><a class="toc-backref" href="#id14">Declarations</a></h1> +<div class="section" id="math-alphabets"> +<h2><a class="toc-backref" href="#id15">Math alphabets</a></h2> +<p>In math, LaTeX uses “absolute” fontnames instead of a selection by +family, shape, and weight because typefaces have a semantic meaning +<a class="citation-reference" href="#fntguide" id="id1">[fntguide]</a>.</p> +<p><cite>isomath</cite> defines a math alphabet for every required font variant and +optionally re-defines the standard math alphabets in <cite>OML</cite> font encoding.</p> +<p>Unfortunately, the number of math alphabets in one math version is +limited to 16, so we have to be careful not to exceed this. The +<tt class="literal">reuseMathAlphabets</tt> option reduces the number of math alphabet +definitions by two, with the side effect of italic shape with +<tt class="literal">\mathbf</tt> and <tt class="literal">\mathsf</tt> commands:</p> +<pre class="literal-block">\ifisomath@reuseMathAlphabets + \PackageWarningNoLine{isomath}{% + Re-using math alphabet `mathsf' for \protect \mathsfbfit + \MessageBreak and `mathbf' for \protect \mathbfit + } +\fi +</pre> +<div class="section" id="mathbfit"> +<h3><a class="toc-backref" href="#id16">mathbfit</a></h3> +<p>The <em>bold italic</em> math alphabet is named <tt class="literal">\mathbfit</tt> like in +<a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html">unicode-math</a> (with an alias <tt class="literal">\mathbold</tt> like in <a class="reference external" href="http://mirror.ctan.org/help/Catalogue/entries/fixmath.html">fixmath</a> and +related packages). With the <a class="reference internal" href="#reusemathalphabets">reuseMathAlphabets</a> option, the roman bold +math alphabet <tt class="literal">\mathbf</tt> is redefined and <tt class="literal">\mathbfit</tt> made an +alias. The series selector <tt class="literal">bx</tt> (bold extended) is used, because it +is better supported than <tt class="literal">b</tt>. (Is there any LaTeX math font +distinguishing between <tt class="literal">b</tt> and <tt class="literal">bx</tt>?)</p> +<pre class="literal-block">\ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathbf}{OML}{\isomath@rmdefault}{bx}{it} + \def\mathbfit{\mathbf} +\else + \DeclareMathAlphabet{\mathbfit}{OML}{\isomath@rmdefault}{bx}{it} +\fi +</pre> +<p>alias (overwriting the definition from fixmath):</p> +<pre class="literal-block">\renewcommand*{\mathbold}{\mathbfit} +</pre> +</div> +<div class="section" id="mathsfit"> +<h3><a class="toc-backref" href="#id17">mathsfit</a></h3> +<p>For <em>sans-serif italic</em>, we define a new alphabet <tt class="literal">\mathsfit</tt> (with +the alias <tt class="literal">\mathsans</tt> in analogy to <tt class="literal">\mathbold</tt>). As this typeface +is not required by ISO 80000-2 and TeX limits the number of math alphabets +to 16 per math version, it is only defined if the <tt class="literal">OMLmathsfit</tt> or +<tt class="literal">OMLmathsans</tt> option is set:</p> +<pre class="literal-block">\ifisomath@OMLmathsfit + \DeclareMathAlphabet{\mathsfit}{OML}{\isomath@sfdefault}{m}{it} + \SetMathAlphabet{\mathsfit}{bold}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsans{\mathsfit} +\fi +</pre> +</div> +<div class="section" id="mathsfbfit"> +<h3><a class="toc-backref" href="#id18">mathsfbfit</a></h3> +<p>The <em>sans serif bold italic</em> alphabet is used for tensor symbols. +Following the Unicode naming scheme it is called +<tt class="literal"><span class="pre">\mathsfbfit``(with</span> the backwards compatibility alias <span class="pre">``\mathboldsans</span></tt>). +With the <a class="reference internal" href="#reusemathalphabets">reuseMathAlphabets</a> option, the upright sans serif math +alphabet <tt class="literal">\mathsf</tt> is redefined and <tt class="literal">\mathsfbfit</tt> made an +alias to it:</p> +<pre class="literal-block">\ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathsf}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsfbfit{\mathsf} +\else + \DeclareMathAlphabet{\mathsfbfit}{OML}{\isomath@sfdefault}{bx}{it} +\fi +\def\mathboldsans{\mathsfbfit} +</pre> +</div> +<div class="section" id="redefine-standard-alphabets"> +<h3><a class="toc-backref" href="#id19">Redefine standard alphabets</a></h3> +<p>Redefine standard alphabets in <cite>OML</cite> font encoding +if the corresponding <a class="reference internal" href="#omlmath">OMLmath*</a> option is true:</p> +<pre class="literal-block">\ifisomath@OMLmathrm + \SetMathAlphabet{\mathrm}{normal}{OML}{\isomath@rmdefault}{m}{n} + \SetMathAlphabet{\mathrm}{bold}{OML}{\isomath@rmdefault}{bx}{n} +\fi +\ifisomath@OMLmathbf + \SetMathAlphabet{\mathbf}{normal}{OML}{\isomath@rmdefault}{bx}{n} +\fi +\ifisomath@OMLmathsf + \SetMathAlphabet{\mathsf}{normal}{OML}{\isomath@sfdefault}{m}{n} + \SetMathAlphabet{\mathsf}{bold}{OML}{\isomath@sfdefault}{bx}{n} +\fi +\ifisomath@OMLmathtt + \SetMathAlphabet{\mathtt}{normal}{OML}{\ttdefault}{m}{n} + \SetMathAlphabet{\mathtt}{bold}{OML}{\ttdefault}{bx}{n} +\fi +</pre> +</div> +</div> +<div class="section" id="command-aliases"> +<h2><a class="toc-backref" href="#id20">Command aliases</a></h2> +<p>The following macros allow semantic markup of mathematical symbols. +The argument is typeset as proposed by ISO 80000-2 and +<a class="reference external" href="http://physics.nist.gov/cuu/pdf/typefaces.pdf">Typefaces for Symbols in Scientific Manuscripts</a>.</p> +<div class="section" id="vectorsym"> +<h3><a class="toc-backref" href="#id21">\vectorsym</a></h3> +<p>Alphabetic vectors symbols are typeset <em>boldface italic</em> while numeric +ones (e.g. zero vector) are typeset <em>boldface upright</em>. The number +test is a simplified version from the LaTeX FAQ "<a class="reference external" href="http://www.tex.ac.uk/cgi-bin/texfaq2html?label=isitanum">Is the argument a number?</a>" +It fails if a number is followed by a non-number, e.g. <tt class="literal">\vectorsym{1a}</tt>, +but this is no valid vector symbol and would look strange with the +<tt class="literal">\vec</tt> accent, too.</p> +<pre class="literal-block">\providecommand*{\vectorsym}[1]{% + \ifnum9<1#1% + \mathbf{#1}% + \else% + \mathbfit{#1}% + \fi} +</pre> +<p>For easier writing or to make existing documents conform to the standard, +you might want to re-define the standard <tt class="literal">\vec</tt> command after loading this +package.</p> +</div> +<div class="section" id="matrixsym"> +<h3><a class="toc-backref" href="#id22">\matrixsym</a></h3> +<p>Symbols for matrices are typeset <em>boldface italic</em>, i. e. in the same face +as vectors.</p> +<pre class="literal-block">\providecommand*{\matrixsym}{\vectorsym} +</pre> +</div> +<div class="section" id="tensorsym"> +<h3><a class="toc-backref" href="#id23">\tensorsym</a></h3> +<p>Symbols for tensors are <em>sans-serif bold italic</em>:</p> +<pre class="literal-block">\providecommand*{\tensorsym}{\mathsfbfit} +</pre> +</div> +</div> +<div class="section" id="font-setup-fixes"> +<h2><a class="toc-backref" href="#id24">Font setup fixes</a></h2> +<p>Substitutions needed for the math alphabet definitions and setup for +scaled fonts. For details about the font definition macros see +<a class="citation-reference" href="#fntguide" id="id3">[fntguide]</a>.</p> +<div class="section" id="unknown-makro-in-font-definition-file"> +<h3><a class="toc-backref" href="#id25">Unknown makro in font definition file</a></h3> +<p>The <cite>Kepler Sans</cite> font definition file <tt class="literal">omljkpss.fd</tt> contains a boolean +that is defined in <tt class="literal">kpfonts.sty</tt>. This leads to errors if the fonts are +used from another package. Provide a dummy definition:</p> +<pre class="literal-block">\newif\ifkp@upRm +</pre> +</div> +<div class="section" id="common-family-name-for-text-and-math-fonts"> +<h3><a class="toc-backref" href="#id26">Common family name for text and math fonts</a></h3> +<p>Some font packages provide matching text and math font but do not +define a substitution in their <tt class="literal">*.fd</tt> files. Ideally, the following +mappings should be moved there.</p> +<p>Mathpazo (Palatino) ppl ↔ zplm</p> +<pre class="literal-block">\DeclareFontFamily{OML}{ppl}{\skewchar\font127} +\DeclareFontShape{OML}{ppl}{m}{it}{<-> ssub * zplm/m/it}{} +\DeclareFontShape{OML}{ppl}{bx}{it}{<-> ssub * zplm/b/it}{} +</pre> +</div> +<div class="section" id="scaling"> +<h3><a class="toc-backref" href="#id27">Scaling</a></h3> +<p>Scale the <tt class="literal">fav</tt> (Arev), <tt class="literal">iwona</tt>, <tt class="literal">jkpss</tt> (Kepler Sans) and +<tt class="literal">llcmss</tt> (LX Fonts) sans serif fonts by the value of the <a class="reference internal" href="#scaled">scaled</a> option.</p> +<p>To get scaled versions of a font, you cannot use the <tt class="literal">ssub</tt> +<cite>size function</cite>, but must use the empty function or <tt class="literal">s</tt> with the font +file as argument [found by experiment, GM 2010-01-28].</p> +<p>Arev (see <tt class="literal">omlzavm.fd</tt>) fav ↔ zavm:</p> +<pre class="literal-block">\DeclareFontFamily{OML}{fav}{\skewchar\font127} +\DeclareFontShape{OML}{fav}{m}{it}{<-> s * [\isomath@scaled] zavmri7m}{} +\DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [\isomath@scaled] zavmbi7m}{} +</pre> +<p>Iwona (see <tt class="literal">omliwona.fd</tt>) iwona ↔ mi-iwona:</p> +<pre class="literal-block">\DeclareFontFamily{OML}{iwona}{} +\DeclareFontShape{OML}{iwona}{m}{it}{<-> s * [\isomath@scaled] mi-iwonari}{} +\DeclareFontShape{OML}{iwona}{bx}{it}{<-> s * [\isomath@scaled] mi-iwonabi}{} +</pre> +<p>Kepler Serif (see <tt class="literal">omljkpss.fd</tt>):</p> +<pre class="literal-block">\DeclareFontFamily{OML}{jkpss}{\skewchar\font127 } +\DeclareFontShape{OML}{jkpss}{m}{it}{<-> s * [\isomath@scaled] jkpssmi}{} +\DeclareFontShape{OML}{jkpss}{bx}{it}{<-> s * [\isomath@scaled] jkpssbmi}{} +</pre> +<p>LX Fonts (see <tt class="literal">lxfonts.sty</tt>) llcmss ↔ llcmm:</p> +<pre class="literal-block">\DeclareFontFamily{OML}{llcmss}{\skewchar\font'177} +\DeclareFontShape{OML}{llcmss}{m}{it}{<-> s * [\isomath@scaled] lcmmi8}{} +\DeclareFontShape{OML}{llcmss}{bx}{it}{<-> s * [\isomath@scaled] lcmmib8}{} +</pre> +</div> +</div> +</div> +<div class="section" id="references"> +<h1><a class="toc-backref" href="#id28">References</a></h1> +<dl class="citation"><dt class="label">[fntguide]</dt> +<dd id="fntguide"> +<em>(<a class="fn-backref" href="#id1">1</a>, <a class="fn-backref" href="#id3">2</a>)</em> <p class="last"><cite>LaTeX 2e font selection</cite>: +<a class="reference external" href="http://mirror.ctan.org/macros/latex/doc/fntguide.pdf">http://mirror.ctan.org/macros/latex/doc/fntguide.pdf</a>.</p> +</dd> +</dl> +</div> +</div> +</body> +</html> diff --git a/macros/latex/contrib/isomath/isomath.sty.txt b/macros/latex/contrib/isomath/isomath.sty.txt new file mode 100644 index 0000000000..bff0572022 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.sty.txt @@ -0,0 +1,372 @@ +isomath +******* +Mathematical style for science and technology +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +:Date: 2012-09-10 +:Copyright: © 2008, 2012 Günter Milde +:Licence: This work may be distributed and/or modified under the + conditions of the `LaTeX Project Public License`_, either + version 1.3 of this license or (at your option) any later version. + +:Abstract: The `isomath` package provides tools for a mathematical style + that conforms to the International Standard ISO 80000-2 and is + common in science and technology. It changes the default shape of + capital Greek letters to italic, sets up bold italic and + sans-serif bold italic math alphabets with Latin and Greek + characters, and defines macros for markup of vector, matrix and + tensor symbols. + +:Identification: + :: + + \NeedsTeXFormat{LaTeX2e} + \ProvidesPackage{isomath} + [2012/09/04 v0.6.1 ISO math style] + +.. contents:: + +History +======= + +.. class:: borderless + +===== =========== ======================================================== +0.1 2008-09-25 first public version. +0.2 2008-10-02 bugfix: a usage example was uncommented; +\ updated documentation; +\ define \mathsans only if OMLmathsans is true; +\ option reuseMathalphabets -> reuseMathAlphabets. +0.3 2009-06-19 documentation update; +\ fix OMLmathrm and OMLmathsans definitions; +\ switch license to LPP. +0.4 2010-08-23 split user documentation from literate source; +\ option ``scaled``; +\ documentation update. +0.5 2011-01-04 math alphabet names matching Unicode; +\ documentation review and extension; +\ bold alphabet variants in ``bold`` math version; +\ upright numbers with ``\vectorsym``. +0.6 2012-09-10 Scaling for Kepler Sans (``sfdefault=jkpss``); +\ documentation update, new caption and abstract. +===== =========== ======================================================== + + +Requirements +============ + +fixmath.sty +----------- +The package fixmath_ by Walter Schmidt defines Greek letters as symbols +of type ``\mathalpha`` and takes them from the ``letters`` symbol font in +``\mathnormal`` (as opposed to ``operators`` in ``fontmath.ltx``). + +`fixmath` also defines the ``\mathbold`` alphabet, setting it to ``cmm``. +`isomath` overwrites this definition with a configurable value for +the font family. :: + + \RequirePackage{fixmath} + + +kvoptions.sty +------------- +The kvoptions_ package in the oberdiek_ bundle facilitates the setup of +package options and provides a key=value interface (based on keyval_):: + + \RequirePackage{kvoptions} + + +Options +======= + +rmdefault +--------- +Family for roman math fonts. Must be available in OML +encoding. The default is to use the corresponding text font family +(``\rmdefault``). :: + + \DeclareStringOption[\rmdefault]{rmdefault} + +sfdefault +--------- +Family for sans-serif math fonts. The default selects `CM Bright`, as +most sans serif fonts are not available in OML encoding:: + + \DeclareStringOption[cmbr]{sfdefault} + +scaled +------ +The sans-serif fonts, ``fav`` (Arev), ``llcmss`` (LX Fonts), +``jkpss`` (Kepler Serif) and ``iwona`` can be scaled +with the ``scaled`` option. :: + + \DeclareStringOption[1.0]{scaled} + +reuseMathAlphabets +------------------ +The definition of new `math alphabets`_ can lead to a “too many math +alphabets used in version normal” error. + +As a workaround, this option tells `isomath` to re-use the existing +``\mathbf`` and ``\mathsf`` alphabets for *italic* bold and sans-serif +bold. :: + + \DeclareBoolOption{reuseMathAlphabets} + +OMLmath* +-------- +The following options cause `isomath` to (re)define the corresponding +`math alphabets`_ in OML encoding:: + + \DeclareBoolOption{OMLmathrm} + \DeclareBoolOption{OMLmathbf} + \DeclareBoolOption{OMLmathsf} + \DeclareBoolOption{OMLmathsfit} + \DeclareBoolOption{OMLmathtt} + % backwards compatibility option alias + \DeclareVoidOption{OMLmathsans}{\isomath@OMLmathsfittrue} + +Setting these options enables access to small Greek letters in different +shapes with e.g. ``\mathrm{\pi}`` but only *if an OML encoded font is +available*. Currently, only the mathdesign_ fonts support roman in OML +encoding. + +With some packages, these options can result in a “too many math alphabets +used in version normal” error. + +-------------------------------------------------------- + +Process the options with ``kvoptions`` extensions:: + + \ProcessKeyvalOptions* + + +Declarations +============ + +Math alphabets +-------------- + +In math, LaTeX uses “absolute” fontnames instead of a selection by +family, shape, and weight because typefaces have a semantic meaning +[fntguide]_. + +`isomath` defines a math alphabet for every required font variant and +optionally re-defines the standard math alphabets in `OML` font encoding. + +Unfortunately, the number of math alphabets in one math version is +limited to 16, so we have to be careful not to exceed this. The +``reuseMathAlphabets`` option reduces the number of math alphabet +definitions by two, with the side effect of italic shape with +``\mathbf`` and ``\mathsf`` commands:: + + \ifisomath@reuseMathAlphabets + \PackageWarningNoLine{isomath}{% + Re-using math alphabet `mathsf' for \protect \mathsfbfit + \MessageBreak and `mathbf' for \protect \mathbfit + } + \fi + +mathbfit +~~~~~~~~ +The *bold italic* math alphabet is named ``\mathbfit`` like in +unicode-math_ (with an alias ``\mathbold`` like in fixmath_ and +related packages). With the reuseMathAlphabets_ option, the roman bold +math alphabet ``\mathbf`` is redefined and ``\mathbfit`` made an +alias. The series selector ``bx`` (bold extended) is used, because it +is better supported than ``b``. (Is there any LaTeX math font +distinguishing between ``b`` and ``bx``?) :: + + \ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathbf}{OML}{\isomath@rmdefault}{bx}{it} + \def\mathbfit{\mathbf} + \else + \DeclareMathAlphabet{\mathbfit}{OML}{\isomath@rmdefault}{bx}{it} + \fi + +alias (overwriting the definition from fixmath):: + + \renewcommand*{\mathbold}{\mathbfit} + +mathsfit +~~~~~~~~ +For *sans-serif italic*, we define a new alphabet ``\mathsfit`` (with +the alias ``\mathsans`` in analogy to ``\mathbold``). As this typeface +is not required by ISO 80000-2 and TeX limits the number of math alphabets +to 16 per math version, it is only defined if the ``OMLmathsfit`` or +``OMLmathsans`` option is set:: + + \ifisomath@OMLmathsfit + \DeclareMathAlphabet{\mathsfit}{OML}{\isomath@sfdefault}{m}{it} + \SetMathAlphabet{\mathsfit}{bold}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsans{\mathsfit} + \fi + +mathsfbfit +~~~~~~~~~~~~ +The *sans serif bold italic* alphabet is used for tensor symbols. +Following the Unicode naming scheme it is called +``\mathsfbfit``(with the backwards compatibility alias ``\mathboldsans``). +With the reuseMathAlphabets_ option, the upright sans serif math +alphabet ``\mathsf`` is redefined and ``\mathsfbfit`` made an +alias to it:: + + \ifisomath@reuseMathAlphabets + \DeclareMathAlphabet{\mathsf}{OML}{\isomath@sfdefault}{bx}{it} + \def\mathsfbfit{\mathsf} + \else + \DeclareMathAlphabet{\mathsfbfit}{OML}{\isomath@sfdefault}{bx}{it} + \fi + \def\mathboldsans{\mathsfbfit} + +Redefine standard alphabets +~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Redefine standard alphabets in `OML` font encoding +if the corresponding `OMLmath*`_ option is true:: + + \ifisomath@OMLmathrm + \SetMathAlphabet{\mathrm}{normal}{OML}{\isomath@rmdefault}{m}{n} + \SetMathAlphabet{\mathrm}{bold}{OML}{\isomath@rmdefault}{bx}{n} + \fi + \ifisomath@OMLmathbf + \SetMathAlphabet{\mathbf}{normal}{OML}{\isomath@rmdefault}{bx}{n} + \fi + \ifisomath@OMLmathsf + \SetMathAlphabet{\mathsf}{normal}{OML}{\isomath@sfdefault}{m}{n} + \SetMathAlphabet{\mathsf}{bold}{OML}{\isomath@sfdefault}{bx}{n} + \fi + \ifisomath@OMLmathtt + \SetMathAlphabet{\mathtt}{normal}{OML}{\ttdefault}{m}{n} + \SetMathAlphabet{\mathtt}{bold}{OML}{\ttdefault}{bx}{n} + \fi + +Command aliases +--------------- + +The following macros allow semantic markup of mathematical symbols. +The argument is typeset as proposed by ISO 80000-2 and +`Typefaces for Symbols in Scientific Manuscripts`_. + +\\vectorsym +~~~~~~~~~~~ +Alphabetic vectors symbols are typeset *boldface italic* while numeric +ones (e.g. zero vector) are typeset *boldface upright*. The number +test is a simplified version from the LaTeX FAQ "`Is the argument a number?`__" +It fails if a number is followed by a non-number, e.g. ``\vectorsym{1a}``, +but this is no valid vector symbol and would look strange with the +``\vec`` accent, too. :: + + \providecommand*{\vectorsym}[1]{% + \ifnum9<1#1% + \mathbf{#1}% + \else% + \mathbfit{#1}% + \fi} + +For easier writing or to make existing documents conform to the standard, +you might want to re-define the standard ``\vec`` command after loading this +package. + +__ http://www.tex.ac.uk/cgi-bin/texfaq2html?label=isitanum + +\\matrixsym +~~~~~~~~~~~ +Symbols for matrices are typeset *boldface italic*, i. e. in the same face +as vectors. :: + + \providecommand*{\matrixsym}{\vectorsym} + +\\tensorsym +~~~~~~~~~~~ +Symbols for tensors are *sans-serif bold italic*:: + + \providecommand*{\tensorsym}{\mathsfbfit} + + +Font setup fixes +---------------- + +Substitutions needed for the math alphabet definitions and setup for +scaled fonts. For details about the font definition macros see +[fntguide]_. + +Unknown makro in font definition file +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +The `Kepler Sans` font definition file ``omljkpss.fd`` contains a boolean +that is defined in ``kpfonts.sty``. This leads to errors if the fonts are +used from another package. Provide a dummy definition:: + + \newif\ifkp@upRm + + +Common family name for text and math fonts +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Some font packages provide matching text and math font but do not +define a substitution in their ``*.fd`` files. Ideally, the following +mappings should be moved there. + +Mathpazo (Palatino) ppl ↔ zplm :: + + \DeclareFontFamily{OML}{ppl}{\skewchar\font127} + \DeclareFontShape{OML}{ppl}{m}{it}{<-> ssub * zplm/m/it}{} + \DeclareFontShape{OML}{ppl}{bx}{it}{<-> ssub * zplm/b/it}{} + + +Scaling +~~~~~~~ +Scale the ``fav`` (Arev), ``iwona``, ``jkpss`` (Kepler Sans) and +``llcmss`` (LX Fonts) sans serif fonts by the value of the scaled_ option. + +To get scaled versions of a font, you cannot use the ``ssub`` +`size function`, but must use the empty function or ``s`` with the font +file as argument [found by experiment, GM 2010-01-28]. + +Arev (see ``omlzavm.fd``) fav ↔ zavm:: + + \DeclareFontFamily{OML}{fav}{\skewchar\font127} + \DeclareFontShape{OML}{fav}{m}{it}{<-> s * [\isomath@scaled] zavmri7m}{} + \DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [\isomath@scaled] zavmbi7m}{} + +Iwona (see ``omliwona.fd``) iwona ↔ mi-iwona:: + + \DeclareFontFamily{OML}{iwona}{} + \DeclareFontShape{OML}{iwona}{m}{it}{<-> s * [\isomath@scaled] mi-iwonari}{} + \DeclareFontShape{OML}{iwona}{bx}{it}{<-> s * [\isomath@scaled] mi-iwonabi}{} + +Kepler Serif (see ``omljkpss.fd``):: + + \DeclareFontFamily{OML}{jkpss}{\skewchar\font127 } + \DeclareFontShape{OML}{jkpss}{m}{it}{<-> s * [\isomath@scaled] jkpssmi}{} + \DeclareFontShape{OML}{jkpss}{bx}{it}{<-> s * [\isomath@scaled] jkpssbmi}{} + +LX Fonts (see ``lxfonts.sty``) llcmss ↔ llcmm:: + + \DeclareFontFamily{OML}{llcmss}{\skewchar\font'177} + \DeclareFontShape{OML}{llcmss}{m}{it}{<-> s * [\isomath@scaled] lcmmi8}{} + \DeclareFontShape{OML}{llcmss}{bx}{it}{<-> s * [\isomath@scaled] lcmmib8}{} + + +References +========== + +.. [fntguide] `LaTeX 2e font selection`: + http://mirror.ctan.org/macros/latex/doc/fntguide.pdf. + +.. _LaTeX Project Public License: http://www.latex-project.org/lppl.txt +.. _arev: http://mirror.ctan.org/help/Catalogue/entries/arev.html +.. _cmbright: http://mirror.ctan.org/help/Catalogue/entries/cmbright.html +.. _fixmath: http://mirror.ctan.org/help/Catalogue/entries/fixmath.html +.. _hvmath: http://mirror.ctan.org/help/Catalogue/entries/hvmath.html +.. _iwona: http://mirror.ctan.org/help/Catalogue/entries/iwona.html +.. _keyval: http://mirror.ctan.org/help/Catalogue/entries/keyval.html +.. _kvoptions: http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html +.. _lxfonts: http://mirror.ctan.org/help/Catalogue/entries/lxfonts.html +.. _mathdesign: http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html +.. _mathematical alphanumeric symbols: + http://www.unicode.org/charts/PDF/U1D400.pdf +.. _oberdiek: http://mirror.ctan.org/help/Catalogue/entries/oberdiek.html +.. _`Typefaces for Symbols in Scientific Manuscripts`: + http://physics.nist.gov/cuu/pdf/typefaces.pdf +.. _unicode-math: + http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html diff --git a/macros/latex/contrib/isomath/isomath.txt b/macros/latex/contrib/isomath/isomath.txt new file mode 100644 index 0000000000..f91e12e667 --- /dev/null +++ b/macros/latex/contrib/isomath/isomath.txt @@ -0,0 +1,1113 @@ +.. -*- rst-mode -*- + +isomath +******* +Mathematical style for science and technology +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +:Author: Günter Milde +:Date: 2012-09-10 +:Copyright: © 2008, 2012 Günter Milde +:Licence: This work may be distributed and/or modified under the + conditions of the `LaTeX Project Public License`_, either + version 1.3 of this license or (at your option) any later version. + +:Abstract: The `isomath` package provides tools for a mathematical style + that conforms to the International Standard ISO 80000-2 and is + common in science and technology. It changes the default shape of + capital Greek letters to italic, sets up bold italic and + sans-serif bold italic math alphabets with Latin and Greek + characters, and defines macros for markup of vector, matrix and + tensor symbols. + +.. contents:: :depth: 2 +.. sectnum:: + + +Features +-------- + +.. How do you write the stress tensor ``$\sigma$`` in a + *sans-serif bold italic* typeface, as recommended by [typefaces]_? + +In their style guides, e. g. [typefaces]_, [checklist]_, [SI]_, +[fonts_for_symbols]_, [Red-Book]_, [Green-Book]_, many international +scientific organisations recommend layout rules for mathematics in line with +the International Standard [ISO-80000-2]_. + +.. admonition:: International standard layout rules + + * The overall rule is that symbols representing physical quantities + (or variables) are italic, but symbols representing units, or + labels, are roman. + + * Symbols for vectors and matrices are bold italic, symbols for tensors + are sans-serif bold italic. + + * The above rules apply equally to letter symbols from the Greek and the + Latin alphabet. + +.. The recommendations in this standard are intended mainly for use in the + natural sciences and technology, but also apply to other areas where + mathematics is used. + +TeX's default mathematical style deviates from this rules in several +points: + +* Capital Greek letters default to upright shape, + +* small Greek letters are excluded from font changes with the `math + alphabet`_ commands, and + +* the ``\vec`` command produces an arrow accent. + + +The `isomath` package implements an `“ISO” math style`_, provides `new math +alphabets`_ with *bold italic* and *sans-serif bold italic* type and macros +for `semantic markup`_ of vector, matrix and tensor symbols. It can be +combined with most packages for mathematical typesetting (see +`<isomath-test.tex>`_ and the sections on alternatives_ and conflicts_). + + +“ISO” math style +~~~~~~~~~~~~~~~~ + +Isomath builds on the package fixmath_ by Walter Schmidt to change the +default mathematics layout to the “ISO” `math style`_: + ++ Capital Greek letters are typeset in italic shape by default. + ++ Both, Greek and Latin letters change shape if a different + `math alphabet`_ is used. + +.. Caution:: + + Be careful with Greek letters in the argument of ``\mathit``, ``\mathrm``, + ``\mathbf``, ``\mathsf``, and ``\mathtt``. By default, these `math + alphabets`_ use text fonts. Fonts in OT1 text font encoding have capital + (but not small) Greek letters at the expected places, T1 encoded text fonts + have no Greek letters at all. + + See the examples_ section on `how to get upright small Greek letters`_ in + mathematical context. + + +New math alphabets +~~~~~~~~~~~~~~~~~~ +`Isomath` defines the new `math alphabets`_: + +.. class:: borderless + +=============== ====================== ================================= +``\mathbfit`` boldface italic vector and matrix symbols +``\mathsfit`` sans-serif italic optional (see OMLmath*_ options) +``\mathsfbfit`` sans-serif bold italic tensor symbols +=============== ====================== ================================= + +For compatibility with earlier versions and `related packages`_, the +new math alphabets are also available under the aliases +``\mathbold``, ``\mathsans``, and ``\mathboldsans``. + +The rmdefault_ and sfdefault_ options_ set the font family used for +these alphabets. + +.. Caution:: + + Using the new math alphabets for numbers can result in upright old-style + numbers instead of italic ones, because some italic math fonts (e. g., + ``cmr``, ``cmbr``) contain old-style in place of italic digits. + + +Semantic markup +~~~~~~~~~~~~~~~ +The following commands set the argument in an ISO-conforming `math alphabet`_: + +.. class:: borderless + +========================== ======================================== +``\vectorsym, \matrixsym`` bold italic for Greek and Latin letters, + bold upright for numbers + +``\tensorsym`` sans-serif bold italic +========================== ======================================== + + +Usage +----- + +Make sure that LaTeX can find ``isomath.sty`` and load it with:: + + \usepackage{isomath} + +Optionally redefine the standard vector macro ``\vec``:: + + \renewcommand{\vec}{\vectorsym} + +(see also Options_, Examples_, and isomath-test.tex_). + +Options +~~~~~~~ + +rmdefault +''''''''' +Family for serif math fonts (``\mathrm``, ``\mathbf``, ``\mathit``, +``\mathbfit``). The default is to use the corresponding text font +family (the value of ``\rmdefault``). The font must be available in +`OML font encoding`_ (cf. `Table 3`_). + + +sfdefault +''''''''' +Family for sans-serif math fonts. The default is ``cmbr`` because most +sans-serif fonts define the Computer Roman font `cmm` as OML substitution +(see `Table 4`_). + +There are only few sans serif fonts in `OML font encoding`_: + +.. class:: borderless + +========== =========== ===================================================== +Name Package Comment +========== =========== ===================================================== +``cmbr`` cmbright_ `Computer Modern Bright`, bitmap, slightly lighter + than cmss (Type 1 fonts with hfbright_) +``fav`` arev_ `Arev` (`Vera Sans`), large x-height +``hvm`` hvmath_ `Helvetica Math`, commercial, free bitmap version +``iwona`` iwona_ `Iwona`, humanistic sans serif, + some shapes very similar to roman +``jkpss`` kpfonts_ `Kepler Sans`, quite light +``llcmss`` lxfonts_ `LX Fonts`, “slide fonts”, very wide, large x-height +========== =========== ===================================================== + + +scaled +'''''' +To improve the chances of finding a matching sans serif math font, the +fonts ``fav``, ``iwona``, ``jkpss``, and ``llcmss`` can be scaled with the +``scaled`` option (cf. Examples_). For other fonts, the option is ignored. + + +reuseMathAlphabets +'''''''''''''''''' +The definition of new math alphabets can lead to a “`too many math +alphabets used in version normal`_” error. As a workaround, this +option tells `isomath` to re-use the existing ``\mathbf`` and +``\mathsf`` alphabets for italic bold and sans-serif bold. [#]_ + +.. [#] To access the upright shapes, the corresponding ``\textbf`` and + ``\textsf`` commands might be used. Watch for side-effects, as these + commands switch to text mode so that the font settings in the embedding + text apply. + +.. _OMLmath*: + +OMLmathrm, OMLmathbf, OMLmathsf, OMLmathsfit, OMLmathtt +''''''''''''''''''''''''''''''''''''''''''''''''''''''' + +The ``OMLmath*`` options bind the corresponding ``\math*`` command to an +OML-encoded font. + +The ``\mathsfit`` alphabet is not required for ISO conforming mathematical +layout and therefore only defined if the ``OMLmathsfit`` argument is used. + +The predefined `math alphabets`_ ``\mathrm``, ``\mathbf``, and ``\mathtt`` +use OT1 encoded text fonts with ligatures and accents in place of the small +Greek letters. The ``OMLmath*`` options enable the use of small Greek +letters in `math alphabet`_ commands, e. g. ``\mathrm{\pi}``, if the +corresponding font is available in `OML font encoding`_. `Table 3`_ lists +font families supporting the OML encoding. + +.. caution:: + + If no matching OML encoded font is found, LaTeX's substitute mechanism + selects a font with different font attributes (for all letters, not only + Greek). Currently, only the mathdesign_ package provides upright fonts in + OML encoding. Many font packages define an *italic* font as OML substitute + for roman fonts. + + With some packages, these options can result in a “`too many math + alphabets used in version normal`_” error. + + +Examples +~~~~~~~~ + +* Use scaled arev_ fonts for the sans serif math alphabets + (adapt the scaling factor to your needs):: + + \usepackage[sfdefault=fav,scaled=0.875]{isomath} + +* Define the ``\mathsfit`` sans-serif italic math alphabet:: + + \usepackage[OMLmathsfit]{isomath} + + +* The ``\mathbfit`` and ``\mathsfbfit`` alphabets do not have a different + weight in the ``bold`` `math version`_ because the number of LaTeX math + fonts providing `extrabold` or `ultrabold` series is negligible. + + As a workaround, use the heavier arev_ font, scaled to 0,875, in the + bold version of ``\mathsfbfit``:: + + \usepackage{isomath} + \DeclareFontShape{OML}{fav}{bx}{it}{<-> s * [0.875] zavmbi7m}{} + \SetMathAlphabet{\mathsfbfit}{bold}{OML}{fav}{bx}{it} + +See also the `isomath-test.tex`_ test document. + + +How to get upright small Greek letters +'''''''''''''''''''''''''''''''''''''' + +Of the following methods, only the first requires `isomath`: + +a) Use `isomath` and the mathdesign_ package:: + + \usepackage[utopia]{mathdesign} + \usepackage[OMLmathrm,OMLmathbf]{isomath} + + Now, e. g., ``\mathrm{\pi}`` and ``\mathbf{\pi}`` work as + expected. + +b) To get upright small Greek letters without affecting other fonts, + set the math alphabet manually to one of the three mathdesign_ + fonts, e. g.:: + + \SetMathAlphabet{\mathbf}{normal}{OML}{mdput}{b}{n} + + (check if the letter shapes match with the rest of the document). + +c) Use a package that provides macros for upright Greek letters + in math mode: + + .. class:: borderless + + ============= ===================================== + fourier_ ``\otheralpha ... \otherOmega`` + kpfonts_ ``\alphaup ... \Omegaup`` + mathdesign_ ``\alphaup ... \Omegaup`` + upgreek_ ``\upalpha ... \upOmega`` + ============= ===================================== + +d) Use an upright text character (requires a matching LGR-encoded + Greek text font). The following lines redefine ``\pi`` to set + the mathematical constant pi upright:: + + \usepackage[LGR,T1]{fontenc} + \usepackage[greek,british]{babel} + \usepackage{amsmath} + \let\mathpi\pi + \renewcommand{\pi}{\text{\textrm{\greektext p }}} + +e) Use the text character with the `alphabeta` package from the lgrx_ + bundle:: + + \usepackage{amsmath} + \usepackage{alphabeta} + + and in the body :: + + $ u = 2 \text{\pi} r $ + + +Related packages +---------------- + +Requirements +~~~~~~~~~~~~ + +fixmath_ + by Walter Schmidt defines Greek letters as alphabetic symbols. + +kvoptions_ + by Heiko Oberdiek facilitates the setup of package options + and provides a key=value interface (based on keyval_). + + +Recommendations +~~~~~~~~~~~~~~~ + +cmbright_ + by Walter Schmidt provides sans serif and sans-serif bold fonts + for the ``\mathsfit`` and ``\mathsfbfit`` alphabets that match + with Computer Modern and derivatives. Free Type 1 versions of the + fonts are provided by hfbright_. + +arev_ + by Stephen Hartke provides the not-so-light `Arev` sans serif font + with letters that are clearly distinguishable from the roman or + italic counterparts (important if used to distinguish vectors and + tensors). + + `Arev` has a large x-height. For many fonts, either small or capital + letters will not match in size. + + +Alternatives +~~~~~~~~~~~~ + +The TUGboat article by Claudio Beccari [becc97]_ discusses tricks and +commands for physicists and engineers in order to satisfy the international +regulations and to distinguish similar symbols with different meanings. + +See `Table 2`_ for other packages that implement the “ISO” `math style`_ and +`Table 6`_ for packages that provide bold italic math fonts. + +`“In-line math versions”`_ + can be used as ISO-conforming replacement for ``\vec``: + + * ``\bm`` from the `bm`_ package. Combining `bm` and `isomath` may + lead to the `too many math alphabets used in version normal`_ error. + + * ``\boldsymbol`` from `amsbsy`_ (part of `amsmath`_, the + near-indispensable adjunct to serious mathematical typesetting in + LaTeX), + +amsmath_ + provides the command ``\text``, that can be used to get, e. g., upright or + sans-serif bold italic Greek symbols from a text font into a formula (see + `How to get upright small Greek letters`_). + +unicode-math_ + for XeTeX and LuaTeX allows mathematical typesetting using OpenType + math fonts. It supports the “ISO” `math style`_ and all mathematical + characters in the Unicode standard. + + `unicode-math` cannot be used together with `isomath`. It can, however, + replace all of isomath's functionality. See the discussion of `the + unicode-math package`_ below. + + +Conflicts +~~~~~~~~~ + +“_`too many math alphabets used in version normal`” + This error occurs if the combination of packages tries to load more + than 16 fonts into the ``normal`` `math version`_. + + `Isomath` can reduce the number of math alphabet definitions with the + reuseMathAlphabets_ option (see there for side-effects). + + Examples for problematic combinations: + + + The `kpfonts`_, `pxfonts`_, and `txfonts`_ packages define many + additional math alphabets (`kpfonts` works with `isomath`, if + it is loaded with ``\usepackage[nomathscript]{kpfonts}``). + + + The `bm`_ package normally allocates several symbol fonts for bold + and heavy fonts. Their number can be customised by defining + ``\bmmax`` and ``\hmmax`` before loading the package. + +fourier_ + provides upright and italic Greek letters, but uses non-standard + math font encodings. It cannot be used with `isomath`. + + However, it is possible to use the non-alphanumeric symbols from + `fourier`_ together with math alphabets from another package, e.g + `mathdesign`_:: + + \usepackage{fourier} + \usepackage[OMLmathbf,rmdefault=mdput, + sfdefault=arev,scaled=0.85]{isomath} + +sansmath_ + defines a ``sans`` `math version`_ using **text** fonts in OT1 or T1 font + encoding. As fixmath/isomath expect math fonts in `OML font encoding`_, + Greek letters will not work inside the ``sans`` math version defined by + sansmath. + + +Background +---------- + +This section discusses LaTeX `math font selection`_, the `OML font +encoding`_, and the relation of LaTeX and `Unicode mathematical +typesetting`_. + + +Math font selection +~~~~~~~~~~~~~~~~~~~ + +There are three complementary methods to set font attributes in LaTeX +math mode: `LaTeX 2e font selection` [fntguide]_ describes `math +alphabets`_ and `math versions`_, several extension packages +provide alternative `math styles`_. + +.. _math alphabet: + +Math alphabets +'''''''''''''' + +TeX's *math alphabets* correspond to the `mathematical alphanumeric +symbols`_ block in Unicode. Both are “to be used for mathematical +variables where style variations are important semantically”. +The font guide [fntguide]_ defines in +section 3: + + Some math fonts are selected explicitly by one-argument commands + such as ``\mathsf{max}`` or ``\mathbf{vec}``; such fonts are called + *math alphabets*. + + Math fonts [...] have the same five attributes as text fonts: + encoding, family, series, shape and size. However, there are no + commands that allow the attributes to be individually changed. + Instead, the conversion from math fonts to these five attributes is + controlled by the `math version`_. + + The _`predefined math alphabets` are: + + .. class:: borderless + + ================= =============== + ``\mathnormal`` default [#mathnormal]_ + ``\mathrm`` roman [#roman]_ + ``\mathbf`` bold roman + ``\mathsf`` sans serif + ``\mathit`` text italic + ``\mathtt`` typewriter + ``\mathcal`` calligraphic + ================= =============== + +.. [#mathnormal] ``\mathnormal`` is used by default for alphanumeric + characters in math mode. It sets the letter shape according to + character class and `math style`_. (`Table 1`_ shows the default + letter shapes for common math styles). + +.. [#roman] The specifier “roman” is ambiguous: roman shape + stands for *upright*, while roman type stands for *serif* (as + opposed to sans serif). + +Many packages define additional math alphabets (cf. `Table 6`_). + +In contrast to the similar named text commands, math alphabets are +*not* orthogonal, e. g., the code ``$\mathit{\mathbf{a}}$`` sets the +letter ``a`` in **upright** bold type. + + +.. _math version: + +Math versions +''''''''''''' + +*Math versions* specify the mapping from commands for mathematical +symbols and `math alphabets`_ to a set of mathematical fonts [#]_. +They are intended for mathematical content in a special context like a +bold section heading. Selecting a math version resembles +the individual selection of text font attributes. + +Example: + Some alternatives to set the letter ``a`` in a bold upright sans-serif + font: + + .. class:: borderless + + ============================ =================================== + Text Math + ============================ =================================== + ``\textbf{\textsf{a}}`` ``$\bm{\mathsf{a}}$`` + ``\bfseries \textsf{a}`` ``\mathversion{bold} $\mathsf{a}$`` + ``\bfseries \sffamily a`` ``$\mathsfbf{a}$`` + ============================ =================================== + + +The predefined math versions are ``normal`` and ``bold`` with the +following defaults for non-specified font attributes: + +.. class:: borderless + +========= ========== ======== +attribute ``normal`` ``bold`` +========= ========== ======== +*type* serif serif +*weight* medium bold +*shape* upright upright +========= ========== ======== + +Packages can define additional math versions, e. g., the kpfonts_ package +defines a ``sans`` math version (another ``sans`` math version example is +available from a `comp.text.tex post``__) and the wrisym_ package defines a +``mono`` math version. + +__ http://newsgroups.derkeiler.com/Archive/Comp/comp.text.tex/2007-09/msg00181.html + +Math versions can only be changed outside of math mode. The commands +``\boldsymbol`` (amsmath_) and ``\bm`` (bm_) behave like _`“in-line +math versions”`: they typeset their argument using the fonts of the +``bold`` math version but can be used inside math mode. + +.. [#] The number of mathematical symbols exceeds the maximal number of + characters in a TeX font file by an order of magnitude: Unicode + defines about 2500 mathematical characters [tr25]_, font files used by + 8-bit TeX engines are limited to 256 characters. The standard math + fonts adhere to the original limit of 128 characters. Grouping math + fonts with common characteristics in math versions simplifies the + setting of font attributes for mathematical expressions. TeX limits + the number of (symbol + alphanumeric) fonts per math version to 16. + + +.. _math style: + +Math styles +''''''''''' + +A *math style* is a document-level feature that determines the default +letter shape in math mode (i. e. the shape attribute of letters in the +``\mathnormal`` `math alphabet`_). [#]_ +LaTeX defaults to the “TeX” math style (without naming it such). +Alternative math styles are introduced by extension packages +(`Table 2`_). + +.. [#] The ``math-style`` option of unicode-math_ changes also the shape + attribute of other math alphabets (see also section + `the unicode-math package`_). + +.. _ Table 1: + +.. table:: Default letter shapes for common math styles + + ============ ======= ======= ======= ======= + math style latin Latin greek Greek + ============ ======= ======= ======= ======= + TeX it it it up + ISO it it it it + French it up up up + upright up up up up + ============ ======= ======= ======= ======= + + +.. _Table 2: + +.. table:: Packages providing alternative math styles + + ============ ============= ================================== + math style Package Option(s) + ============ ============= ================================== + ISO fixmath_ + .. isomath + .. kpfonts_ slantedGreeks + .. lucimatx_ math-style=iso + .. mathdesign_ greekuppercase=italicized + .. mathpazo_ slantedGreek + .. mathptmx_ slantedGreek + .. unicode-math_ math-style=ISO + + French fourier_ upright + .. kpfonts_ frenchstyle (or upright) + .. lucimatx_ math-style=french + .. mathdesign_ uppercase=upright, greeklowercase=upright + .. unicode-math_ math-style=french + + upright eulervm_ + .. lucimatx_ math-style=upright + .. unicode-math_ math-style=upright + ============ ============= ================================== + + +OML font encoding +~~~~~~~~~~~~~~~~~ + +The equal treatment of Latin and Greek letters in the `“ISO” math +style`_ is best achieved with a font that contains all required +letters in one file. + +There is only one established LaTeX font encoding that contains Latin and +Greek letters, the `OML font encoding`_. The standard Greek font +encoding `T7` is just a “reserved name” and the de-facto standard +Greek text font encoding `LGR` has no Latin letters. Unfortunately, +`OML support`_ is limited to a few (mostly italic) fonts. + +Discussion +'''''''''' + +The `LaTeX font encodings` guide [encguide]_ names the OML encoding +`TeX math italic` and defines: + + The OML encoding contains italic Latin and Greek letters for use in + mathematical formulae (typically used for variables) together with some + symbols. + +The reference to *italic* shape is odd: + +* No other font encoding is specific to a font shape. + +* The different font selection and the semantic of font features in + mathematical formulae do not interfere with the font *encoding*: Both, + ``\DeclareSymbolFont`` and ``\DeclareMathAlphabet`` require a + shape argument. Thus it is possible to set up OML encoded math + alphabets in roman {n} as well as italic {it} shape without + conflicts. + +This seems to be more a remnant of pre-NFSS times than a necessary +restriction – there is only one OML encoded font in Knuth's Computer +Modern fonts: `Computer Modern Math Italic` (cmmi). + +Proposals: + +* Drop the *italic* from the definition. Optionally add an explanation: + + The OML encoding contains Latin and Greek letters for use in + mathematical formulae (typically used for variables) together with + some symbols. It first appeared in the `Computer Modern Math + Italic` (cmmi) font. + +* The name `TeX math italic` can be interpreted as “the encoding + **of** `Computer Modern Math Italic`” rather than “an encoding + **for** math italic” fonts. + + A less confusing name would be `TeX math letters` or `Original/Old + Math Letters`. The latter would also explain the acronym OML. + + +OML Support +''''''''''' + +Unfortunately, support for the OML encoding is missing for many font +families even if the text font defines Greek letters. +Supported font families can be found searching for ``oml*.fd`` files +and grepping for ``DeclareFont.*OML`` in ``*.sty`` files. + +`Table 3`_ lists the findings for a selection of TeXLive 2012 + some +additionally installed font packages. + +* If there is an alias (substitution) from the text font to a + math-variant, only the text font is listed. + +* Many text fonts define substitutions also for upright shape, + however mapping to an italic variant of the OML encoded font. These + are not listed as supporting ``m/n`` or ``bx/n`` here. + +`Table 4`_ lists some fonts that define ``cmm`` as OML substitution. +With `isomath`, a better matching substitution can be set using the +rmdefault_ or sfdefault_ options. + +.. _Table 3: + +.. table:: Font families supporting the OML encoding + + ============= ================================= ======= ======== ====== ======= + Name Family (package) m/it bx/it m/n bx/n + ============= ================================= ======= ======== ====== ======= + antt Antykwa Torunska (anttor_) ✓ ✓ + cmr Computer Modern ✓ ✓ + ccr Concrete Roman (concmath_) ✓ ✓ + cmbr CM Bright (cmbright_) ✓ ✓ + hlh Lucida ✓ ✓ + hfor CM with old-style digits ✓ ✓ + iwona Iwona (sans serif) (iwona_) ✓ ✓ + iwonal Iwona light ✓ ✓ + iwonac Iwona condensed ✓ ✓ + iwonalc Iwona light condensed ✓ ✓ + jkp Kepler Serif (kpfonts_) ✓ ✓ + jkpw Kepler Serif wide ✓ ✓ + jkpvos Kepler Serif oldstyle ✓ ✓ + jkpvosw Kepler Serif oldstyle wide ✓ ✓ + jkpl Kepler Serif light ✓ ✓ + jkplw Kepler Serif light wide ✓ ✓ + jkplvos Kepler Serif light oldstyle ✓ ✓ + jkplvosw Kepler Serif light os wide ✓ ✓ + jkpss Kepler Sans (kpfonts_) ✓ ✓ + jkpssvos Kepler Sans oldstyle ✓ ✓ + jtm expanded Times (jamtimes_) ✓ ✓ + llcmm LX Fonts (sans serif) (lxfonts_) ✓ ✓ + lmr Latin Modern Roman (lmodern) ✓ ✓ + mak Kerkis (kerkis_) ✓ + kurier Kurier (sans serif) (kurier_) ✓ ✓ + kurierc Kurier condensed ✓ ✓ + kurierl Kurier light ✓ ✓ + kurierlc Kurier light condensed ✓ ✓ + mdbch Math Design Charter (mathdesign_) ✓ ✓ ✓ ✓ + mdput Math Design Utopia ✓ ✓ ✓ ✓ + mdugm Math Design Garamond ✓ ✓ ✓ ✓ + neohellenic Neohellenic (gfsneohellenic_) ✓ + ntxmi Times (newtx_) ✓ ✓ + nxlmi Libertine (newtx_) ✓ ✓ + plcm CM (PLaTeX) ✓ + ptmom Times (Omega or MB-Times) ✓ ✓ + ptmomu Times (Omega or MB-Times) ✓ ✓ + ptmcm Times (mathptmx_) ✓ + pxr Palatino (pxfonts_) ✓ ✓ + qpl Palatino/Pagella (qpxmath) ✓ ✓ + qtm Times/Termes (qtxmath) ✓ ✓ + txr Times (txfonts_) ✓ ✓ + udidot Didot (gfsdidot_) ✓ + ywclm (greektex_) ✓ ✓ + zavm Arev (Vera Sans-Serif) ✓ ✓ + zplm Palatino (mathpazo_) ✓ ✓ + zpple Palatino ✓ ✓ + ztmcm Times (mathptmx_) ✓ + zer Computer Modern (zefonts_) ✓ ✓ + ============= ================================= ======= ======== ====== ======= + + +.. _Table 4: + +.. table:: Non-CM fonts with ``cmm`` as OML substitution + + ============= =============================== + Family Name + ============= =============================== + bch Charter (psnfss) + pag Avant Garde (psnfss) + pbk Bookman (psnfss) + pcr Courier (psnfss) + phv Helvetica (psnfss) + pnc New Century Schoolbook (psnfss) + ppl Palatino (psnfss) + ptm Times Roman (psnfss) + put Utopia (psnfss) + pzc Zapf Chancery (psnfss) + uag Avant Garde (avantgar) + ubk Bookman (bookman) + ucr Courier (courier) + ucrs Courier + unc New Century Schoolbook (psnfss) + uni Universal (universa) + uhv Helvetica (helvetic) + upl Palatino (palatino) + utm Times (times) + uzc Zapf Chancery (zapfchan) + ============= =============================== + + +Unicode mathematical typesetting +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +This section compares `math font selection`_ in LaTeX and Unicode. It +suggests a set of 14 math alphabet commands that covers all Unicode +`mathematical alphanumeric symbols`_ and discusses compatibility issues +between math typesetting with traditional (8-bit) TeX engines versus `the +unicode-math package`_ for Unicode-enabled TeX engines (XeTeX, LuaTeX). + +The technical report [tr25]_ presents an in-depth discussion of the +mathematical character repertoire of the Unicode Standard as well as +mathematical notation in general. + +.. _mathematical alphanumeric symbols: + +Unicode mathematical alphabets +'''''''''''''''''''''''''''''' + +Chapter 2 `Mathematical Character Repertoire` of [tr25]_ lists 14 +`Mathematical Alphabets` in Table 2.1. These mathematical alphabets are a +superset of the predefined `math alphabets`_ in the LaTeX core. + +Unicode assigns code points to most letters of the mathematical +alphabets in the `mathematical alphanumeric symbols Unicode block`_. +The plain (upright) letters have been unified with the +existing characters in the Basic Latin and Greek blocks. + +`Table 5`_ maps the 14 Unicode mathematical alphabets to LaTeX commands +according to the `naming scheme`_ below. `Table 6`_ lists the status of +LaTeX support for the mathematical alphanumeric symbols. + +Naming scheme +````````````` + +The naming scheme is an extension of the predefined `math alphabet`_ +commands with the established short-cuts: + +.. class:: borderless + +===== ================================ +bf bold +it italic +cal script (calligraphic) +frak fraktur +bb double-struck (blackboard bold) +sf sans serif +===== ================================ + +combined to commands in the form ``\math<type><weight><shape>``. + +The <*type*>, <*weight*>, and <*shape*> specifiers are optional +(defaults depend on the `math version`_). Their order matches the +names of Unicode `Mathematical Alphanumeric Symbols`_. + +Examples:: + + \mathbf{d} % MATHEMATICAL BOLD SMALL D + \mathsfbfit{d} % MATHEMATICAL SANS-SERIF BOLD ITALIC SMALL D. + +.. _table 5: + +.. table:: Mapping Unicode `mathematical alphanumeric symbols`_ to LaTeX + math alphabets. + + ========== ======== ============= ================== =============== + serifs weight shape symbols math alphabet + ========== ======== ============= ================== =============== + *serif* *medium* *upright* Latin/Greek/digits ``\mathrm`` + [#up]_ + .. bold Latin/Greek/digits ``\mathbf`` + .. italic Latin/Greek ``\mathit`` + .. bold italic Latin/Greek ``\mathbfit`` + .. script Latin ``\mathcal`` + .. bold script Latin ``\mathbfcal`` + .. fraktur Latin ``\mathfrak`` + .. double-struck Latin/digits ``\mathbb`` + .. bold fraktur Latin ``\mathbffrak`` + sans serif Latin/digits ``\mathsf`` + sans serif bold Latin/Greek/digits ``\mathsfbf`` + sans serif italic Latin ``\mathsfit`` + sans serif bold italic Latin/Greek ``\mathsfbfit`` + .. monospace Latin/digits ``\mathtt`` + ========== ======== ============= ================== =============== + +.. [#up] plain standard characters outside the + `mathematical alphanumeric symbols` Unicode block. + +LaTeX support +````````````` + +Most commonly used math alphabets are supported either by the TeX kernel +or additional packages. Full support is only provided by `the unicode-math +package`_. + + +.. _Table 6: + +.. table:: LaTeX support for `mathematical alphanumeric symbols`_. + + ============ ========================= =========================== + style math alphabet package, comment + ============ ========================= =========================== + plain [#up]_ ``\mathrm`` predefined [#no-g]_ + .. ``\mathup`` unicode-math_, kpfonts_ + bf ``\mathbf`` predefined [#no-g]_ + it ``\mathit`` predefined [#no-g]_ + bf it ``\mathbfit`` isomath [#digits]_ + .. ``\mathbold`` fixmath_, mathpazo_, + mathptmx_, tmmath_ + [#digits]_ + .. ``\boldsymbol`` amsmath_ + .. ``\bm`` bm_ + cal ``\mathcal`` predefined [#script]_ + .. ``\mathscr`` mathrsfs_, euscript_, + mathdesign_ + bf cal ``\mathbfscr`` unicode-math_ + frak ``\mathfrak`` amssymb_, amsfonts_, eufrak_ + bf frak ``\mathbffrak`` unicode-math_ + bb ``\mathbb`` amssymb_, bbold_, + mathbbol_, mbboard_, + mathpazo_, sbbm_ + .. ``\mathbbm`` bbm_ + .. ``\mathds`` dsfont (doublestoke_) + sf ``\mathsf`` predefined [#no-g]_ + sf bf ``\mathbfsfup`` unicode-math_ + sf it ``\mathsfit`` isomath [#digits]_ + sf bf it ``\mathsfbfit`` isomath [#digits]_ + .. ``\mathbold`` cmbright_, hvmath_ + .. ``\mathbfsfit`` unicode-math_ + tt ``\mathtt`` predefined [#no-g]_ + ============ ========================= =========================== + +.. [#no-g] no small Greek, full Greek with `OMLmath*`_ options and + OML-encoded fonts +.. [#digits] Some italic math fonts (e. g., cmr, cmbr) have old-style + numbers in place of italic digits. +.. [#script] formal script with calrsfs_, eucal_, fourier_, + small Latin letters only with urwchancal_ + + +The unicode-math package +'''''''''''''''''''''''' + +Users of UTF-8 enabled TeX engines (XeTeX, LuaTeX) can typeset +mathematics with the experimental unicode-math_ package by Will +Robertson. It provides a LaTeX interface to OpenType fonts with math +support, e. g., `Asana Math`_, Cambria Math, `New Euler`_ or XITS_, with +commands to access the complete mathematical character repertoire of the +Unicode Standard. + +LaTeX `math font selection`_ methods with unicode-math: + +* `Math alphabets`_ map to a range of the `mathematical alphanumeric + symbols`_ block in the current font (or a substitution defined with the + ``range`` math font option). + + Some command names differ from the `predefined math alphabets`_ or the + above `naming scheme`_: + + .. class:: borderless + + =============== =============== + LaTeX unicode-math + =============== =============== + ``\mathbf`` ``\mathbfup`` + ``\mathsf`` ``\mathsfup`` + ``\mathsfbf`` ``\mathbfsfup`` + ``\mathsfbfit`` ``\mathbfsfit`` + =============== =============== + + With unicode-math, ``\mathbf``, ``\mathsf``, and ``\mathsfbf`` + behave similar to `“in-line math versions”`_: they consider the + `math style`_ for upright vs. italic shape. Compatibility can be + achieved via the options ``bold-style=upright`` and + ``sans-style=upright``. + + ``\mathbfsfit`` reverses the order of the ``sf`` and ``bf`` selectors, + so that, e. g., the Unicode character MATHEMATICAL SANS-SERIF BOLD + ITALIC CAPITAL A is selected by the non-mnemonic ``\mathbfsfit{A}``. + +* `Math versions`_ can be set up using the syntax + ``\setmathfont[version=<version name>,<font features>]{<font name>}`` + +* Several `math styles`_ are supported with the ``math-style`` package + option that accepts the values ``TeX``, ``ISO``, ``french``, ``upright``, + and ``literal``. + + +Conclusions and outlook +~~~~~~~~~~~~~~~~~~~~~~~ + +It is hoped, that in the future more font families will support the +OML encoding in normal and bold weight as well as upright and italic +shape. This would be a major step towards a LaTeX equivalent of the +`mathematical alphanumeric symbols`_ Unicode block. + +This should be (relatively) easy to achieve via virtual fonts when the +glyphs for the Greek letters already exist. Examples are Latin Modern, +Kerkis, GFS Neohellenic, LX Fonts and KP-Serif. + +Upright small Greek letters in ``\mathrm`` would enable the +specification of the constant pi, Myons, Pions, alpha-particles, +photons, and neutrinos with `math alphabets`_. (With mathdesign_ +fonts, this is already possible today.) + +With the development of the unicode-math_ package, an interesting +alternative for ISO-conforming math typesetting became available to +users of Unicode-enabled TeX engines (XeTeX or LuaTeX). + + +References +---------- + +.. [ISO-80000-2] `Quantities and units – Part 2: Mathematical signs + and symbols to be used in the natural sciences and technology`: + http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?csnumber=31887. + +.. [ISO-31] `Quantities and units`, Superseded by [ISO-80000]. + +.. [typefaces] National Institute of Standards and Technology (NIST_), + `Typefaces for Symbols in Scientific Manuscripts`: + http://physics.nist.gov/cuu/pdf/typefaces.pdf. + +.. [checklist] National Institute of Standards and Technology (NIST_), + `SI Unit rules and style conventions` + Check List for Reviewing Manuscripts: + http://physics.nist.gov/cuu/Units/checklist.html. + +.. [fonts_for_symbols] International Union of Pure and Applied + Chemistry (IUPAC_), `On the use of italic and roman fonts for symbols + in scientific text`, (Revised December 1999): + http://old.iupac.org/standing/idcns/fonts_for_symbols.html. + +.. [SI] Bureau international des poids et mesures (BIPM_), + `The International System of Units (SI)`: + http://www.bipm.org/en/si/si_brochure/. + +.. [Green-Book] International Union of Pure and Applied Chemistry (IUPAC_), + `Quantities, Units and Symbols in Physical Chemistry`, + 3rd edition, RSC Publishing, Cambridge 2007: + [ISBN 0 85404 433 7; ISBN-13 978 0 85404 433 7]. + +.. [Red-Book] International Union of Pure and Applied Physics (IUPAP_), + `Symbols, Units, Nomenclature and Fundamental Constants in Physics`: + http://metrology.wordpress.com/measurement-process-index/iupap-red-book/index-iupap-red-book/. + +.. [becc97] Claudio Beccari, `Typesetting mathematics for science and + technology according to ISO 31 XI`, TUGboat, Volume 18, 1997, No. 1: + http://www.tug.org/TUGboat/tb18-1/tb54becc.pdf. + +.. [encguide] Frank Mittelbach, Robin Fairbairns, Werner Lemberg, + LaTeX3 Project Team, `LaTeX font encodings`: + http://mirror.ctan.org/macros/latex/doc/encguide.pdf. + +.. [fntguide] LaTeX3 Project Team, `LaTeX 2e font selection`: + http://mirror.ctan.org/macros/latex/doc/fntguide.pdf. + +.. [tr25] Barbara Beeton, Asmus Freytag, Murray Sargent III, + `Unicode Support for Mathematics`, Unicode Technical Report #25: + http://www.unicode.org/reports/tr25/. + +.. [beeton:2000] Barbara Beeton: + `Unicode and math, a combination whose time has come – Finally!`, + TUGBoat, 21#3, 2000: + http://www.tug.org/TUGboat/Articles/tb21-3/tb68beet.pdf. + +.. see also + [koma-mail] Custom font substitution: http://www.komascript.de/node/823. + + +.. Links + ===== + +.. _BIPM: http://www.bipm.org/ +.. _IUPAC: http://iupac.org/ +.. _IUPAP: http://www.iupap.org/ +.. _LaTeX Project Public License: http://www.latex-project.org/lppl.txt +.. _Jens-Peer Kuska: http://phong.informatik.uni-leipzig.de/~kuska/ +.. _NIST: http://physics.nist.gov/ +.. _mathematical alphanumeric symbols unicode block: + http://www.unicode.org/charts/PDF/U1D400.pdf +.. _amsbsy: http://mirror.ctan.org/help/Catalogue/entries/amsbsy.html +.. _amsfonts: http://mirror.ctan.org/help/Catalogue/entries/amsfonts.html +.. _amsmath: http://mirror.ctan.org/help/Catalogue/entries/amsmath.html +.. _amssymb: http://mirror.ctan.org/help/Catalogue/entries/amssymb.html +.. _anttor: http://mirror.ctan.org/help/Catalogue/entries/anttor.html +.. _arev: http://mirror.ctan.org/help/Catalogue/entries/arev.html +.. _Asana Math: http://mirror.ctan.org/help/Catalogue/entries/asana-math.html +.. _bm: http://mirror.ctan.org/help/Catalogue/entries/bm.html +.. _bbm: http://mirror.ctan.org/help/Catalogue/entries/bbm.html +.. _bbold: http://mirror.ctan.org/help/Catalogue/entries/bbold.html +.. _calrsfs: http://mirror.ctan.org/help/Catalogue/entries/calrsfs.html +.. _cmbright: http://mirror.ctan.org/help/Catalogue/entries/cmbright.html +.. _concmath: http://mirror.ctan.org/help/Catalogue/entries/concmath.html +.. _doublestoke: http://mirror.ctan.org/help/Catalogue/entries/doublestoke.html +.. _efont: http://mirror.ctan.org/help/Catalogue/entries/efont.html +.. _eucal: http://mirror.ctan.org/help/Catalogue/entries/eucal.html +.. _eufrak: http://mirror.ctan.org/help/Catalogue/entries/eufrak.html +.. _eulervm: http://mirror.ctan.org/help/Catalogue/entries/eulervm.html +.. _euscript: http://mirror.ctan.org/help/Catalogue/entries/euscript.html +.. _fixmath: http://mirror.ctan.org/help/Catalogue/entries/fixmath.html +.. _fix-cm: http://mirror.ctan.org/help/Catalogue/entries/fix-cm.html +.. _fourier: http://mirror.ctan.org/help/Catalogue/entries/fourier.html +.. _fontspec: http://mirror.ctan.org/help/Catalogue/entries/fontspec.html +.. _gfsdidot: http://mirror.ctan.org/help/Catalogue/entries/gfsdidot.html +.. _gfsneohellenic: http://mirror.ctan.org/help/Catalogue/entries/gfsneohellenic.html +.. _greektex: http://mirror.ctan.org/help/Catalogue/entries/greektex.html +.. _hvmath: http://mirror.ctan.org/help/Catalogue/entries/hvmath.html +.. _hfbright: http://mirror.ctan.org/help/Catalogue/entries/hfbright.html +.. _ifthen: http://mirror.ctan.org/help/Catalogue/entries/ifthen.html +.. _iwona: http://mirror.ctan.org/help/Catalogue/entries/iwona.html +.. _jamtimes: http://mirror.ctan.org/help/Catalogue/entries/jamtimes.html +.. _kerkis: http://mirror.ctan.org/help/Catalogue/entries/kerkis.html +.. _keyval: http://mirror.ctan.org/help/Catalogue/entries/keyval.html +.. _kpfonts: http://mirror.ctan.org/help/Catalogue/entries/kpfonts.html +.. _kurier: http://mirror.ctan.org/help/Catalogue/entries/kurier.html +.. _kvoptions: http://mirror.ctan.org/help/Catalogue/entries/kvoptions.html +.. _lgrx: http://mirror.ctan.org/help/Catalogue/entries/lgrx.html +.. _lxfonts: http://mirror.ctan.org/help/Catalogue/entries/lxfonts.html +.. _lucimatx: http://pctex.com/files/managed/b/bf/lucimatxAbbrev.pdf +.. _mathbbol: http://mirror.ctan.org/help/Catalogue/entries/mathbbol.html +.. _mbboard: http://mirror.ctan.org/help/Catalogue/entries/mbboard.html +.. _mathdesign: http://mirror.ctan.org/help/Catalogue/entries/mathdesign.html +.. _mathpazo: http://mirror.ctan.org/help/Catalogue/entries/mathpazo.html +.. _mathptmx: http://mirror.ctan.org/help/Catalogue/entries/mathptmx.html +.. _mathptmv: http://mirror.ctan.org/help/Catalogue/entries/mathptmv.html +.. _mathrsfs: http://mirror.ctan.org/help/Catalogue/entries/mathrsfs.html +.. _newtx: http://mirror.ctan.org/help/Catalogue/entries/newtx.html +.. _New Euler: https://github.com/khaledhosny/euler-otf +.. _pxfonts: http://mirror.ctan.org/help/Catalogue/entries/pxfonts.html +.. _sansmath: http://mirror.ctan.org/help/Catalogue/entries/sansmath.html +.. _sbbm: http://mirror.ctan.org/help/Catalogue/entries/sbbm.html +.. _sfmath: http://dtrx.de/od/tex/sfmath.html +.. _tmmath: http://mirror.ctan.org/help/Catalogue/entries/tmmath.html +.. _txfonts: http://mirror.ctan.org/help/Catalogue/entries/txfonts.html +.. _unicode-math: + http://mirror.ctan.org/help/Catalogue/entries/unicode-math.html +.. _upgreek: http://mirror.ctan.org/help/Catalogue/entries/upgreek.html +.. _urwchancal: http://mirror.ctan.org/help/Catalogue/entries/urwchancal.html +.. _wrisym: http://phong.informatik.uni-leipzig.de/~kuska/wri_texmf_4.2.zip +.. _XITS: http://mirror.ctan.org/help/Catalogue/entries/xits.html +.. _zefonts: http://mirror.ctan.org/help/Catalogue/entries/zefonts.html |