You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
= The last case does not have the sup part above the operator.
Analysis
The math package code is insane and poorly commented, sorry to say.
Yet a line for the sup-only case (which differs from the sub-only case) looks dubious:
diff --git a/packages/math/texlike.lua b/packages/math/texlike.lua
index 5d1073fe..5abb03c6 100644
--- a/packages/math/texlike.lua
+++ b/packages/math/texlike.lua
@@ -328,7 +328,7 @@ local function compileToMathML_aux (_, arg_env, tree)
tree.options = {}
-- Translate TeX-like sub/superscripts to `munderover` or `msubsup`,
-- depending on whether the base is a big operator
- elseif tree.id == "sup" and tree[1].command == "mo" and tree[1].atom == atomType.bigOperator then
+ elseif tree.id == "sup" and tree[1].command == "mo" and symbolDefaults[tree[1][1]].atom == atomType.bigOperator then
tree.command = "mover"
elseif tree.id == "sub" and tree[1].command == "mo" and symbolDefaults[tree[1][1]].atom == atomType.bigOperator then
tree.command = "munder"
And with the shown change, yay:
Dear math-aware friends, what do you think?
The text was updated successfully, but these errors were encountered:
Input
Formula in TeX-like syntax:
I.e. large operator, with (1) both sup and sub elements, (2) only sub elements, (3) only sup elements.
Expected
As obtained on https://latexeditor.lagrida.com/
Observed
= The last case does not have the sup part above the operator.
Analysis
The math package code is insane and poorly commented, sorry to say.
Yet a line for the sup-only case (which differs from the sub-only case) looks dubious:
And with the shown change, yay:
Dear math-aware friends, what do you think?
The text was updated successfully, but these errors were encountered: