-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
msubsup issue
Volker Sorge edited this page Apr 22, 2015
·
9 revisions
Issue. Back to list of issues.
Msubsup are broken up in the semantic tree into explicit subscripts and superscripts if advisable.
We will stick with alternative 2 and add a collapsed attribute. Example is now here:
<math> <msubsup type="subsup" role="latinletter" id="4" children="0,1,2" collapsed="(4 (3 0 1) 2)"> <mi type="identifier" role="latinletter" id="0" parent="4">a</mi> <mi type="identifier" role="latinletter" id="1" parent="4">b</mi> <mi type="identifier" role="latinletter" id="2" parent="4">c</mi> </msubsup> </math>
Still to do: Look into prime, etc.
Original MathML:
<math> <msubsup> <mi>a</mi> <mi>b</mi> <mi>c</mi> </msubsup> </math>
Semantic Tree:
<stree> <superscript role="latinletter" id="4"> <children> <subscript role="subsup" id="3"> <children> <identifier role="latinletter" font="italic" id="0">a</identifier> <identifier role="latinletter" font="italic" id="1">b</identifier> </children> </subscript> <identifier role="latinletter" font="italic" id="2">c</identifier> </children> </superscript> </stree>
Straightforward translation of the semantic tree into the MathML element, naturally ruins the msubsup element. Here's the semantically enriched MathML:
<math> <msubsup type="superscript" role="latinletter" id="4" children="3,2"> <mrow type="subscript" role="subsup" id="3" children="0,1" parent="4"> <mi type="identifier" role="latinletter" id="0" parent="3">a</mi> <mi type="identifier" role="latinletter" id="1" parent="3">b</mi> </mrow> <mi type="identifier" role="latinletter" id="2" parent="4">c</mi> </msubsup> </math>
Alternative is this semantically enriched MathML:
<msubsup type="subsup" role="latinletter" id="4" children="0,1,2"> <mi type="identifier" role="latinletter" id="0" parent="4">a</mi> <mi type="identifier" role="latinletter" id="1" parent="4">b</mi> <mi type="identifier" role="latinletter" id="2" parent="4">c</mi> </msubsup>
Observe that this does not affect elements where msubsup has discernably been used as a layout element. See, for example the following sum expression:
<math> <msubsup> <mo>∑</mo> <mi>b</mi> <mi>c</mi> </msubsup> </math>
Semantic Tree:
<stree> <limboth role="sum" id="3"> <children> <largeop role="sum" id="0">∑</largeop> <identifier role="latinletter" font="italic" id="1">b</identifier> <identifier role="latinletter" font="italic" id="2">c</identifier> </children> </limboth> </stree>
Semantically enriched MathML:
<math> <msubsup type="limboth" role="sum" id="3" children="0,1,2"> <mo type="largeop" role="sum" id="0" parent="3">∑</mo> <mi type="identifier" role="latinletter" id="1" parent="3">b</mi> <mi type="identifier" role="latinletter" id="2" parent="3">c</mi> </msubsup> </math>