In MathML, two elements are used to specify radicals. These two elements are:
- <msqrt> element
- <mroot> element
The <msqrt> element creates a square root, taking the base as its only argument, and the <mroot> element is used to create an indexed root. It takes base and index as argument.
For example:
To write the following equation on the web page:
Equivalent MathML code:
- <math xmlns=’http://www.w3.org/1998/Math/MathML’ display=’block’>
- <msqrt>
- <mn>4</mn>
- </msqrt>
- <mo>×</mo>
- <mroot>
- <mn>8</mn>
- <mn>3</mn>
- </mroot>
- <mo>=</mo>
- <mn>4</mn>
- </math>
Supporting Browsers:
Element | Chrome | IE | Firefox (Gecko) | Opera | Safari |
<msqrt> | Not Supported | Not Supported | Supported | Not Supported | Only Basic Support |
Leave a Reply