"mn" - MathML Number Element

Q

How to use the MathML Number Element: "mn"?

✍: FYIcenter.com

A

"mn" is the MathML Number Element that allows you to specify a numeric value in a mathematical express.

The syntax for "mn" element is:

<mn>value</mn>

Here are some guidelines on how to specify a numeric value:

  • Integer and decimal numbers are allowed.
  • Scientific notations are allowed.
  • Operators and symbols should not be used.

Here are some good examples of "mn" elements:

<math>
  <mrow>
    <mn>1024</mn><mo>,</mo>
    <mn>1,024</mn><mo>,</mo>
    <mn>-17.77778</mn><mo>,</mo>
    <mn>3.14</mn><mo>,</mo>
    <mn>9.1e-31</mn><mo>,</mo>
    <mn>π</mn><mo>,</mo>
  </mrow>
</math>

The above MathML example represents:


  
    1024,
    1,024,
    -17.77778,
    3.14,
    9.1e-31,
    π,
  

Here are some bad examples of "mn" elements:

<math>
  <mrow>
    <mn>$0.99</mn><mo>,</mo>
    <mn>5.00%</mn><mo>,</mo>
    <mn>3^2</mn><mo>,</mo>
  </mrow>
</math>

The above MathML example represents:


  
    $0.99,
    5.00%,
    3^2,
  

 

"mo" - MathML Operator Element

"mi" - MathML Identifier Element

Simple MathML Elements

⇑⇑ MathML (Mathematical Markup Language)

2025-03-29, 296🔥, 0💬