--- title: slug: Web/MathML/Element/msqrt tags: - MathML - 平方根 translation_of: Web/MathML/Element/msqrt ---

{{MathMLRef()}}

MathMLの <msqrt> 要素は平方根(根指数のついていない累乗根)を表示するために用いられます。 引数は一つだけで、構文は <msqrt> base </msqrt> となります。

属性

class, id, style
CSSを用いて修飾を行なう際に使われます。
href
ハイパーリンクを設定する際に用いられます。
mathbackground
数式の背景色を指定するために使われます。#rgb#rrggbbのような16進表現のほか、HTMLで定められた色キーワードを用いることができます。
mathcolor
根号を含んだ数式の文字の色を指定するために使われます。#rgb#rrggbbのような16進表現のほか、HTMLで定められた色キーワードを用いることができます。

レンダリングのサンプル(画像): root-x

ブラウザのレンダリング結果: x

<math>

 <msqrt>
    <mi>x</mi>
  </msqrt>

</math>

ブラウザごとの互換性

{{Compat("mathml.elements.msqrt")}}

仕様

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

See also