Menu
MathML Basic Elements

MathML (Mathematical Markup Language), similar to HTML which is used to encode the structure and content of a webapge, is an XML dialect for encoding mathematical expressions on a webapge. MathML most basic elements are <mn>, <mi> and <mo>.

mn Use this element to specify a numeric literal.

mi Use this element to specify an identifier, for example the name of a variable.

mo Use this element to specify an operator, for example +, -, =. Brackets are also considered operators.

Examples:

y + 4 = 5
<math>
  <mi>y</mi>
  <mo>+</mo>
  <mn>4</mn>
  <mo>=</mo>
  <mn>5</mn>
</math>

Most basic math expressions can be rendered with these three elements.

2 x - 14 + 3 ( x + 2 ) = -4
<math>
   <mn>2</mn>
   <mi>x</mi>
   <mo>-</mo>
   <mn>14</mn>
   <mo>+</mo>

   <mn>3</mn>
   <mo>(</mo>
   <mi>x</mi>
   <mo>+</mo>
   <mn>2</mn>
   <mo>)</mo>

   <mo>=</mo>
   <mn>-4</mn>
</math>

Note that the mo operator is used to place parentheses.

6 ( 2 x + 2 - 4 ( 4 x - 2 ) )
<math>
   <mn>6</mn>
   <mo>(</mo>
     <mn>2</mn>
     <mi>x</mi>
     <mo>+</mo>
     <mn>2</mn>
     <mo>-</mo>
       <mn>4</mn>
       <mo>(</mo>

      <mn>4</mn>
      <mi>x</mi>
      <mo>-</mo>
      <mn>2</mn>
      <mo>)</mo>
   <mo>)</mo>
</math>

The example above uses nested parentheses, a set of parentheses inside another set. Of course, to evaluate nested parentheses, start by evaluating the inner set of and then work your way outward.


Learn more at amazon.com

More Graphics Design Tips:
• Create Animated Glistening Gold Text With SVG
• MathML Element to Display a Radical
• Graphics File Formats for Your Web Page
• Coding Color for the Web
• How to Make a Simple Video
• XDdom 3D Axis and Coordinate System
• History of Type Development and Type Terminology
• How to Create a Simple Video with Windows Movie Maker
• MathML Basic Elements
• SVG Code for Outlined Letters Text