Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
MathML
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Content MathML === {{Infobox file format | name = Content MathML | mime = application/mathml-content+xml | type code = <code>MMLc</code> | uniform type = {{mono|public.mathml.content}} | conforms to = {{mono|public.mathml}} | extended from = [[#Generic MathML|Generic MathML]] }} Content MathML focuses on the semantics, or meaning, of the expression rather than its layout. Central to Content MathML is the {{code|lang=XML|<apply>}} element that represents function application. The function being applied is the first child element under {{code|lang=XML|<apply>}}, and its operands or parameters are the remaining child elements. Content MathML uses only a few attributes. Tokens such as identifiers and numbers are individually marked up, much as for Presentation MathML, but with elements such as {{code|lang=XML|<ci>}} and {{code|lang=XML|<cn>}}. Rather than being merely another type of token, operators are represented by specific elements, whose mathematical semantics are known to MathML: {{code|lang=XML|<times>}}, {{code|lang=XML|<power>}}, etc. There are over a hundred different elements for different functions and operators.<ref>{{cite web | url = http://www.w3.org/TR/MathML3/chapter4.html#contm.opel | title = Content Markup | website = W3.org }}</ref> For example, {{code|lang=XML|<apply><sin/><ci>x</ci></apply>}} represents <math>\sin(x)</math> and {{code|lang=XML|<apply><plus/><ci>x</ci><cn>5</cn></apply>}} represents <math>x+5</math>. The elements representing operators and functions are empty elements, because their operands are the other elements under the containing {{code|lang=XML|<apply>}}. The expression <math>a x^2+b x+c</math> could be represented as <syntaxhighlight lang="xml"> <math> <apply> <plus/> <apply> <times/> <ci>a</ci> <apply> <power/> <ci>x</ci> <cn>2</cn> </apply> </apply> <apply> <times/> <ci>b</ci> <ci>x</ci> </apply> <ci>c</ci> </apply> </math> </syntaxhighlight> Content MathML is nearly [[isomorphic]] to [[Binary expression tree|expressions]] in a [[Functional programming|functional language]] such as [[Scheme (programming language)|Scheme]] and other dialects of [[Lisp (programming language)|Lisp]]. {{code|lang=XML|<apply>...</apply>}} amounts to Scheme's {{code|lang=Scheme|(...)}}, and the many operator and function elements amount to Scheme functions. With this trivial literal transformation, plus un-tagging the individual tokens, the example above becomes: <syntaxhighlight lang="scheme"> (plus (times a (power x 2)) (times b x) c) </syntaxhighlight> This reflects the long-known close relationship between XML element structures, and [[Lisp (programming language)|LISP]] or Scheme [[S-expressions]].<ref>Steven DeRose. The SGML FAQ Book: Understanding the Relationship of SGML and XML, Kluwer Academic Publishers, 1997. {{isbn|978-0-7923-9943-8}}.</ref><ref>[[Canonical S-expressions#cite note-0]]</ref> ==== Wikidata annotation in Content MathML ==== According to the OM Society,<ref name="OpenMath">{{cite web | url = https://www.openmath.org/ | title = OpenMath Home Β· OpenMath | website = www.openmath.org }}</ref> OpenMath Content Dictionaries can be employed as collections of symbols and identifiers with declarations of their semantics{{snd}}names, descriptions and rules. A 2018 paper presented at the [[Special Interest Group on Information Retrieval|SIGIR]] conference<ref name="SchubotzScharpfGipp2018">{{cite journal | first1 = Moritz | last1 = Schubotz | first2 = Philipp | last2 = Scharpf | first3 = Bela | last3 = Gipp | title = Representing Mathematical Formulae in Content MathML using Wikidata. | url = http://ceur-ws.org/Vol-2132/paper5.pdf | date = 2018 | journal = Birndl@sigir }}</ref> proposed that the semantic knowledge base [[Wikidata]] could be used as an OpenMath Content Dictionary to link semantic elements of a mathematical formula to unique and language-independent Wikidata items.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)