<mmultiscripts>

  • Revision slug: MathML/Element/mmultiscripts
  • Revision title: mmultiscripts
  • Revision id: 303581
  • Created:
  • Creator: fscholz
  • Is current revision? No
  • Comment

Revision Content

The MathML <mmultiscripts> element allows you to create tensor-like objects. In a descriptive way tensors are multidimensional matrices (mathematical imprecise but exemplified). The degree of a tensor depends on the dimensionality of a representative array. For example, a number is a 0-dimensional array, or a 0th-order tensor. A 1-dimensional array (e.g. vectors) is a 1st-order tensor and so 2nd-order tensors are needed to represent square matrices. To learn more about the mathematical background of tensors refer to the entry on Wikipedia.

MathML uses a special syntax to describe subscripts and superscripts for both, postscripts and prescripts, attached to a base expression:

<mmultiscripts>
    base
     (subscript superscript)*
     [ <mprescripts/> (presubscript presuperscript)* ]
</mmultiscripts>

After the base expression you can specify a postsubscript and a postsuperscript. Prescripts are optional and are separated by the empty tag <mprescripts/>. In addition you are able to use <none/> as a placeholder for empty positions.

Attributes

class, id, style
Provided for use with stylesheets.
href
Used to set a hyperlink to a specified URI.
mathbackground
The background color. You can use #rgb, #rrggbb and HTML color names.
mathcolor
The text color. You can use #rgb, #rrggbb and HTML color names.
subscriptshift
The minimum space by which to shift the subscript below the baseline of the expression, as a CSS length.
superscriptshift
The minimum space by which to shift the superscript above the baseline of the expression, as a CSS length.

Examples

Example 1: Using <mprescripts/>

Rendering:

<math>  

    <mmultiscripts>

        <mi>X</mi>      <!-- base expression -->  

        <mi>d</mi>      <!-- postsubscript -->
        <mi>c</mi>      <!-- postsuperscript -->

        <mprescripts />
        <mi>b</mi>      <!-- presubscript -->
        <mi>a</mi>      <!-- presuperscript -->

    </mmultiscripts>

</math>

Example 2: Using <none/>

Rendering: <img alt="" data-cke-saved-src="/files/3222/mmultiscripts_none.png style=" src="/files/3222/mmultiscripts_none.png style=" vertical-align:="" middle;="" margin-left:="" 10px;"="">

<math>  

    <mmultiscripts>

        <mi>X</mi>      <!-- base expression -->

        <none />        <!-- postsubscript -->
        <mi>c</mi>      <!-- postsuperscript -->

        <mprescripts />
        <mi>b</mi>      <!-- presubscript -->
        <none />        <!-- presuperscript -->

    </mmultiscripts>

</math>

Browser compatibility

{{ CompatibilityTable() }}

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari
Basic support {{ CompatNo() }} {{ CompatGeckoDesktop("1.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
href {{ CompatNo() }} {{ CompatGeckoDesktop("7.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
mathbackground {{ CompatNo() }} {{ CompatGeckoDesktop("2.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
mathcolor {{ CompatNo() }} {{ CompatGeckoDesktop("2.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
Feature Android Chrome for Android Firefox Mobile (Gecko) IE Mobile Opera Mobile Safari Mobile
Basic support {{ CompatNo() }} {{ CompatNo() }} {{ CompatGeckoMobile("1.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
href {{ CompatNo() }} {{ CompatNo() }} {{ CompatGeckoMobile("7.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
mathbackground {{ CompatNo() }} {{ CompatNo() }} {{ CompatGeckoMobile("2.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}
mathcolor {{ CompatNo() }} {{ CompatNo() }} {{ CompatGeckoMobile("2.0") }} {{ CompatNo() }} {{ CompatNo() }} {{ CompatNo() }}

Specifications

Specification Status Comment
{{ SpecName('MathML3', 'chapter3.html#presm.mmultiscripts', 'mmultiscripts') }} {{ Spec2('MathML3') }} Current specification
{{ SpecName('MathML2', 'chapter3.html#presm.mmultiscripts', 'mmultiscripts') }} {{ Spec2('MathML2') }} Initial specification

See also

  • {{ MathMLElement("msub") }} (Subscript)
  • {{ MathMLElement("msup") }} (Superscript)
  • {{ MathMLElement("msubsup") }} (Subscript-superscript pair)

Revision Source

<p>The MathML <code>&lt;mmultiscripts&gt;</code> element allows you to create tensor-like objects. In a descriptive way <a class="external" href="http://en.wikipedia.org/wiki/Tensor" title="http://en.wikipedia.org/wiki/Tensor">tensors</a> are multidimensional matrices (mathematical imprecise but exemplified). The degree of a tensor depends on the dimensionality of a representative array. For example, a number is a 0-dimensional array, or a 0th-order tensor. A 1-dimensional array (e.g. vectors) is a 1st-order tensor and so 2nd-order tensors are needed to represent square matrices. To learn more about the mathematical background of tensors refer to the <a class="external" href="http://en.wikipedia.org/wiki/Tensor" title="http://en.wikipedia.org/wiki/Tensor">entry on Wikipedia</a>.</p>
<p>MathML uses a special syntax to describe subscripts and superscripts for both, postscripts and prescripts, attached to a base expression:</p>
<pre>
&lt;mmultiscripts&gt;
    <em>base</em>
     (<em>subscript superscript</em>)*
     [ &lt;mprescripts/&gt; (<em>presubscript presuperscript</em>)* ]
&lt;/mmultiscripts&gt;
</pre>
<p>After the base expression you can specify a postsubscript and a postsuperscript. Prescripts are optional and are separated by the empty tag <code>&lt;mprescripts/&gt;</code>. In addition you are able to use <code>&lt;none/&gt;</code> as a placeholder for empty positions.</p>
<h2 id="Attributes">Attributes</h2>
<dl>
  <dt id="attr-class-id-style">
    class, id, style</dt>
  <dd>
    Provided for use with <a href="/en-US/docs/CSS">stylesheets</a>.</dd>
  <dt id="attr-href">
    href</dt>
  <dd>
    Used to set a hyperlink to a specified URI.</dd>
  <dt id="attr-mathbackground">
    mathbackground</dt>
  <dd>
    The background color. You can use <code>#rgb</code>, <code>#rrggbb</code> and <a href="/en-US/docs/CSS/color_value#Color_Keywords">HTML color names</a>.</dd>
  <dt id="attr-mathcolor">
    mathcolor</dt>
  <dd>
    The text color. You can use <code>#rgb</code>, <code>#rrggbb</code> and <a href="/en-US/docs/CSS/color_value#Color_Keywords">HTML color names</a>.</dd>
  <dt id="attr-subscriptshift">
    subscriptshift</dt>
  <dd>
    The minimum space by which to shift the subscript below the baseline of the expression, as a <a href="/en-US/docs/CSS/length">CSS length</a>.</dd>
  <dt id="attr-superscriptshift">
    superscriptshift</dt>
  <dd>
    The minimum space by which to shift the superscript above the baseline of the expression, as a <a href="/en-US/docs/CSS/length">CSS length</a>.</dd>
</dl>
<h2 id="Examples">Examples</h2>
<h4>Example 1: Using <code>&lt;mprescripts/&gt;</code></h4>
<p>Rendering: <img alt="" src="/files/3223/mmultiscripts_prescripts.png" style="vertical-align: middle; margin-left: 10px;" /></p>
<pre class="brush: html">
&lt;math&gt;  

    &lt;mmultiscripts&gt;

        &lt;mi&gt;X&lt;/mi&gt;      &lt;!-- base expression --&gt;  

        &lt;mi&gt;d&lt;/mi&gt;      &lt;!-- postsubscript --&gt;
        &lt;mi&gt;c&lt;/mi&gt;      &lt;!-- postsuperscript --&gt;

        &lt;mprescripts /&gt;
        &lt;mi&gt;b&lt;/mi&gt;      &lt;!-- presubscript --&gt;
        &lt;mi&gt;a&lt;/mi&gt;      &lt;!-- presuperscript --&gt;

    &lt;/mmultiscripts&gt;

&lt;/math&gt;
</pre>
<h4>Example 2: Using <code>&lt;none/&gt;</code></h4>
<p>Rendering: &lt;img alt="" data-cke-saved-src="/files/3222/mmultiscripts_none.png style=" src="/files/3222/mmultiscripts_none.png style=" vertical-align:="" middle;="" margin-left:="" 10px;"=""&gt;</p>
<pre class="brush: html">
&lt;math&gt;  

    &lt;mmultiscripts&gt;

        &lt;mi&gt;X&lt;/mi&gt;      &lt;!-- base expression --&gt;

        &lt;none /&gt;        &lt;!-- postsubscript --&gt;
        &lt;mi&gt;c&lt;/mi&gt;      &lt;!-- postsuperscript --&gt;

        &lt;mprescripts /&gt;
        &lt;mi&gt;b&lt;/mi&gt;      &lt;!-- presubscript --&gt;
        &lt;none /&gt;        &lt;!-- presuperscript --&gt;

    &lt;/mmultiscripts&gt;

&lt;/math&gt;
</pre>
<h2 id="Browser_compatibility">Browser compatibility</h2>
<p>{{ CompatibilityTable() }}</p>
<div id="compat-desktop">
  <table class="compat-table">
    <tbody>
      <tr>
        <th>Feature</th>
        <th>Chrome</th>
        <th>Firefox (Gecko)</th>
        <th>Internet Explorer</th>
        <th>Opera</th>
        <th>Safari</th>
      </tr>
      <tr>
        <td>Basic support</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoDesktop("1.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>href</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoDesktop("7.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>mathbackground</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoDesktop("2.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>mathcolor</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoDesktop("2.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
    </tbody>
  </table>
</div>
<div id="compat-mobile">
  <table class="compat-table">
    <tbody>
      <tr>
        <th>Feature</th>
        <th>Android</th>
        <th>Chrome for Android</th>
        <th>Firefox Mobile (Gecko)</th>
        <th>IE Mobile</th>
        <th>Opera Mobile</th>
        <th>Safari Mobile</th>
      </tr>
      <tr>
        <td>Basic support</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoMobile("1.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>href</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoMobile("7.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>mathbackground</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoMobile("2.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
      <tr>
        <td><code>mathcolor</code></td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatGeckoMobile("2.0") }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
        <td>{{ CompatNo() }}</td>
      </tr>
    </tbody>
  </table>
</div>
<h2 id="Specifications" name="Specifications">Specifications</h2>
<table class="standard-table" height="49" width="1000">
  <thead>
    <tr>
      <th scope="col">Specification</th>
      <th scope="col">Status</th>
      <th scope="col">Comment</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>{{ SpecName('MathML3', 'chapter3.html#presm.mmultiscripts', 'mmultiscripts') }}</td>
      <td>{{ Spec2('MathML3') }}</td>
      <td>Current specification</td>
    </tr>
    <tr>
      <td>{{ SpecName('MathML2', 'chapter3.html#presm.mmultiscripts', 'mmultiscripts') }}</td>
      <td>{{ Spec2('MathML2') }}</td>
      <td>Initial specification</td>
    </tr>
  </tbody>
</table>
<h2 id="See_also">See also</h2>
<ul>
  <li>{{ MathMLElement("msub") }} (Subscript)</li>
  <li>{{ MathMLElement("msup") }} (Superscript)</li>
  <li>{{ MathMLElement("msubsup") }} (Subscript-superscript pair)</li>
</ul>
Revert to this revision