English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
HTML5 può utilizzare gli elementi MathML nei documenti, i tag corrispondenti sono <math>...</math> . MathML è un linguaggio di markup per la matematica, una specifica basata su XML (sottoinsieme del linguaggio di markup generale) utilizzata per scrivere simboli e formule matematiche su Internet.
Attenzione: la maggior parte dei browser supporta i tag MathML, se il tuo browser non supporta questi tag, puoi utilizzare la versione più recente di Firefox o Safari per visualizzarli.
Di seguito è riportato un esempio semplice di MathML:
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Base Tutorial Website (oldtoolbag.com)</title> </head> <body> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <msup><mi>a</mi><mn>2</mn></msup> <mo>+</mo> <msup><mi>b</mi><mn>2</mn></msup> <mo>=</mo> <msup><mi>c</mi><mn>2</mn></msup> </mrow> </math> </body> </html>Testa per vedere ‹/›
Ecco l'immagine del risultato di esecuzione:
Di seguito è riportato un esempio con alcuni operatori:
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Base Tutorial Website (oldtoolbag.com)</title> </head> <body> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mrow> <msup> <mi>x</mi> <mn>2</mn> </msup> <mo>+</mo> <mrow> <mn>4</mn> <mo></mo> <mi>x</mi> </mrow> <mo>+</mo> <mn>4</mn> </mrow> <mo>=</mo> <mn>0</mn> </mrow> </math> </body> </html>Testa per vedere ‹/›
Ecco l'immagine del risultato di esecuzione:
Di seguito è riportato un esempio di matrice 2x2:
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Base Tutorial Website (oldtoolbag.com)</title> </head> <body> <math xmlns="http://www.w3.org/1998/Math/MathML"> <mrow> <mi>A</mi> <mo>=</mo> <mfenced open="[" close="]"> <mtable> <mtr> <mtd><mi>x</mi></mtd> <mtd><mi>y</mi></mtd> </mtr> <mtr> <mtd><mi>z</mi></mtd> <mtd><mi>w</mi></mtd> </mtr> </mtable> </mfenced> </mrow> </math> </body> </html>Testa per vedere ‹/›
Immagine del risultato della runtime, come segue, questo genererà il risultato seguente. Se non vedete il risultato corretto, utilizzate Firefox 3.7 o versione successiva: