PageRenderTime 108ms CodeModel.GetById 26ms RepoModel.GetById 0ms app.codeStats 2ms

/main/khan/static/latestKhan/utils/MathJax/1.1a/config/KAthJax-62e7a7b628ba168df6b9cd3de8feac38.js

https://github.com/togaurav/class2go
JavaScript | 5957 lines | 5957 code | 0 blank | 0 comment | 887 complexity | 62e7a7b628ba168df6b9cd3de8feac38 MD5 | raw file
Possible License(s): Apache-2.0
  1. MathJax.Hub.Config({
  2. messageStyle: "none",
  3. skipStartupTypeset: !0,
  4. jax: [ "input/TeX", "output/HTML-CSS" ],
  5. extensions: [ "tex2jax.js", "MathZoom.js" ],
  6. TeX: {
  7. extensions: [ "AMSmath.js", "AMSsymbols.js", "noErrors.js", "noUndefined.js", "newcommand.js", "boldsymbol.js" ],
  8. Macros: {
  9. RR: "\\mathbb{R}",
  10. blue: "\\color{#6495ED}",
  11. orange: "\\color{#FFA500}",
  12. pink: "\\color{#FF00AF}",
  13. red: "\\color{red}",
  14. green: "\\color{#28AE7B}",
  15. gray: "\\color{gray}",
  16. purple: "\\color{purple}"
  17. },
  18. Augment: {
  19. Definitions: {
  20. macros: {
  21. lrsplit: "LRSplit",
  22. cancel: "Cancel",
  23. lcm: [ "NamedOp", 0 ]
  24. }
  25. },
  26. Parse: {
  27. prototype: {
  28. LRSplit: function(e) {
  29. var t = this.GetArgument(e), n = this.GetArgument(e), r = MathJax.ElementJax.mml.mfrac(MathJax.InputJax.TeX.Parse("\\strut\\textstyle{" + t + "\\qquad}", this.stack.env).mml(), MathJax.InputJax.TeX.Parse("\\strut\\textstyle{\\qquad " + n + "}", this.stack.env).mml());
  30. r.numalign = MathJax.ElementJax.mml.ALIGN.LEFT, r.denomalign = MathJax.ElementJax.mml.ALIGN.RIGHT, r.linethickness = "0em", this.Push(r);
  31. },
  32. Cancel: function(e) {
  33. this.Push(MathJax.ElementJax.mml.menclose(this.ParseArg(e)).With({
  34. notation: MathJax.ElementJax.mml.NOTATION.UPDIAGONALSTRIKE
  35. }));
  36. }
  37. }
  38. }
  39. }
  40. },
  41. "HTML-CSS": {
  42. scale: 100,
  43. showMathMenu: !1,
  44. availableFonts: [ "TeX" ],
  45. imageFont: null
  46. }
  47. }), MathJax.Hub.elementScripts = function(e) {
  48. return e.nodeName.toLowerCase() === "code" ? [ e ] : e.getElementsByTagName("code");
  49. }, MathJax.Hub.Browser.isKonqueror = !0, MathJax.Ajax.timeout = 6e4, MathJax.Ajax.loadError = function(e) {
  50. return function(t) {
  51. Khan.warnTimeout(), MathJax.Ajax.loadComplete = function(e) {}, e.call(this, t);
  52. };
  53. }(MathJax.Ajax.loadError), MathJax.Hub.Register.StartupHook("HTML-CSS Jax - disable web fonts", function() {
  54. Khan.warnFont();
  55. }), MathJax.Message.Init = function(e) {
  56. return function(t) {
  57. if (this.div && this.div.parentNode == null) {
  58. var n = document.getElementById("MathJax_Message");
  59. if (n && n.firstChild == null) {
  60. var r = n.parentNode;
  61. r && r.removeChild(n);
  62. }
  63. }
  64. e.call(this, t);
  65. };
  66. }(MathJax.Message.Init), MathJax.Hub.Startup.onload(), MathJax.Ajax.Preloading("[MathJax]/extensions/MathZoom.js", "[MathJax]/extensions/TeX/AMSmath.js", "[MathJax]/extensions/TeX/AMSsymbols.js", "[MathJax]/extensions/TeX/noErrors.js", "[MathJax]/extensions/TeX/noUndefined.js", "[MathJax]/extensions/TeX/newcommand.js", "[MathJax]/extensions/TeX/boldsymbol.js", "[MathJax]/extensions/tex2jax.js", "[MathJax]/jax/element/mml/jax.js", "[MathJax]/jax/input/TeX/config.js", "[MathJax]/jax/input/TeX/jax.js", "[MathJax]/jax/output/HTML-CSS/config.js", "[MathJax]/jax/output/HTML-CSS/jax.js"), MathJax.Hub.Config({
  67. "v1.0-compatible": !1
  68. }), function(e, t, n, r, i) {
  69. var s = "1.1", o = e.CombineConfig("MathZoom", {
  70. delay: 400,
  71. styles: {
  72. "#MathJax_Zoom": {
  73. position: "absolute",
  74. "background-color": "#F0F0F0",
  75. overflow: "auto",
  76. display: "block",
  77. "z-index": 301,
  78. padding: ".5em",
  79. border: "1px solid black",
  80. margin: 0,
  81. "font-family": "serif",
  82. "font-size": "85%",
  83. "font-weight": "normal",
  84. "font-style": "normal",
  85. "text-align": "left",
  86. "text-indent": 0,
  87. "text-transform": "none",
  88. "line-height": "normal",
  89. "letter-spacing": "normal",
  90. "word-spacing": "normal",
  91. "word-wrap": "normal",
  92. "white-space": "nowrap",
  93. "float": "none",
  94. "box-shadow": "5px 5px 15px #AAAAAA",
  95. "-webkit-box-shadow": "5px 5px 15px #AAAAAA",
  96. "-moz-box-shadow": "5px 5px 15px #AAAAAA",
  97. "-khtml-box-shadow": "5px 5px 15px #AAAAAA",
  98. filter: "progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"
  99. },
  100. "#MathJax_ZoomOverlay": {
  101. position: "absolute",
  102. left: 0,
  103. top: 0,
  104. "z-index": 300,
  105. display: "inline-block",
  106. width: "100%",
  107. height: "100%",
  108. border: 0,
  109. padding: 0,
  110. margin: 0,
  111. "background-color": "white",
  112. opacity: 0,
  113. filter: "alpha(opacity=0)"
  114. }
  115. }
  116. }), u = function(e) {
  117. return e || (e = window.event), e && (e.preventDefault && e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.cancelBubble = !0, e.returnValue = !1), !1;
  118. }, a = MathJax.Extension.MathZoom = {
  119. version: s,
  120. settings: e.config.menuSettings,
  121. HandleEvent: function(e, t, n) {
  122. return e || (e = window.event), a.settings.CTRL && !e.ctrlKey ? !0 : a.settings.ALT && !e.altKey ? !0 : a.settings.CMD && !e.metaKey ? !0 : a.settings.Shift && !e.shiftKey ? !0 : a[t](e, n);
  123. },
  124. Click: function(e, t) {
  125. if (this.settings.zoom === "Click") return this.Zoom(t, e);
  126. },
  127. DblClick: function(e, t) {
  128. if (this.settings.zoom === "Double-Click") return this.Zoom(t, e);
  129. },
  130. Mouseover: function(e, t) {
  131. if (this.settings.zoom === "Hover") return a.oldMouseOver = t.onmouseover, t.onmouseover = null, t.onmousemove = this.Mousemove, t.onmouseout = this.Mouseout, a.Timer(e, t);
  132. },
  133. Mouseout: function(e) {
  134. return this.onmouseover = a.oldMouseOver, delete a.oldMouseOver, this.onmousemove = this.onmouseout = null, a.ClearTimer(), u(e);
  135. },
  136. Mousemove: function(e) {
  137. return a.Timer(e || window.event, this);
  138. },
  139. Timer: function(e, t) {
  140. return this.ClearTimer(), this.timer = setTimeout(MathJax.Callback([ "Zoom", this, t, {} ]), o.delay), u(e);
  141. },
  142. ClearTimer: function() {
  143. this.timer && (clearTimeout(this.timer), delete this.timer);
  144. },
  145. Zoom: function(n, s) {
  146. this.ClearTimer(), this.Remove();
  147. var a = n.parentNode;
  148. a.className === "MathJax_MathContainer" && (a = a.parentNode), a.parentNode.className === "MathJax_MathContainer" && (a = a.parentNode.parentNode);
  149. var f = (String(a.className).match(/^MathJax_(MathML|Display)$/) ? a : n).nextSibling, l = e.getJaxFor(f), p = l.root, v = r && l.outputJax.isa(r.constructor) ? "HTMLCSS" : i && l.outputJax.isa(i.constructor) ? "MathML" : null;
  150. if (!v) return;
  151. var m = Math.floor(.85 * document.body.clientWidth), y = Math.floor(.85 * document.body.clientHeight), w = t.Element("span", {
  152. style: {
  153. position: "relative",
  154. display: "inline-block",
  155. height: 0,
  156. width: 0
  157. },
  158. id: "MathJax_ZoomFrame"
  159. }, [ [ "span", {
  160. id: "MathJax_ZoomOverlay",
  161. onmousedown: this.Remove
  162. } ], [ "span", {
  163. id: "MathJax_Zoom",
  164. onclick: this.Remove,
  165. style: {
  166. visibility: "hidden",
  167. fontSize: this.settings.zscale,
  168. "max-width": m + "px",
  169. "max-height": y + "px"
  170. }
  171. }, [ [ "span" ] ] ] ]), E = w.lastChild, S = E.firstChild, x = w.firstChild;
  172. n.parentNode.insertBefore(w, n);
  173. if (this.msieZIndexBug) {
  174. var T = t.Element("img", {
  175. src: "about:blank",
  176. id: "MathJax_ZoomTracker",
  177. style: {
  178. width: 0,
  179. height: 0,
  180. position: "relative"
  181. }
  182. });
  183. document.body.appendChild(w), w.style.position = "absolute", w.style.zIndex = o.styles["#MathJax_ZoomOverlay"]["z-index"], w = T;
  184. }
  185. var N = this["Zoom" + v](p, S, n);
  186. return this.msiePositionBug ? (this.msieIE8Bug && (S.style.position = "absolute", E.style.height = S.offsetHeight, S.style.position = "", E.offsetHeight <= y && E.offsetWidth <= m && (E.style.overflow = "visible")), this.msieWidthBug ? E.style.width = Math.min(m, N.w) : N.w > m && (E.style.width = m), E.offsetHeight > y && (E.style.Height = y + "px"), n.nextSibling ? n.parentNode.insertBefore(w, n.nextSibling) : a.appendChild(w)) : this.operaPositionBug && (E.style.width = Math.min(m, S.offsetWidth) + "px"), this.Position(E, N, v === "MathML" && a.nodeName.toLowerCase() === "div"), E.style.visibility = "", this.settings.zoom === "Hover" && (x.onmouseover = this.Remove), window.addEventListener ? addEventListener("resize", this.Resize, !1) : window.attachEvent ? attachEvent("onresize", this.Resize) : (this.onresize = window.onresize, window.onresize = this.Resize), u(s);
  187. },
  188. ZoomHTMLCSS: function(e, t, n) {
  189. t.className = "MathJax", r.idPostfix = "-zoom", r.getScales(t, t), e.toHTML(t, t);
  190. var i = e.HTMLspanElement().bbox;
  191. r.idPostfix = "";
  192. if (i.width && i.width !== "100%") {
  193. var s = Math.floor(.85 * document.body.clientWidth);
  194. t.style.width = s + "px", t.style.display = "inline-block";
  195. var o = (e.id || "MathJax-Span-" + e.spanID) + "-zoom", u = document.getElementById(o).firstChild;
  196. while (u && u.style.width !== i.width) u = u.nextSibling;
  197. u && (u.style.width = "100%");
  198. }
  199. t.appendChild(this.topImg);
  200. var a = this.topImg.offsetTop;
  201. t.removeChild(this.topImg);
  202. var f = this.msieWidthBug ? r.getW(n) * r.em : n.offsetWidth;
  203. return {
  204. w: i.w * r.em,
  205. Y: -a,
  206. W: f
  207. };
  208. },
  209. ZoomMathML: function(e, t, n) {
  210. e.toNativeMML(t, t);
  211. var r;
  212. t.appendChild(this.topImg), r = this.topImg.offsetTop, t.removeChild(this.topImg);
  213. var i = (this.ffMMLwidthBug ? n.parentNode : n).offsetWidth;
  214. return {
  215. w: t.offsetWidth,
  216. Y: -r,
  217. W: i
  218. };
  219. },
  220. Position: function(e, t, n) {
  221. var r = this.Resize(), i = r.x, s = r.y, o = t.W;
  222. this.msiePositionBug && (o = -o), n && this.ffMMLcenterBug && (o = 0);
  223. var u = -Math.floor((e.offsetWidth - o) / 2), a = t.Y;
  224. e.style.left = Math.max(u, 20 - i) + "px", e.style.top = Math.max(a, 20 - s) + "px";
  225. },
  226. Resize: function(e) {
  227. a.onresize && a.onresize(e);
  228. var t = 0, n = 0, r = document.getElementById("MathJax_ZoomFrame"), i = document.getElementById("MathJax_ZoomOverlay"), s = a.msieZIndexBug ? document.getElementById("MathJax_ZoomTracker") : r;
  229. a.operaPositionBug && (r.style.border = "1px solid");
  230. if (s.offsetParent) do t += s.offsetLeft, n += s.offsetTop; while (s = s.offsetParent);
  231. return a.operaPositionBug && (r.style.border = ""), a.msieZIndexBug && (r.style.left = t + "px", r.style.top = n + "px"), i.style.left = -t + "px", i.style.top = -n + "px", a.msiePositionBug ? setTimeout(a.SetWH, 0) : a.SetWH(), {
  232. x: t,
  233. y: n
  234. };
  235. },
  236. SetWH: function() {
  237. var e = document.getElementById("MathJax_ZoomOverlay");
  238. e.style.width = e.style.height = "1px", e.style.width = document.body.scrollWidth + "px", e.style.height = document.body.scrollHeight + "px";
  239. },
  240. Remove: function(e) {
  241. var n = document.getElementById("MathJax_ZoomFrame");
  242. if (n) {
  243. n.parentNode.removeChild(n), n = document.getElementById("MathJax_ZoomTracker"), n && n.parentNode.removeChild(n);
  244. if (a.operaRefreshBug) {
  245. var r = t.addElement(document.body, "div", {
  246. style: {
  247. position: "fixed",
  248. left: 0,
  249. top: 0,
  250. width: "100%",
  251. height: "100%",
  252. backgroundColor: "white",
  253. opacity: 0
  254. },
  255. id: "MathJax_OperaDiv"
  256. });
  257. document.body.removeChild(r);
  258. }
  259. window.removeEventListener ? removeEventListener("resize", a.Resize, !1) : window.detachEvent ? detachEvent("onresize", a.Resize) : (window.onresize = a.onresize, delete a.onresize);
  260. }
  261. return u(e);
  262. }
  263. };
  264. e.Register.StartupHook("HTML-CSS Jax Ready", function() {
  265. r = MathJax.OutputJax["HTML-CSS"], r.Augment({
  266. HandleEvent: a.HandleEvent
  267. });
  268. }), e.Register.StartupHook("NativeMML Jax Ready", function() {
  269. i = MathJax.OutputJax.NativeMML, i.Augment({
  270. HandleEvent: a.HandleEvent,
  271. MSIEmouseup: function(e, t, n) {
  272. return this.trapUp ? (delete this.trapUp, !0) : this.MSIEzoomKeys(e) ? !0 : !1;
  273. },
  274. MSIEclick: function(e, t, n) {
  275. return this.trapClick ? (delete this.trapClick, !0) : this.MSIEzoomKeys(e) ? this.settings.zoom.match(/Click/) ? a.Click(e, t) === !1 : !1 : !1;
  276. },
  277. MSIEdblclick: function(e, t, n) {
  278. return this.MSIEzoomKeys(e) ? a.DblClick(e, t) === !1 : !1;
  279. },
  280. MSIEmouseover: function(e, t, n) {
  281. return this.settings.zoom !== "Hover" ? !1 : (a.Timer(e, t), !0);
  282. },
  283. MSIEmouseout: function(e, t, n) {
  284. return this.settings.zoom !== "Hover" ? !1 : (a.ClearTimer(), !0);
  285. },
  286. MSIEmousemove: function(e, t, n) {
  287. return this.settings.zoom !== "Hover" ? !1 : (a.Timer(e, t), !0);
  288. },
  289. MSIEzoomKeys: function(e) {
  290. return this.settings.CTRL && !e.ctrlKey ? !1 : this.settings.CMD && !e.metaKey ? !1 : this.settings.ALT && !e.altKey ? !1 : this.settings.Shift && !e.shiftKey ? !1 : !0;
  291. }
  292. });
  293. }), e.Browser.Select({
  294. MSIE: function(e) {
  295. var t = document.compatMode === "BackCompat", n = e.versionAtLeast("8.0") && document.documentMode > 7;
  296. a.msiePositionBug = !0, a.msieWidthBug = !t, a.msieIE8Bug = n, a.msieZIndexBug = !n, a.msieInlineBlockAlignBug = !n || t, document.documentMode >= 9 && delete o.styles["#MathJax_Zoom"].filter;
  297. },
  298. Opera: function(e) {
  299. a.operaPositionBug = !0, a.operaRefreshBug = !0;
  300. },
  301. Firefox: function(e) {
  302. a.ffMMLwidthBug = !0, a.ffMMLcenterBug = !0;
  303. }
  304. }), a.topImg = a.msieInlineBlockAlignBug ? t.Element("img", {
  305. style: {
  306. width: 0,
  307. height: 0
  308. },
  309. src: "about:blank"
  310. }) : t.Element("span", {
  311. style: {
  312. width: 0,
  313. height: 0,
  314. display: "inline-block"
  315. }
  316. }), a.operaPositionBug && (a.topImg.style.border = "1px solid"), MathJax.Callback.Queue([ "Styles", n, o.styles ], [ "Post", e.Startup.signal, "MathZoom Ready" ], [ "loadComplete", n, "[MathJax]/extensions/MathZoom.js" ]);
  317. }(MathJax.Hub, MathJax.HTML, MathJax.Ajax, MathJax.OutputJax["HTML-CSS"], MathJax.OutputJax.NativeMML), MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  318. var e = "1.1", t = MathJax.ElementJax.mml, n = MathJax.InputJax.TeX, r = n.Definitions, i = n.Stack.Item, s = function(e) {
  319. return e.join("em ") + "em";
  320. };
  321. MathJax.Hub.Insert(r, {
  322. macros: {
  323. mathring: [ "Accent", "2DA" ],
  324. nobreakspace: "Tilde",
  325. negmedspace: [ "Spacer", t.LENGTH.NEGATIVEMEDIUMMATHSPACE ],
  326. negthickspace: [ "Spacer", t.LENGTH.NEGATIVETHICKMATHSPACE ],
  327. intI: [ "Macro", "\\mathchoice{\\!}{}{}{}\\!\\!\\int" ],
  328. iiiint: [ "MultiIntegral", "\\int\\intI\\intI\\intI" ],
  329. idotsint: [ "MultiIntegral", "\\int\\cdots\\int" ],
  330. dddot: [ "Macro", "\\mathop{#1}\\limits^{\\textstyle \\mathord{.}\\mathord{.}\\mathord{.}}", 1 ],
  331. ddddot: [ "Macro", "\\mathop{#1}\\limits^{\\textstyle \\mathord{.}\\mathord{.}\\mathord{.}\\mathord{.}}", 1 ],
  332. sideset: [ "Macro", "\\mathop{\\mathop{\\rlap{\\phantom{#3}}}\\nolimits#1\\!\\mathop{#3}\\nolimits#2}", 3 ],
  333. boxed: [ "Macro", "\\fbox{$\\displaystyle{#1}$}", 1 ],
  334. tag: "HandleTag",
  335. notag: "HandleNoTag",
  336. substack: [ "Macro", "\\begin{subarray}{c}#1\\end{subarray}", 1 ],
  337. injlim: [ "Macro", "\\mathop{\\rm inj\\,lim}" ],
  338. projlim: [ "Macro", "\\mathop{\\rm proj\\,lim}" ],
  339. varliminf: [ "Macro", "\\mathop{\\underline{\\rm lim}}" ],
  340. varlimsup: [ "Macro", "\\mathop{\\overline{\\rm lim}}" ],
  341. varinjlim: [ "Macro", "\\mathop{\\underrightarrow{\\rm lim\\Rule{-1pt}{0pt}{1pt}}\\Rule{0pt}{0pt}{.45em}}" ],
  342. varprojlim: [ "Macro", "\\mathop{\\underleftarrow{\\rm lim\\Rule{-1pt}{0pt}{1pt}}\\Rule{0pt}{0pt}{.45em}}" ],
  343. DeclareMathOperator: "HandleDeclareOp",
  344. operatorname: "HandleOperatorName",
  345. genfrac: "Genfrac",
  346. frac: [ "Genfrac", "", "", "", "" ],
  347. tfrac: [ "Genfrac", "", "", "", 1 ],
  348. dfrac: [ "Genfrac", "", "", "", 0 ],
  349. binom: [ "Genfrac", "(", ")", "0em", "" ],
  350. tbinom: [ "Genfrac", "(", ")", "0em", 1 ],
  351. dbinom: [ "Genfrac", "(", ")", "0em", 0 ],
  352. cfrac: "CFrac",
  353. shoveleft: [ "HandleShove", t.ALIGN.LEFT ],
  354. shoveright: [ "HandleShove", t.ALIGN.RIGHT ],
  355. xrightarrow: [ "xArrow", 8594, 5, 6 ],
  356. xleftarrow: [ "xArrow", 8592, 7, 3 ]
  357. },
  358. environment: {
  359. align: [ "AMSarray", null, !0, !0, "rlrlrlrlrlrl", s([ 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18 ]) ],
  360. "align*": [ "AMSarray", null, !1, !0, "rlrlrlrlrlrl", s([ 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18 ]) ],
  361. multline: [ "Multline", null, !0 ],
  362. "multline*": [ "Multline", null, !1 ],
  363. split: [ "AMSarray", null, !1, !1, "rl", s([ 5 / 18 ]) ],
  364. gather: [ "AMSarray", null, !0, !0, "c" ],
  365. "gather*": [ "AMSarray", null, !1, !0, "c" ],
  366. alignat: [ "AlignAt", null, !0, !0 ],
  367. "alignat*": [ "AlignAt", null, !1, !0 ],
  368. alignedat: [ "AlignAt", null, !1, !1 ],
  369. aligned: [ "Array", null, null, null, "rlrlrlrlrlrl", s([ 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18, 2, 5 / 18 ]), ".5em", "D" ],
  370. gathered: [ "Array", null, null, null, "c", null, ".5em", "D" ],
  371. subarray: [ "Array", null, null, null, null, s([ 0, 0, 0, 0 ]), "0.1em", "S", 1 ],
  372. smallmatrix: [ "Array", null, null, null, "c", s([ 1 / 3 ]), ".2em", "S", 1 ]
  373. },
  374. delimiter: {
  375. "\\lvert": [ "2223", {
  376. texClass: t.TEXCLASS.OPEN
  377. } ],
  378. "\\rvert": [ "2223", {
  379. texClass: t.TEXCLASS.CLOSE
  380. } ],
  381. "\\lVert": [ "2225", {
  382. texClass: t.TEXCLASS.OPEN
  383. } ],
  384. "\\rVert": [ "2225", {
  385. texClass: t.TEXCLASS.CLOSE
  386. } ]
  387. }
  388. }), n.Parse.Augment({
  389. HandleTag: function(e) {
  390. var r = this.trimSpaces(this.GetArgument(e));
  391. r === "*" ? r = this.GetArgument(e) : r = "(" + r + ")", this.stack.global.notag && n.Error(e + " not allowed in " + this.stack.global.notag + " environment"), this.stack.global.tag && n.Error("Multiple " + e), this.stack.global.tag = t.mtd.apply(t, this.InternalMath(r));
  392. },
  393. HandleNoTag: function(e) {
  394. this.stack.global.tag && delete this.stack.global.tag;
  395. },
  396. HandleDeclareOp: function(e) {
  397. var t = "", r = this.trimSpaces(this.GetArgument(e));
  398. r == "*" && (t = "\\limits", r = this.trimSpaces(this.GetArgument(e))), r.charAt(0) == "\\" && (r = r.substr(1));
  399. var i = this.GetArgument(e);
  400. i = i.replace(/\*/g, "\\text{*}").replace(/-/g, "\\text{-}"), n.Definitions.macros[r] = [ "Macro", "\\mathop{\\rm " + i + "}" + t ];
  401. },
  402. HandleOperatorName: function(e) {
  403. var t = "\\nolimits", n = this.trimSpaces(this.GetArgument(e));
  404. n == "*" && (t = "\\limits", n = this.trimSpaces(this.GetArgument(e))), n = n.replace(/\*/g, "\\text{*}").replace(/-/g, "\\text{-}"), this.string = "\\mathop{\\rm " + n + "}" + t + " " + this.string.slice(this.i), this.i = 0;
  405. },
  406. HandleShove: function(e, t) {
  407. var r = this.stack.Top();
  408. (r.type !== "multline" || r.data.length) && n.Error(e + " must come at the beginning of the line"), r.data.shove = t;
  409. },
  410. CFrac: function(e) {
  411. var r = this.trimSpaces(this.GetBrackets(e)), i = this.GetArgument(e), s = this.GetArgument(e), o = t.mfrac(n.Parse("\\strut\\textstyle{" + i + "}", this.stack.env).mml(), n.Parse("\\strut\\textstyle{" + s + "}", this.stack.env).mml());
  412. r = {
  413. l: t.ALIGN.LEFT,
  414. r: t.ALIGN.RIGHT,
  415. "": ""
  416. }[r], r == null && n.Error("Illegal alignment specified in " + e), r && (o.numalign = o.denomalign = r), this.Push(o);
  417. },
  418. Genfrac: function(e, r, i, s, o) {
  419. r == null ? r = this.GetDelimiterArg(e) : r = this.convertDelimiter(r), i == null ? i = this.GetDelimiterArg(e) : i = this.convertDelimiter(i), s == null && (s = this.GetArgument(e)), o == null && (o = this.trimSpaces(this.GetArgument(e)));
  420. var u = this.ParseArg(e), l = this.ParseArg(e), c = t.mfrac(u, l);
  421. s !== "" && (c.linethickness = s);
  422. if (r || i) c = t.mfenced(c).With({
  423. open: r,
  424. close: i
  425. });
  426. if (o !== "") {
  427. var h = [ "D", "T", "S", "SS" ][o];
  428. h == null && n.Error("Bad math style for " + e), c = t.mstyle(c), h === "D" ? (c.displaystyle = !0, c.scriptlevel = 0) : (c.displaystyle = !1, c.scriptlevel = o - 1);
  429. }
  430. this.Push(c);
  431. },
  432. Multline: function(e, t) {
  433. return this.Push(e), i.multline().With({
  434. arraydef: {
  435. displaystyle: !0,
  436. rowspacing: ".5em",
  437. width: n.config.MultLineWidth,
  438. columnwidth: "100%",
  439. side: n.config.TagSide,
  440. minlabelspacing: n.config.TagIndent
  441. }
  442. });
  443. },
  444. AMSarray: function(e, t, r, s, o) {
  445. return this.Push(e), s = s.replace(/[^clr]/g, "").split("").join(" "), s = s.replace(/l/g, "left").replace(/r/g, "right").replace(/c/g, "center"), i.AMSarray(e.name, t, r, this.stack).With({
  446. arraydef: {
  447. displaystyle: !0,
  448. rowspacing: ".5em",
  449. columnalign: s,
  450. columnspacing: o || "1em",
  451. rowspacing: "3pt",
  452. side: n.config.TagSide,
  453. minlabelspacing: n.config.TagIndent
  454. }
  455. });
  456. },
  457. AlignAt: function(e, t, r) {
  458. var i = this.GetArgument("\\begin{" + e.name + "}");
  459. i.match(/[^0-9]/) && n.Error("Argument to \\begin{" + e.name + "} must me a positive integer"), align = "", spacing = [];
  460. while (i > 0) align += "rl", spacing.push("0em 0em"), i--;
  461. return spacing = spacing.join(" "), r ? this.AMSarray(e, t, r, align, spacing) : this.Array(e, null, null, align, spacing, ".5em", "D");
  462. },
  463. MultiIntegral: function(e, t) {
  464. var n = this.GetNext();
  465. if (n === "\\") {
  466. var r = this.i;
  467. n = this.GetArgument(e), this.i = r, n === "\\limits" && (e === "\\idotsint" ? t = "\\!\\!\\mathop{\\,\\," + t + "}" : t = "\\!\\!\\!\\mathop{\\,\\,\\," + t + "}");
  468. }
  469. this.string = t + " " + this.string.slice(this.i), this.i = 0;
  470. },
  471. xArrow: function(e, r, i, s) {
  472. var o = {
  473. width: "+" + (i + s) + "mu",
  474. lspace: i + "mu"
  475. }, u = this.GetBrackets(e), l = this.ParseArg(e), c = t.mo(t.chars(String.fromCharCode(r))).With({
  476. stretchy: !0,
  477. texClass: t.TEXCLASS.REL
  478. }), h = t.munderover(c);
  479. h.SetData(h.over, t.mpadded(l).With(o).With({
  480. voffset: ".15em"
  481. })), u && (u = n.Parse(u, this.stack.env).mml(), h.SetData(h.under, t.mpadded(u).With(o).With({
  482. voffset: "-.24em"
  483. }))), this.Push(h);
  484. },
  485. GetDelimiterArg: function(e) {
  486. var t = this.trimSpaces(this.GetArgument(e));
  487. return t == "" ? null : (r.delimiter[t] || n.Error("Missing or unrecognized delimiter for " + e), this.convertDelimiter(t));
  488. }
  489. }), i.multline = i.array.Subclass({
  490. type: "multline",
  491. EndEntry: function() {
  492. var e = t.mtd.apply(t, this.data);
  493. this.data.shove && (e.columnalign = this.data.shove), this.row.push(e), this.data = [];
  494. },
  495. EndRow: function() {
  496. this.row.length != 1 && n.Error("multline rows must have exactly one column"), this.table.push(this.row), this.row = [];
  497. },
  498. EndTable: function() {
  499. this.SUPER(arguments).EndTable.call(this);
  500. if (this.table.length) {
  501. var e = this.table.length - 1, n;
  502. this.table[0][0].columnalign || (this.table[0][0].columnalign = t.ALIGN.LEFT), this.table[e][0].columnalign || (this.table[e][0].columnalign = t.ALIGN.RIGHT);
  503. var r = t.mtr;
  504. this.global.tag && (this.table[0] = [ this.global.tag ].concat(this.table[0]), delete this.global.tag, r = t.mlabeledtr), this.table[0] = r.apply(t, this.table[0]);
  505. for (n = 1, e = this.table.length; n < e; n++) this.table[n] = t.mtr.apply(t, this.table[n]);
  506. }
  507. }
  508. }), i.AMSarray = i.array.Subclass({
  509. type: "AMSarray",
  510. Init: function(e, t, n, r) {
  511. this.SUPER(arguments).Init.apply(this), this.numbered = t, this.save_notag = r.global.notag, r.global.notag = n ? null : e;
  512. },
  513. EndRow: function() {
  514. var e = t.mtr;
  515. this.global.tag && (this.row = [ this.global.tag ].concat(this.row), e = t.mlabeledtr, delete this.global.tag), this.table.push(e.apply(t, this.row)), this.row = [];
  516. },
  517. EndTable: function() {
  518. this.SUPER(arguments).EndTable.call(this), this.global.notag = this.save_notag;
  519. }
  520. }), i.start.Augment({
  521. oldCheckItem: i.start.prototype.checkItem,
  522. checkItem: function(e) {
  523. if (e.type === "stop") {
  524. var r = this.mmlData();
  525. if (this.global.tag) {
  526. var s = [ this.global.tag, t.mtd(r) ];
  527. delete this.global.tag;
  528. var o = {
  529. side: n.config.TagSide,
  530. minlabelspacing: n.config.TagIndent,
  531. columnalign: r.displayAlign
  532. };
  533. r.displayAlign === t.INDENTALIGN.LEFT ? (o.width = "100%", r.displayIndent && !String(r.displayIndent).match(/^0+(\.0*)?($|[a-z%])/) && (o.columnwidth = r.displayIndent + " fit", o.columnspacing = "0", s = [ s[0], t.mtd(), s[1] ])) : r.displayAlign === t.INDENTALIGN.RIGHT && (o.width = "100%", r.displayIndent && !String(r.displayIndent).match(/^0+(\.0*)?($|[a-z%])/) && (o.columnwidth = "fit " + r.displayIndent, o.columnspacing = "0", s[2] = t.mtd())), r = t.mtable(t.mlabeledtr.apply(t, s)).With(o);
  534. }
  535. return i.mml(r);
  536. }
  537. return this.SUPER(arguments).checkItem.call(this, e);
  538. }
  539. }), MathJax.Hub.Startup.signal.Post("TeX AMSmath Ready");
  540. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/AMSmath.js"), MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  541. var e = "1.1.2", t = MathJax.ElementJax.mml;
  542. MathJax.Hub.Insert(MathJax.InputJax.TeX.Definitions, {
  543. mathchar0mi: {
  544. digamma: "03DD",
  545. varkappa: "03F0",
  546. varGamma: [ "0393", {
  547. mathvariant: t.VARIANT.ITALIC
  548. } ],
  549. varDelta: [ "0394", {
  550. mathvariant: t.VARIANT.ITALIC
  551. } ],
  552. varTheta: [ "0398", {
  553. mathvariant: t.VARIANT.ITALIC
  554. } ],
  555. varLambda: [ "039B", {
  556. mathvariant: t.VARIANT.ITALIC
  557. } ],
  558. varXi: [ "039E", {
  559. mathvariant: t.VARIANT.ITALIC
  560. } ],
  561. varPi: [ "03A0", {
  562. mathvariant: t.VARIANT.ITALIC
  563. } ],
  564. varSigma: [ "03A3", {
  565. mathvariant: t.VARIANT.ITALIC
  566. } ],
  567. varUpsilon: [ "03A5", {
  568. mathvariant: t.VARIANT.ITALIC
  569. } ],
  570. varPhi: [ "03A6", {
  571. mathvariant: t.VARIANT.ITALIC
  572. } ],
  573. varPsi: [ "03A8", {
  574. mathvariant: t.VARIANT.ITALIC
  575. } ],
  576. varOmega: [ "03A9", {
  577. mathvariant: t.VARIANT.ITALIC
  578. } ],
  579. beth: "2136",
  580. gimel: "2137",
  581. daleth: "2138",
  582. backprime: [ "2035", {
  583. variantForm: !0
  584. } ],
  585. hslash: [ "210F", {
  586. variantForm: !0
  587. } ],
  588. varnothing: [ "2205", {
  589. variantForm: !0
  590. } ],
  591. blacktriangle: "25B2",
  592. triangledown: "25BD",
  593. blacktriangledown: "25BC",
  594. square: "25A1",
  595. Box: "25A1",
  596. blacksquare: "25A0",
  597. lozenge: "25CA",
  598. Diamond: "25CA",
  599. blacklozenge: "29EB",
  600. circledS: [ "24C8", {
  601. mathvariant: t.VARIANT.NORMAL
  602. } ],
  603. bigstar: "2605",
  604. sphericalangle: "2222",
  605. measuredangle: "2221",
  606. nexists: "2204",
  607. complement: "2201",
  608. mho: "2127",
  609. eth: [ "00F0", {
  610. mathvariant: t.VARIANT.NORMAL
  611. } ],
  612. Finv: "2132",
  613. diagup: "2571",
  614. Game: "2141",
  615. diagdown: "2572",
  616. Bbbk: [ "006B", {
  617. mathvariant: t.VARIANT.DOUBLESTRUCK
  618. } ],
  619. yen: "00A5",
  620. circledR: "00AE",
  621. checkmark: "2713",
  622. maltese: "2720"
  623. },
  624. mathchar0mo: {
  625. dotplus: "2214",
  626. ltimes: "22C9",
  627. smallsetminus: [ "2216", {
  628. variantForm: !0
  629. } ],
  630. rtimes: "22CA",
  631. Cap: "22D2",
  632. doublecap: "22D2",
  633. leftthreetimes: "22CB",
  634. Cup: "22D3",
  635. doublecup: "22D3",
  636. rightthreetimes: "22CC",
  637. barwedge: "22BC",
  638. curlywedge: "22CF",
  639. veebar: "22BB",
  640. curlyvee: "22CE",
  641. doublebarwedge: "2A5E",
  642. boxminus: "229F",
  643. circleddash: "229D",
  644. boxtimes: "22A0",
  645. circledast: "229B",
  646. boxdot: "22A1",
  647. circledcirc: "229A",
  648. boxplus: "229E",
  649. centerdot: "22C5",
  650. divideontimes: "22C7",
  651. intercal: "22BA",
  652. leqq: "2266",
  653. geqq: "2267",
  654. leqslant: "2A7D",
  655. geqslant: "2A7E",
  656. eqslantless: "2A95",
  657. eqslantgtr: "2A96",
  658. lesssim: "2272",
  659. gtrsim: "2273",
  660. lessapprox: "2A85",
  661. gtrapprox: "2A86",
  662. approxeq: "224A",
  663. lessdot: "22D6",
  664. gtrdot: "22D7",
  665. lll: "22D8",
  666. llless: "22D8",
  667. ggg: "22D9",
  668. gggtr: "22D9",
  669. lessgtr: "2276",
  670. gtrless: "2277",
  671. lesseqgtr: "22DA",
  672. gtreqless: "22DB",
  673. lesseqqgtr: "2A8B",
  674. gtreqqless: "2A8C",
  675. doteqdot: "2251",
  676. Doteq: "2251",
  677. eqcirc: "2256",
  678. risingdotseq: "2253",
  679. circeq: "2257",
  680. fallingdotseq: "2252",
  681. triangleq: "225C",
  682. backsim: "223D",
  683. thicksim: [ "223C", {
  684. variantForm: !0
  685. } ],
  686. backsimeq: "22CD",
  687. thickapprox: "2248",
  688. subseteqq: "2AC5",
  689. supseteqq: "2AC6",
  690. Subset: "22D0",
  691. Supset: "22D1",
  692. sqsubset: "228F",
  693. sqsupset: "2290",
  694. preccurlyeq: "227C",
  695. succcurlyeq: "227D",
  696. curlyeqprec: "22DE",
  697. curlyeqsucc: "22DF",
  698. precsim: "227E",
  699. succsim: "227F",
  700. precapprox: "2AB7",
  701. succapprox: "2AB8",
  702. vartriangleleft: "22B2",
  703. lhd: "22B2",
  704. vartriangleright: "22B3",
  705. rhd: "22B3",
  706. trianglelefteq: "22B4",
  707. unlhd: "22B4",
  708. trianglerighteq: "22B5",
  709. unrhd: "22B5",
  710. vDash: "22A8",
  711. Vdash: "22A9",
  712. Vvdash: "22AA",
  713. smallsmile: "2323",
  714. shortmid: [ "2223", {
  715. variantForm: !0
  716. } ],
  717. smallfrown: "2322",
  718. shortparallel: [ "2225", {
  719. variantForm: !0
  720. } ],
  721. bumpeq: "224F",
  722. between: "226C",
  723. Bumpeq: "224E",
  724. pitchfork: "22D4",
  725. varpropto: "221D",
  726. backepsilon: "220D",
  727. blacktriangleleft: "25C0",
  728. blacktriangleright: "25B6",
  729. therefore: "2234",
  730. because: "2235",
  731. eqsim: "2242",
  732. vartriangle: [ "25B3", {
  733. variantForm: !0
  734. } ],
  735. Join: "22C8",
  736. nless: "226E",
  737. ngtr: "226F",
  738. nleq: "2270",
  739. ngeq: "2271",
  740. nleqslant: [ "2A87", {
  741. variantForm: !0
  742. } ],
  743. ngeqslant: [ "2A88", {
  744. variantForm: !0
  745. } ],
  746. nleqq: [ "2270", {
  747. variantForm: !0
  748. } ],
  749. ngeqq: [ "2271", {
  750. variantForm: !0
  751. } ],
  752. lneq: "2A87",
  753. gneq: "2A88",
  754. lneqq: "2268",
  755. gneqq: "2269",
  756. lvertneqq: [ "2268", {
  757. variantForm: !0
  758. } ],
  759. gvertneqq: [ "2269", {
  760. variantForm: !0
  761. } ],
  762. lnsim: "22E6",
  763. gnsim: "22E7",
  764. lnapprox: "2A89",
  765. gnapprox: "2A8A",
  766. nprec: "2280",
  767. nsucc: "2281",
  768. npreceq: [ "22E0", {
  769. variantForm: !0
  770. } ],
  771. nsucceq: [ "22E1", {
  772. variantForm: !0
  773. } ],
  774. precneqq: "2AB5",
  775. succneqq: "2AB6",
  776. precnsim: "22E8",
  777. succnsim: "22E9",
  778. precnapprox: "2AB9",
  779. succnapprox: "2ABA",
  780. nsim: "2241",
  781. ncong: "2246",
  782. nshortmid: [ "2224", {
  783. variantForm: !0
  784. } ],
  785. nshortparallel: [ "2226", {
  786. variantForm: !0
  787. } ],
  788. nmid: "2224",
  789. nparallel: "2226",
  790. nvdash: "22AC",
  791. nvDash: "22AD",
  792. nVdash: "22AE",
  793. nVDash: "22AF",
  794. ntriangleleft: "22EA",
  795. ntriangleright: "22EB",
  796. ntrianglelefteq: "22EC",
  797. ntrianglerighteq: "22ED",
  798. nsubseteq: "2288",
  799. nsupseteq: "2289",
  800. nsubseteqq: [ "2288", {
  801. variantForm: !0
  802. } ],
  803. nsupseteqq: [ "2289", {
  804. variantForm: !0
  805. } ],
  806. subsetneq: "228A",
  807. supsetneq: "228B",
  808. varsubsetneq: [ "228A", {
  809. variantForm: !0
  810. } ],
  811. varsupsetneq: [ "228B", {
  812. variantForm: !0
  813. } ],
  814. subsetneqq: "2ACB",
  815. supsetneqq: "2ACC",
  816. varsubsetneqq: [ "2ACB", {
  817. variantForm: !0
  818. } ],
  819. varsupsetneqq: [ "2ACC", {
  820. variantForm: !0
  821. } ],
  822. leftleftarrows: "21C7",
  823. rightrightarrows: "21C9",
  824. leftrightarrows: "21C6",
  825. rightleftarrows: "21C4",
  826. Lleftarrow: "21DA",
  827. Rrightarrow: "21DB",
  828. twoheadleftarrow: "219E",
  829. twoheadrightarrow: "21A0",
  830. leftarrowtail: "21A2",
  831. rightarrowtail: "21A3",
  832. looparrowleft: "21AB",
  833. looparrowright: "21AC",
  834. leftrightharpoons: "21CB",
  835. rightleftharpoons: [ "21CC", {
  836. variantForm: !0
  837. } ],
  838. curvearrowleft: "21B6",
  839. curvearrowright: "21B7",
  840. circlearrowleft: "21BA",
  841. circlearrowright: "21BB",
  842. Lsh: "21B0",
  843. Rsh: "21B1",
  844. upuparrows: "21C8",
  845. downdownarrows: "21CA",
  846. upharpoonleft: "21BF",
  847. upharpoonright: "21BE",
  848. downharpoonleft: "21C3",
  849. restriction: "21BE",
  850. multimap: "22B8",
  851. downharpoonright: "21C2",
  852. leftrightsquigarrow: "21AD",
  853. rightsquigarrow: "21DD",
  854. leadsto: "21DD",
  855. dashrightarrow: "21E2",
  856. dashleftarrow: "21E0",
  857. nleftarrow: "219A",
  858. nrightarrow: "219B",
  859. nLeftarrow: "21CD",
  860. nRightarrow: "21CF",
  861. nleftrightarrow: "21AE",
  862. nLeftrightarrow: "21CE"
  863. },
  864. delimiter: {
  865. "\\ulcorner": "250C",
  866. "\\urcorner": "2510",
  867. "\\llcorner": "2514",
  868. "\\lrcorner": "2518"
  869. },
  870. macros: {
  871. implies: [ "Macro", "\\;\\Longrightarrow\\;" ],
  872. impliedby: [ "Macro", "\\;\\Longleftarrow\\;" ]
  873. }
  874. });
  875. var n = t.mo.OPTYPES.REL;
  876. MathJax.Hub.Insert(t.mo.prototype, {
  877. OPTABLE: {
  878. infix: {
  879. "\u2322": n,
  880. "\u2323": n,
  881. "\u25b3": n,
  882. "\ue006": n,
  883. "\ue007": n,
  884. "\ue00c": n,
  885. "\ue00d": n,
  886. "\ue00e": n,
  887. "\ue00f": n,
  888. "\ue010": n,
  889. "\ue011": n,
  890. "\ue016": n,
  891. "\ue017": n,
  892. "\ue018": n,
  893. "\ue019": n,
  894. "\ue01a": n,
  895. "\ue01b": n,
  896. "\ue04b": n,
  897. "\ue04f": n
  898. }
  899. }
  900. });
  901. }), MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready", function() {
  902. var e = MathJax.OutputJax["HTML-CSS"], t = e.FONTDATA.VARIANT;
  903. e.fontInUse === "TeX" && (t["-TeX-variant"] = {
  904. fonts: [ "MathJax_AMS", "MathJax_Main", "MathJax_Size1" ],
  905. remap: {
  906. 8808: 57356,
  907. 8809: 57357,
  908. 8816: 57361,
  909. 8817: 57358,
  910. 10887: 57360,
  911. 10888: 57359,
  912. 8740: 57350,
  913. 8742: 57351,
  914. 8840: 57366,
  915. 8841: 57368,
  916. 8842: 57370,
  917. 8843: 57371,
  918. 10955: 57367,
  919. 10956: 57369,
  920. 988: 57352,
  921. 1008: 57353
  922. }
  923. }, e.msieIE6 && MathJax.Hub.Insert(t["-TeX-variant"].remap, {
  924. 8592: [ 58049, "-WinIE6" ],
  925. 8594: [ 58048, "-WinIE6" ],
  926. 8739: [ 58050, "-WinIE6" ],
  927. 8741: [ 58051, "-WinIE6" ],
  928. 8764: [ 58052, "-WinIE6" ],
  929. 9651: [ 58067, "-WinIE6" ]
  930. })), e.fontInUse === "STIX" && MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  931. var e = MathJax.InputJax.TeX.Definitions;
  932. e.mathchar0mi.varnothing = "2205", e.mathchar0mi.hslash = "210F", e.mathchar0mi.blacktriangle = "25B4", e.mathchar0mi.blacktriangledown = "25BE", e.mathchar0mi.square = "25FB", e.mathchar0mi.blacksquare = "25FC", e.mathchar0mi.vartriangle = [ "25B3", {
  933. mathsize: "71%"
  934. } ], e.mathchar0mi.triangledown = [ "25BD", {
  935. mathsize: "71%"
  936. } ], e.mathchar0mo.blacktriangleleft = "25C2", e.mathchar0mo.blacktriangleright = "25B8", e.mathchar0mo.smallsetminus = "2216", MathJax.Hub.Insert(t["-STIX-variant"], {
  937. remap: {
  938. 10887: 57360,
  939. 10888: 57359,
  940. 8816: 57361,
  941. 8817: 57358,
  942. 8928: 57419,
  943. 8929: 57423,
  944. 8840: 57366,
  945. 8841: 57368
  946. }
  947. });
  948. }), MathJax.Hub.Startup.signal.Post("TeX AMSsymbols Ready");
  949. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/AMSsymbols.js"), function() {
  950. var e = "1.1", t = MathJax.Hub.CombineConfig("TeX.noErrors", {
  951. multiLine: !0,
  952. inlineDelimiters: [ "", "" ],
  953. style: {
  954. "font-family": "serif",
  955. "font-size": "80%",
  956. "text-align": "left",
  957. color: "black",
  958. padding: "1px 3px",
  959. border: "1px solid"
  960. }
  961. }), n = "\u00a0";
  962. MathJax.Extension["TeX/noErrors"] = {
  963. version: e,
  964. config: t
  965. }, MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  966. MathJax.InputJax.TeX.Augment({
  967. formatError: function(e, r, i, s) {
  968. var o = t.inlineDelimiters, u = i || t.multiLine;
  969. return i || (r = o[0] + r + o[1]), u ? r = r.replace(/ /g, n) : r = r.replace(/\n/g, " "), MathJax.ElementJax.mml.merror(r).With({
  970. isError: !0,
  971. multiLine: u
  972. });
  973. }
  974. });
  975. }), MathJax.Hub.Register.StartupHook("HTML-CSS Jax Config", function() {
  976. MathJax.Hub.Config({
  977. "HTML-CSS": {
  978. styles: {
  979. ".MathJax .merror": MathJax.Hub.Insert({
  980. "font-style": null,
  981. "background-color": null,
  982. "vertical-align": MathJax.Hub.Browser.isMSIE && t.multiLine ? "-2px" : ""
  983. }, t.style)
  984. }
  985. }
  986. });
  987. });
  988. }(), MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready", function() {
  989. var e = MathJax.ElementJax.mml, t = MathJax.OutputJax["HTML-CSS"], n = e.math.prototype.toHTML;
  990. e.math.Augment({
  991. toHTML: function(e, t) {
  992. return this.data[0] && this.data[0].data[0] && this.data[0].data[0].isError ? this.data[0].data[0].toHTML(e) : n.call(this, e, t);
  993. }
  994. }), e.merror.Augment({
  995. toHTML: function(n) {
  996. if (!this.isError) return e.mbase.prototype.toHTML.call(this, n);
  997. n = this.HTMLcreateSpan(n), this.multiLine && (n.style.display = "inline-block");
  998. var r = this.data[0].data[0].data.join("").split(/\n/);
  999. for (var i = 0, s = r.length; i < s; i++) t.addText(n, r[i]), i !== s - 1 && t.addElement(n, "br");
  1000. var o = t.getHD(n.parentNode), u = t.getW(n.parentNode);
  1001. if (s > 1) {
  1002. var f = (o.h + o.d) / 2, l = t.TeX.x_height / 2, c = t.config.styles[".MathJax .merror"]["font-size"];
  1003. c && c.match(/%/) && (l *= parseInt(c) / 100), n.parentNode.style.verticalAlign = t.Em(o.d + (l - f)), o.h = l + f, o.d = f - l;
  1004. }
  1005. return n.bbox = {
  1006. h: o.h,
  1007. d: o.d,
  1008. w: u,
  1009. lw: 0,
  1010. rw: u
  1011. }, n;
  1012. }
  1013. }), MathJax.Hub.Startup.signal.Post("TeX noErrors Ready");
  1014. }), MathJax.Hub.Register.StartupHook("NativeMML Jax Ready", function() {
  1015. var e = MathJax.ElementJax.mml, t = MathJax.Extension["TeX/noErrors"].config, n = e.math.prototype.toNativeMML;
  1016. e.math.Augment({
  1017. toNativeMML: function(e) {
  1018. return this.data[0] && this.data[0].data[0] && this.data[0].data[0].isError ? this.data[0].data[0].toNativeMML(e) : n.call(this, e);
  1019. }
  1020. }), e.merror.Augment({
  1021. toNativeMML: function(n) {
  1022. if (!this.isError) return e.mbase.prototype.toNativeMML.call(this, n);
  1023. n = n.appendChild(document.createElement("span"));
  1024. var r = this.data[0].data[0].data.join("").split(/\n/);
  1025. for (var i = 0, s = r.length; i < s; i++) n.appendChild(document.createTextNode(r[i])), i !== s - 1 && n.appendChild(document.createElement("br"));
  1026. this.multiLine && (n.style.display = "inline-block", s > 1 && (n.style.verticalAlign = "middle"));
  1027. for (var o in t.style) if (t.style.hasOwnProperty(o)) {
  1028. var u = o.replace(/-./g, function(e) {
  1029. return e.charAt(1).toUpperCase();
  1030. });
  1031. n.style[u] = t.style[o];
  1032. }
  1033. return n;
  1034. }
  1035. }), MathJax.Hub.Startup.signal.Post("TeX noErrors Ready");
  1036. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/noErrors.js"), MathJax.Extension["TeX/noUndefined"] = {
  1037. version: "1.1",
  1038. config: MathJax.Hub.CombineConfig("TeX.noUndefined", {
  1039. attributes: {
  1040. mathcolor: "red"
  1041. }
  1042. })
  1043. }, MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  1044. var e = MathJax.Extension["TeX/noUndefined"].config, t = MathJax.ElementJax.mml;
  1045. MathJax.InputJax.TeX.Parse.Augment({
  1046. csUndefined: function(n) {
  1047. this.Push(t.mtext(n).With(e.attributes));
  1048. }
  1049. }), MathJax.Hub.Startup.signal.Post("TeX noUndefined Ready");
  1050. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/noUndefined.js"), MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  1051. var e = "1.1", t = MathJax.InputJax.TeX, n = t.Definitions;
  1052. MathJax.Hub.Insert(n, {
  1053. macros: {
  1054. newcommand: "NewCommand",
  1055. renewcommand: "NewCommand",
  1056. newenvironment: "NewEnvironment",
  1057. def: "MacroDef"
  1058. }
  1059. }), t.Parse.Augment({
  1060. NewCommand: function(e) {
  1061. var r = this.trimSpaces(this.GetArgument(e)), i = this.trimSpaces(this.GetBrackets(e)), s = this.GetArgument(e);
  1062. i === "" && (i = null), r.charAt(0) === "\\" && (r = r.substr(1)), r.match(/^(.|[a-z]+)$/i) || t.Error("Illegal control sequence name for " + e), i != null && !i.match(/^[0-9]+$/) && t.Error("Illegal number of parameters specified in " + e), n.macros[r] = [ "Macro", s, i ];
  1063. },
  1064. NewEnvironment: function(e) {
  1065. var r = this.trimSpaces(this.GetArgument(e)), i = this.trimSpaces(this.GetBrackets(e)), s = this.GetArgument(e), o = this.GetArgument(e);
  1066. i === "" && (i = null), i != null && !i.match(/^[0-9]+$/) && t.Error("Illegal number of parameters specified in " + e), n.environment[r] = [ "BeginEnv", "EndEnv", s, o, i ];
  1067. },
  1068. MacroDef: function(e) {
  1069. var t = this.GetCSname(e), r = this.GetTemplate(e, "\\" + t), i = this.GetArgument(e);
  1070. r instanceof Array ? n.macros[t] = [ "MacroWithTemplate", i, r[0], r[1] ] : n.macros[t] = [ "Macro", i, r ];
  1071. },
  1072. GetCSname: function(e) {
  1073. var n = this.GetNext();
  1074. n !== "\\" && t.Error("\\ must be followed by a control sequence");
  1075. var r = this.trimSpaces(this.GetArgument(e));
  1076. return r.substr(1);
  1077. },
  1078. GetTemplate: function(e, n) {
  1079. var r, i = [], s = 0;
  1080. r = this.GetNext();
  1081. var o = this.i;
  1082. while (this.i < this.string.length) {
  1083. r = this.GetNext();
  1084. if (r === "#") o !== this.i && (i[s] = this.string.substr(o, this.i - o)), r = this.string.charAt(++this.i), r.match(/^[1-9]$/) || t.Error("Illegal use of # in template for " + n), parseInt(r) != ++s && t.Error("Parameters for " + n + " must be numbered sequentially"), o = this.i + 1; else if (r === "{") return o !== this.i && (i[s] = this.string.substr(o, this.i - o)), i.length > 0 ? [ s, i ] : s;
  1085. this.i++;
  1086. }
  1087. t.Error("Missing replacement string for definition of " + e);
  1088. },
  1089. MacroWithTemplate: function(e, n, r, i) {
  1090. if (r) {
  1091. var s = [];
  1092. this.GetNext(), i[0] && !this.MatchParam(i[0]) && t.Error("Use of " + e + " doesn't match its definition");
  1093. for (var o = 0; o < r; o++) s.push(this.GetParameter(e, i[o + 1]));
  1094. n = this.SubstituteArgs(s, n);
  1095. }
  1096. this.string = this.AddArgs(n, this.string.slice(this.i)), this.i = 0, ++this.macroCount > t.config.MAXMACROS && t.Error("MathJax maximum macro substitution count exceeded; is there a recursive macro call?");
  1097. },
  1098. BeginEnv: function(e, t, n, r) {
  1099. if (r) {
  1100. var i = [];
  1101. for (var s = 0; s < r; s++) i.push(this.GetArgument("\\begin{" + name + "}"));
  1102. t = this.SubstituteArgs(i, t), n = this.SubstituteArgs(i, n);
  1103. }
  1104. return e.edef = n, this.string = this.AddArgs(t, this.string.slice(this.i)), this.i = 0, e;
  1105. },
  1106. EndEnv: function(e, t) {
  1107. return this.string = this.AddArgs(e.edef, this.string.slice(this.i)), this.i = 0, t;
  1108. },
  1109. GetParameter: function(e, n) {
  1110. if (n == null) return this.GetArgument(e);
  1111. var r = this.i, i = 0, s = 0;
  1112. while (this.i < this.string.length) if (this.string.charAt(this.i) === "{") this.i === r && (s = 1), this.GetArgument(e), i = this.i - r; else {
  1113. if (this.MatchParam(n)) return s && (r++, i -= 2), this.string.substr(r, i);
  1114. this.i++, i++, s = 0;
  1115. }
  1116. t.Error("Runaway argument for " + e + "?");
  1117. },
  1118. MatchParam: function(e) {
  1119. return this.string.substr(this.i, e.length) !== e ? 0 : (this.i += e.length, 1);
  1120. }
  1121. }), t.Environment = function(e) {
  1122. n.environment[e] = [ "BeginEnv", "EndEnv" ].concat([].slice.call(arguments, 1));
  1123. }, MathJax.Hub.Startup.signal.Post("TeX newcommand Ready");
  1124. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/newcommand.js"), MathJax.Hub.Register.StartupHook("TeX Jax Ready", function() {
  1125. var e = "1.1", t = MathJax.ElementJax.mml, n = MathJax.InputJax.TeX, r = n.Definitions, i = {};
  1126. i[t.VARIANT.NORMAL] = t.VARIANT.BOLD, i[t.VARIANT.ITALIC] = t.VARIANT.BOLDITALIC, i[t.VARIANT.FRAKTUR] = t.VARIANT.BOLDFRAKTUR, i[t.VARIANT.SCRIPT] = t.VARIANT.BOLDSCRIPT, i[t.VARIANT.SANSSERIF] = t.VARIANT.BOLDSANSSERIF, i["-tex-caligraphic"] = "-tex-caligraphic-bold", i["-tex-oldstyle"] = "-tex-oldstyle-bold", r.macros.boldsymbol = "Boldsymbol", n.Parse.Augment({
  1127. mmlToken: function(e) {
  1128. if (this.stack.env.boldsymbol) {
  1129. var n = e.Get("mathvariant");
  1130. n == null ? e.mathvariant = t.VARIANT.BOLD : e.mathvariant = i[n] || n;
  1131. }
  1132. return e;
  1133. },
  1134. Boldsymbol: function(e) {
  1135. var t = this.stack.env.boldsymbol, n = this.stack.env.font;
  1136. this.stack.env.boldsymbol = !0, this.stack.env.font = null;
  1137. var r = this.ParseArg(e);
  1138. this.stack.env.font = n, this.stack.env.boldsymbol = t, this.Push(r);
  1139. }
  1140. });
  1141. }), MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready", function() {
  1142. var e = MathJax.OutputJax["HTML-CSS"], t = e.FONTDATA.FONTS, n = e.FONTDATA.VARIANT;
  1143. e.fontInUse === "TeX" ? (t["MathJax_Caligraphic-bold"] = "Caligraphic/Bold/Main.js", n["-tex-caligraphic-bold"] = {
  1144. fonts: [ "MathJax_Caligraphic-bold", "MathJax_Main-bold", "MathJax_Main", "MathJax_Math", "MathJax_Size1" ],
  1145. offsetA: 65,
  1146. variantA: "bold-italic"
  1147. }, n["-tex-oldstyle-bold"] = {
  1148. fonts: [ "MathJax_Caligraphic-bold", "MathJax_Main-bold", "MathJax_Main", "MathJax_Math", "MathJax_Size1" ]
  1149. }, e.msieCheckGreek && e.Font.testFont({
  1150. family: "MathJax_Greek",
  1151. weight: "bold",
  1152. style: "italic",
  1153. testString: e.msieCheckGreek
  1154. }) && (n["bold-italic"].offsetG = 913, n["bold-italic"].variantG = "-Greek-Bold-Italic", n["-Greek-Bold-Italic"] = {
  1155. fonts: [ "MathJax_Greek-bold-italic" ]
  1156. }, t["MathJax_Greek-bold-italic"] = "Greek/BoldItalic/Main.js"), MathJax.Hub.Browser.isChrome && !MathJax.Hub.Browser.versionAtLeast("5.0") && (n["-tex-caligraphic-bold"].remap = {
  1157. 84: [ 58096, "-WinChrome" ]
  1158. })) : e.fontInUse === "STIX" && (n["-tex-caligraphic-bold"] = {
  1159. fonts: [ "STIXGeneral-bold-italic", "STIXNonUnicode-bold-italic", "STIXNonUnicode", "STIXGeneral", "STIXSizeOneSym" ],
  1160. offsetA: 57927,
  1161. noLowerCase: 1
  1162. }, n["-tex-oldstyle-bold"] = {
  1163. fonts: [ "STIXGeneral-bold", "STIXNonUnicode-bold", "STIXGeneral", "STIXSizeOneSym" ],
  1164. offsetN: 57955,
  1165. remap: {
  1166. 57956: 57959,
  1167. 57957: 57963,
  1168. 57958: 57967,
  1169. 57959: 57971,
  1170. 57960: 57975,
  1171. 57961: 57979,
  1172. 57962: 57983,
  1173. 57963: 57987,
  1174. 57964: 57991
  1175. }
  1176. }), MathJax.Hub.Startup.signal.Post("TeX boldsymbol Ready");
  1177. }), MathJax.Ajax.loadComplete("[MathJax]/extensions/TeX/boldsymbol.js"), MathJax.Extension.tex2jax = {
  1178. version: "1.1.3",
  1179. config: {
  1180. inlineMath: [ [ "\\(", "\\)" ] ],
  1181. displayMath: [ [ "$$", "$$" ], [ "\\[", "\\]" ] ],
  1182. skipTags: [ "script", "noscript", "style", "textarea", "pre", "code" ],
  1183. ignoreClass: "tex2jax_ignore",
  1184. processClass: "tex2jax_process",
  1185. processEscapes: !1,
  1186. processEnvironments: !0,
  1187. preview: "TeX"
  1188. },
  1189. PreProcess: function(e) {
  1190. this.configured || (this.config = MathJax.Hub.CombineConfig("tex2jax", this.config), this.config.Augment && MathJax.Hub.Insert(this, this.config.Augment), typeof this.config.previewTeX != "undefined" && !this.config.previewTeX && (this.config.preview = "none"), this.configured = !0), typeof e == "string" && (e = document.getElementById(e)), e || (e = document.body), this.createPatterns(), this.scanElement(e, e.nextSibling);
  1191. },
  1192. createPatterns: function() {
  1193. var e = [], t, n, r = this.config;
  1194. this.match = {};
  1195. for (t = 0, n = r.inlineMath.length; t < n; t++) e.push(this.patternQuote(r.inlineMath[t][0])), this.match[r.inlineMath[t][0]] = {
  1196. mode: "",
  1197. end: r.inlineMath[t][1],
  1198. pattern: this.endPattern(r.inlineMath[t][1])
  1199. };
  1200. for (t = 0, n = r.displayMath.length; t < n; t++) e.push(this.patternQuote(r.displayMath[t][0])), this.match[r.displayMath[t][0]] = {
  1201. mode: "; mode=display",
  1202. end: r.displayMath[t][1],
  1203. pattern: this.endPattern(r.displayMath[t][1])
  1204. };
  1205. this.start = new RegExp(e.sort(this.sortLength).join("|") + (r.processEnvironments ? "|\\\\begin\\{([^}]*)\\}" : "") + (r.processEscapes ? "|\\\\*\\\\\\$" : ""), "g"), this.skipTags = new RegExp("^(" + r.skipTags.join("|") + ")$", "i"), this.ignoreClass = new RegExp("(^| )(" + r.ignoreClass + ")( |$)"), this.processClass = new RegExp("(^| )(" + r.processClass + ")( |$)");
  1206. },
  1207. patternQuote: function(e) {
  1208. return e.replace(/([\^$(){}+*?\-|\[\]\:\\])/g, "\\$1");
  1209. },
  1210. endPattern: function(e) {
  1211. return new RegExp(this.patternQuote(e) + "|\\\\.", "g");
  1212. },
  1213. sortLength: function(e, t) {
  1214. return e.length !== t.length ? t.length - e.length : e == t ? 0 : e < t ? -1 : 1;
  1215. },
  1216. scanElement: function(e, t, n) {
  1217. var r, i, s;
  1218. while (e && e != t) e.nodeName.toLowerCase() === "#text" ? n || (e = this.scanText(e)) : (r = typeof e.className == "undefined" ? "" : e.className, i = typeof e.tagName == "undefined" ? "" : e.tagName, typeof r != "string" && (r = String(r)), e.firstChild && !r.match(/(^| )MathJax/) && !this.skipTags.exec(i) && (s = (n || this.ignoreClass.exec(r)) && !this.processClass.exec(r), this.scanElement(e.firstChild, t, s))), e && (e = e.nextSibling);
  1219. },
  1220. scanText: function(e) {
  1221. if (e.nodeValue.replace(/\s+/, "") == "") return e;
  1222. var t, n;
  1223. this.search = {
  1224. start: !0
  1225. }, this.pattern = this.start;
  1226. while (e) {
  1227. this.pattern.lastIndex = 0;
  1228. while (e && e.nodeName.toLowerCase() === "#text" && (t = this.pattern.exec(e.nodeValue))) this.search.start ? e = this.startMatch(t, e) : e = this.endMatch(t, e);
  1229. this.search.matched && (e = this.encloseMath(e));
  1230. if (e) {
  1231. do n = e, e = e.nextSibling; while (e && (e.nodeName.toLowerCase() === "br" || e.nodeName.toLowerCase() === "#comment"));
  1232. if (!e || e.nodeName !== "#text") return n;
  1233. }
  1234. }
  1235. return e;
  1236. },
  1237. startMatch: function(e, t) {
  1238. var n = this.match[e[0]];
  1239. if (n != null) this.search = {
  1240. end: n.end,
  1241. mode: n.mode,
  1242. open: t,
  1243. olen: e[0].length,
  1244. opos: this.pattern.lastIndex - e[0].length
  1245. }, this.switchPattern(n.pattern); else if (e[0].substr(0, 6) === "\\begin") this.search = {
  1246. end: "\\end{" + e[1] + "}",
  1247. mode: "; mode=display",
  1248. open: t,
  1249. olen: 0,
  1250. opos: this.pattern.lastIndex - e[0].length,
  1251. isBeginEnd: !0
  1252. }, this.switchPattern(this.endPattern(this.search.end)); else {
  1253. var r = e[0].substr(0, e[0].length - 1), i, s;
  1254. r.length % 2 === 0 ? (s = [ r.replace(/\\\\/g, "\\") ], i = 1) : (s = [ r.substr(1).replace(/\\\\/g, "\\"), "$" ], i = 0), s = MathJax.HTML.Element("span", null, s);
  1255. var o = MathJax.HTML.TextNode(t.nodeValue.substr(0, e.index));
  1256. t.nodeValue = t.nodeValue.substr(e.index + e[0].length - i), t.parentNode.insertBefore(s, t), t.parentNode.insertBefore(o, s), this.pattern.lastIndex = i;
  1257. }
  1258. return t;
  1259. },
  1260. endMatch: function(e, t) {
  1261. return e[0] == this.search.end && (this.search.close = t, this.search.cpos = this.pattern.lastIndex, this.search.clen = this.search.isBeginEnd ? 0 : e[0].length, this.search.matched = !0, t = this.encloseMath(t), this.switchPattern(this.start)), t;
  1262. },
  1263. switchPattern: function(e) {
  1264. e.lastIndex = this.pattern.lastIndex, this.pattern = e, this.search.start = e === this.start;
  1265. },
  1266. encloseMath: function(e) {
  1267. var t = this.search, n = t.close, r, i;
  1268. t.cpos === n.length ? n = n.nextSibling : n = n.splitText(t.cpos), n || (r = n = MathJax.HTML.addText(t.close.parentNode, "")), t.close = n, i = t.opos ? t.open.splitText(t.opos) : t.open;
  1269. while (i.nextSibling && i.nextSibling !== n) i.nextSibling.nodeValue !== null ? i.nextSibling.nodeName === "#comment" ? i.nodeValue += i.nextSibling.nodeValue.replace(/^\[CDATA\[((.|\n|\r)*)\]\]$/, "$1") : i.nodeValue += i.nextSibling.nodeValue : this.msieNewlineBug ? i.nodeValue += i.nextSibling.nodeName.toLowerCase() === "br" ? "\n" : " " : i.nodeValue += " ", i.parentNode.removeChild(i.nextSibling);
  1270. var s = i.nodeValue.substr(t.olen, i.nodeValue.length - t.olen - t.clen);
  1271. return i.parentNode.removeChild(i), this.config.preview !== "none" && this.createPreview(t.mode, s), i = this.createMathTag(t.mode, s), this.search = {}, this.pattern.lastIndex = 0, r && r.parentNode.removeChild(r), i;
  1272. },
  1273. insertNode: function(e) {
  1274. var t = this.search;
  1275. t.close.parentNode.insertBefore(e, t.close);
  1276. },
  1277. createPreview: function(e, t) {
  1278. var n;
  1279. this.config.preview === "TeX" ? n = [ this.filterTeX(t) ] : this.config.preview instanceof Array && (n = this.config.preview), n && (n = MathJax.HTML.Element("span", {
  1280. className: MathJax.Hub.config.preRemoveClass
  1281. }, n), this.insertNode(n));
  1282. },
  1283. createMathTag: function(e, t) {
  1284. var n = document.createElement("script");
  1285. return n.type = "math/tex" + e, MathJax.HTML.setScript(n, t), this.insertNode(n), n;
  1286. },
  1287. filterTeX: function(e) {
  1288. return e;
  1289. },
  1290. msieNewlineBug: MathJax.Hub.Browser.isMSIE && document.documentMode < 9
  1291. }, MathJax.Hub.Register.PreProcessor([ "PreProcess", MathJax.Extension.tex2jax ]), MathJax.Ajax.loadComplete("[MathJax]/extensions/tex2jax.js"), MathJax.ElementJax.mml = MathJax.ElementJax({
  1292. mimeType: "jax/mml"
  1293. }, {
  1294. id: "mml",
  1295. version: "1.1.1",
  1296. directory: MathJax.ElementJax.directory + "/mml",
  1297. extensionDir: MathJax.ElementJax.extensionDir + "/mml",
  1298. optableDir: MathJax.ElementJax.directory + "/mml/optable"
  1299. }), MathJax.ElementJax.mml.Augment({
  1300. Init: function() {
  1301. arguments.length === 1 && arguments[0].type === "math" ? this.root = arguments[0] : this.root = MathJax.ElementJax.mml.math.apply(this, arguments), this.root.mode && (!this.root.display && this.root.mode === "display" && (this.root.display = "block"), delete this.root.mode);
  1302. }
  1303. }, {
  1304. INHERIT: "_inherit_",
  1305. AUTO: "_auto_",
  1306. SIZE: {
  1307. INFINITY: "infinity",
  1308. SMALL: "small",
  1309. NORMAL: "normal",
  1310. BIG: "big"
  1311. },
  1312. COLOR: {
  1313. TRANSPARENT: "transparent"
  1314. },
  1315. VARIANT: {
  1316. NORMAL: "normal",
  1317. BOLD: "bold",
  1318. ITALIC: "italic",
  1319. BOLDITALIC: "bold-italic",
  1320. DOUBLESTRUCK: "double-struck",
  1321. FRAKTUR: "fraktur",
  1322. BOLDFRAKTUR: "bold-fraktur",
  1323. SCRIPT: "script",
  1324. BOLDSCRIPT: "bold-script",
  1325. SANSSERIF: "sans-serif",
  1326. BOLDSANSSERIF: "bold-sans-serif",
  1327. SANSSERIFITALIC: "sans-serif-italic",
  1328. SANSSERIFBOLDITALIC: "sans-serif-bold-italic",
  1329. MONOSPACE: "monospace",
  1330. INITIAL: "inital",
  1331. TAILED: "tailed",
  1332. LOOPED: "looped",
  1333. STRETCHED: "stretched",
  1334. CALIGRAPHIC: "-tex-caligraphic",
  1335. OLDSTYLE: "-tex-oldstyle"
  1336. },
  1337. FORM: {
  1338. PREFIX: "prefix",
  1339. INFIX: "infix",
  1340. POSTFIX: "postfix"
  1341. },
  1342. LINEBREAK: {
  1343. AUTO: "auto",
  1344. NEWLINE: "newline",
  1345. NOBREAK: "nobreak",
  1346. GOODBREAK: "goodbreak",
  1347. BADBREAK: "badbreak"
  1348. },
  1349. LINEBREAKSTYLE: {
  1350. BEFORE: "before",
  1351. AFTER: "after",
  1352. DUPLICATE: "duplicate",
  1353. INFIXLINBREAKSTYLE: "infixlinebreakstyle"
  1354. },
  1355. INDENTALIGN: {
  1356. LEFT: "left",
  1357. CENTER: "center",
  1358. RIGHT: "right",
  1359. AUTO: "auto",
  1360. ID: "id",
  1361. INDENTALIGN: "indentalign"
  1362. },
  1363. INDENTSHIFT: {
  1364. INDENTSHIFT: "indentshift"
  1365. },
  1366. LINETHICKNESS: {
  1367. THIN: "thin",
  1368. MEDIUM: "medium",
  1369. THICK: "thick"
  1370. },
  1371. NOTATION: {
  1372. LONGDIV: "longdiv",
  1373. ACTUARIAL: "actuarial",
  1374. RADICAL: "radical",
  1375. BOX: "box",
  1376. ROUNDEDBOX: "roundedbox",
  1377. CIRCLE: "circle",
  1378. LEFT: "left",
  1379. RIGHT: "right",
  1380. TOP: "top",
  1381. BOTTOM: "bottom",
  1382. UPDIAGONALSTRIKE: "updiagonalstrike",
  1383. DOWNDIAGONALSTRIKE: "downdiagonalstrike",
  1384. VERTICALSTRIKE: "verticalstrike",
  1385. HORIZONTALSTRIKE: "horizontalstrike",
  1386. MADRUWB: "madruwb"
  1387. },
  1388. ALIGN: {
  1389. TOP: "top",
  1390. BOTTOM: "bottom",
  1391. CENTER: "center",
  1392. BASELINE: "baseline",
  1393. AXIS: "axis",
  1394. LEFT: "left",
  1395. RIGHT: "right"
  1396. },
  1397. LINES: {
  1398. NONE: "none",
  1399. SOLID: "solid",
  1400. DASHED: "dashed"
  1401. },
  1402. SIDE: {
  1403. LEFT: "left",
  1404. RIGHT: "right",
  1405. LEFTOVERLAP: "leftoverlap",
  1406. RIGHTOVERLAP: "rightoverlap"
  1407. },
  1408. WIDTH: {
  1409. AUTO: "auto",
  1410. FIT: "fit"
  1411. },
  1412. ACTIONTYPE: {
  1413. TOGGLE: "toggle",
  1414. STATUSLINE: "statusline",
  1415. TOOLTIP: "tooltip",
  1416. INPUT: "input"
  1417. },
  1418. LENGTH: {
  1419. VERYVERYTHINMATHSPACE: "veryverythinmathspace",
  1420. VERYTHINMATHSPACE: "verythinmathspace",
  1421. THINMATHSPACE: "thinmathspace",
  1422. MEDIUMMATHSPACE: "mediummathspace",
  1423. THICKMATHSPACE: "thickmathspace",
  1424. VERYTHICKMATHSPACE: "verythickmathspace",
  1425. VERYVERYTHICKMATHSPACE: "veryverythickmathspace",
  1426. NEGATIVEVERYVERYTHINMATHSPACE: "negativeveryverythinmathspace",
  1427. NEGATIVEVERYTHINMATHSPACE: "negativeverythinmathspace",
  1428. NEGATIVETHINMATHSPACE: "negativethinmathspace",
  1429. NEGATIVEMEDIUMMATHSPACE: "negativemediummathspace",
  1430. NEGATIVETHICKMATHSPACE: "negativethickmathspace",
  1431. NEGATIVEVERYTHICKMATHSPACE: "negativeverythickmathspace",
  1432. NEGATIVEVERYVERYTHICKMATHSPACE: "negativeveryverythickmathspace"
  1433. },
  1434. OVERFLOW: {
  1435. LINBREAK: "linebreak",
  1436. SCROLL: "scroll",
  1437. ELIDE: "elide",
  1438. TRUNCATE: "truncate",
  1439. SCALE: "scale"
  1440. },
  1441. UNIT: {
  1442. EM: "em",
  1443. EX: "ex",
  1444. PX: "px",
  1445. IN: "in",
  1446. CM: "cm",
  1447. MM: "mm",
  1448. PT: "pt",
  1449. PC: "pc"
  1450. },
  1451. TEXCLASS: {
  1452. ORD: 0,
  1453. OP: 1,
  1454. BIN: 2,
  1455. REL: 3,
  1456. OPEN: 4,
  1457. CLOSE: 5,
  1458. PUNCT: 6,
  1459. INNER: 7,
  1460. VCENTER: 8,
  1461. NONE: -1
  1462. },
  1463. PLANE1: String.fromCharCode(55349)
  1464. }), function(e) {
  1465. var t = !1, n = !0;
  1466. e.mbase = MathJax.Object.Subclass({
  1467. type: "base",
  1468. isToken: t,
  1469. defaults: {
  1470. mathbackground: e.INHERIT,
  1471. mathcolor: e.INHERIT
  1472. },
  1473. noInherit: {},
  1474. Init: function() {
  1475. this.data = [], this.inferRow && (arguments.length !== 1 || !arguments[0].inferred) && this.Append(e.mrow().With({
  1476. inferred: n
  1477. })), this.Append.apply(this, arguments);
  1478. },
  1479. With: function(e) {
  1480. for (var t in e) e.hasOwnProperty(t) && (this[t] = e[t]);
  1481. return this;
  1482. },
  1483. Append: function() {
  1484. if (this.inferRow && this.data.length) this.data[0].Append.apply(this.data[0], arguments); else for (var e = 0, t = arguments.length; e < t; e++) this.SetData(this.data.length, arguments[e]);
  1485. },
  1486. SetData: function(t, n) {
  1487. n != null && (n instanceof e.mbase || (n = this.isToken ? e.chars(n) : e.mtext(n)), n.parent = this, n.setInherit(this.inheritFromMe ? this : this.inherit)), this.data[t] = n;
  1488. },
  1489. Parent: function() {
  1490. var e = this.parent;
  1491. while (e && e.inferred) e = e.parent;
  1492. return e;
  1493. },
  1494. Get: function(t, n) {
  1495. if (typeof this[t] != "undefined") return this[t];
  1496. var r = this.Parent();
  1497. if (r && r["adjustChild_" + t] != null) return r["adjustChild_" + t](r.childPosition(this));
  1498. var i = this.inherit, s = i;
  1499. while (i) {
  1500. if (typeof i[t] != "undefined") {
  1501. var o = i.noInherit[this.type];
  1502. if (!o || !o[t]) return i[t];
  1503. }
  1504. s = i, i = i.inherit;
  1505. }
  1506. if (!n) {
  1507. if (this.defaults[t] === e.AUTO) return this.autoDefault(t);
  1508. if (this.defaults[t] !== e.INHERIT && this.defaults[t] != null) return this.defaults[t];
  1509. if (s) return s.defaults[t];
  1510. }
  1511. return null;
  1512. },
  1513. hasValue: function(e) {
  1514. return this.Get(e, true) != null;
  1515. },
  1516. getValues: function() {
  1517. var e = {};
  1518. for (var t = 0, n = arguments.length; t < n; t++) e[arguments[t]] = this.Get(arguments[t]);
  1519. return e;
  1520. },
  1521. adjustChild_scriptlevel: function(e) {
  1522. return this.Get("scriptlevel");
  1523. },
  1524. adjustChild_displaystyle: function(e) {
  1525. return this.Get("displaystyle");
  1526. },
  1527. adjustChild_texprimestyle: function(e) {
  1528. return this.Get("texprimestyle");
  1529. },
  1530. childPosition: function(e) {
  1531. e.parent.inferred && (e = e.parent);
  1532. for (var t = 0, n = this.data.length; t < n; t++) if (this.data[t] === e) return t;
  1533. return null;
  1534. },
  1535. setInherit: function(e) {
  1536. if (e !== this.inherit && this.inherit == null) {
  1537. this.inherit = e;
  1538. for (var t = 0, n = this.data.length; t < n; t++) this.data[t] && this.data[t].setInherit && this.data[t].setInherit(e);
  1539. }
  1540. },
  1541. setTeXclass: function(e) {
  1542. return this.getPrevClass(e), typeof this.texClass != "undefined" ? this : e;
  1543. },
  1544. getPrevClass: function(e) {
  1545. e && (this.prevClass = e.Get("texClass"), this.prevLevel = e.Get("scriptlevel"));
  1546. },
  1547. updateTeXclass: function(e) {
  1548. e && (this.prevClass = e.prevClass, delete e.prevClass, this.prevLevel = e.prevLevel, delete e.prevLevel, this.texClass = e.Get("texClass"));
  1549. },
  1550. texSpacing: function() {
  1551. var t = this.prevClass != null ? this.prevClass : e.TEXCLASS.NONE, n = this.Get("texClass") || e.TEXCLASS.ORD;
  1552. if (t === e.TEXCLASS.NONE || n === e.TEXCLASS.NONE) return "";
  1553. t === e.TEXCLASS.VCENTER && (t = e.TEXCLASS.ORD), n === e.TEXCLASS.VCENTER && (n = e.TEXCLASS.ORD);
  1554. var r = this.TEXSPACE[t][n];
  1555. return this.prevLevel > 0 && this.Get("scriptlevel") > 0 && r >= 0 ? "" : this.TEXSPACELENGTH[Math.abs(r)];
  1556. },
  1557. TEXSPACELENGTH: [ "", e.LENGTH.THINMATHSPACE, e.LENGTH.MEDIUMMATHSPACE, e.LENGTH.THICKMATHSPACE ],
  1558. TEXSPACE: [ [ 0, -1, 2, 3, 0, 0, 0, 1 ], [ -1, -1, 0, 3, 0, 0, 0, 1 ], [ 2, 2, 0, 0, 2, 0, 0, 2 ], [ 3, 3, 0, 0, 3, 0, 0, 3 ], [ 0, 0, 0, 0, 0, 0, 0, 0 ], [ 0, -1, 2, 3, 0, 0, 0, 1 ], [ 1, 1, 0, 1, 1, 1, 1, 1 ], [ 1, -1, 2, 3, 1, 0, 1, 1 ] ],
  1559. autoDefault: function(e) {
  1560. return "";
  1561. },
  1562. isSpacelike: function() {
  1563. return t;
  1564. },
  1565. isEmbellished: function() {
  1566. return t;
  1567. },
  1568. Core: function() {
  1569. return this;
  1570. },
  1571. CoreMO: function() {
  1572. return this;
  1573. },
  1574. lineBreak: function() {
  1575. return this.isEmbellished() ? this.CoreMO().lineBreak() : "none";
  1576. },
  1577. array: function() {
  1578. return this.inferred ? this.data : [ this ];
  1579. },
  1580. toString: function() {
  1581. return this.type + "(" + this.data.join(",") + ")";
  1582. }
  1583. }, {
  1584. childrenSpacelike: function() {
  1585. for (var e = 0; e < this.data.length; e++) if (!this.data[e].isSpacelike()) return t;
  1586. return n;
  1587. },
  1588. childEmbellished: function() {
  1589. return this.data[0] && this.data[0].isEmbellished();
  1590. },
  1591. childCore: function() {
  1592. return this.data[0];
  1593. },
  1594. childCoreMO: function() {
  1595. return this.data[0] ? this.data[0].CoreMO() : null;
  1596. },
  1597. setChildTeXclass: function(e) {
  1598. return this.data[0] && (e = this.data[0].setTeXclass(e), this.updateTeXclass(this.data[0])), e;
  1599. },
  1600. setBaseTeXclasses: function(e) {
  1601. this.getPrevClass(e), this.texClass = null, this.isEmbellished() ? (e = this.data[0].setTeXclass(e), this.updateTeXclass(this.Core())) : (this.data[0] && this.data[0].setTeXclass(), e = this);
  1602. for (var t = 1, n = this.data.length; t < n; t++) this.data[t] && this.data[t].setTeXclass();
  1603. return e;
  1604. },
  1605. setSeparateTeXclasses: function(e) {
  1606. this.getPrevClass(e);
  1607. for (var t = 0, n = this.data.length; t < n; t++) this.data[t] && this.data[t].setTeXclass();
  1608. return this.isEmbellished() && this.updateTeXclass(this.Core()), this;
  1609. }
  1610. }), e.mi = e.mbase.Subclass({
  1611. type: "mi",
  1612. isToken: n,
  1613. texClass: e.TEXCLASS.ORD,
  1614. defaults: {
  1615. mathvariant: e.AUTO,
  1616. mathsize: e.INHERIT,
  1617. mathbackground: e.INHERIT,
  1618. mathcolor: e.INHERIT
  1619. },
  1620. autoDefault: function(t) {
  1621. if (t === "mathvariant") {
  1622. var n = (this.data[0] || "").toString();
  1623. return n.length === 1 || n.length === 2 && n.charCodeAt(0) === this.PLANE1 ? e.VARIANT.ITALIC : e.VARIANT.NORMAL;
  1624. }
  1625. return "";
  1626. }
  1627. }), e.mn = e.mbase.Subclass({
  1628. type: "mn",
  1629. isToken: n,
  1630. texClass: e.TEXCLASS.ORD,
  1631. defaults: {
  1632. mathvariant: e.INHERIT,
  1633. mathsize: e.INHERIT,
  1634. mathbackground: e.INHERIT,
  1635. mathcolor: e.INHERIT
  1636. }
  1637. }), e.mo = e.mbase.Subclass({
  1638. type: "mo",
  1639. isToken: n,
  1640. defaults: {
  1641. mathvariant: e.INHERIT,
  1642. mathsize: e.INHERIT,
  1643. mathbackground: e.INHERIT,
  1644. mathcolor: e.INHERIT,
  1645. form: e.AUTO,
  1646. fence: e.AUTO,
  1647. separator: e.AUTO,
  1648. lspace: e.AUTO,
  1649. rspace: e.AUTO,
  1650. stretchy: e.AUTO,
  1651. symmetric: e.AUTO,
  1652. maxsize: e.AUTO,
  1653. minsize: e.AUTO,
  1654. largeop: e.AUTO,
  1655. movablelimits: e.AUTO,
  1656. accent: e.AUTO,
  1657. linebreak: e.LINEBREAK.AUTO,
  1658. lineleading: e.INHERIT,
  1659. linebreakstyle: e.AUTO,
  1660. linebreakmultchar: e.INHERIT,
  1661. indentalign: e.INHERIT,
  1662. indentshift: e.INHERIT,
  1663. indenttarget: e.INHERIT,
  1664. indentalignfirst: e.INHERIT,
  1665. indentshiftfirst: e.INHERIT,
  1666. indentalignlast: e.INHERIT,
  1667. indentshiftlast: e.INHERIT,
  1668. texClass: e.AUTO
  1669. },
  1670. defaultDef: {
  1671. form: e.FORM.INFIX,
  1672. fence: t,
  1673. separator: t,
  1674. lspace: e.LENGTH.THICKMATHSPACE,
  1675. rspace: e.LENGTH.THICKMATHSPACE,
  1676. stretchy: t,
  1677. symmetric: n,
  1678. maxsize: e.SIZE.INFINITY,
  1679. minsize: "0em",
  1680. largeop: t,
  1681. movablelimits: t,
  1682. accent: t,
  1683. linebreak: e.LINEBREAK.AUTO,
  1684. lineleading: "1ex",
  1685. linebreakstyle: "before",
  1686. indentalign: e.INDENTALIGN.AUTO,
  1687. indentshift: "0",
  1688. indenttarget: "",
  1689. indentalignfirst: e.INDENTALIGN.INDENTALIGN,
  1690. indentshiftfirst: e.INDENTSHIFT.INDENTSHIFT,
  1691. indentalignlast: e.INDENTALIGN.INDENTALIGN,
  1692. indentshiftlast: e.INDENTSHIFT.INDENTSHIFT,
  1693. texClass: e.TEXCLASS.REL
  1694. },
  1695. SPACE_ATTR: {
  1696. lspace: 1,
  1697. rspace: 2,
  1698. form: 4
  1699. },
  1700. useMMLspacing: 7,
  1701. autoDefault: function(t, n) {
  1702. var r = this.def;
  1703. if (!r) {
  1704. if (t === "form") return this.useMMLspacing &= ~this.SPACE_ATTR.form, this.getForm();
  1705. var i = this.data.join(""), s = [ this.Get("form"), e.FORM.INFIX, e.FORM.POSTFIX, e.FORM.PREFIX ];
  1706. for (var o = 0, u = s.length; o < u; o++) {
  1707. var f = this.OPTABLE[s[o]][i];
  1708. if (f) {
  1709. r = this.makeDef(f);
  1710. break;
  1711. }
  1712. }
  1713. r || (r = this.CheckRange(i)), !r && n ? r = {} : (r || (r = MathJax.Hub.Insert({}, this.defaultDef)), r.form = s[0], this.def = r);
  1714. }
  1715. return this.useMMLspacing &= ~(this.SPACE_ATTR[t] || 0), r[t] != null ? r[t] : n ? "" : this.defaultDef[t];
  1716. },
  1717. CheckRange: function(t) {
  1718. var n = t.charCodeAt(0);
  1719. t.charAt(0) === e.PLANE1 && (n = t.charCodeAt(1) + 119808 - 56320);
  1720. for (var r = 0, i = this.RANGES.length; r < i && this.RANGES[r][0] <= n; r++) if (n <= this.RANGES[r][1]) {
  1721. if (this.RANGES[r][3]) {
  1722. var s = e.optableDir + "/" + this.RANGES[r][3] + ".js";
  1723. this.RANGES[r][3] = null, MathJax.Hub.RestartAfter(MathJax.Ajax.Require(s));
  1724. }
  1725. var o = [ "ORD", "OP", "BIN", "REL", "OPEN", "CLOSE", "PUNCT", "INNER" ][this.RANGES[r][2]];
  1726. return o = this.OPTABLE.infix[t] = e.mo.OPTYPES[o === "BIN" ? "BIN3" : o], this.makeDef(o);
  1727. }
  1728. return null;
  1729. },
  1730. makeDef: function(e) {
  1731. e[2] == null && (e[2] = this.defaultDef.texClass), e[3] || (e[3] = {});
  1732. var t = MathJax.Hub.Insert({}, e[3]);
  1733. return t.lspace = this.SPACE[e[0]], t.rspace = this.SPACE[e[1]], t.texClass = e[2], t;
  1734. },
  1735. getForm: function() {
  1736. var t = this, n = this.parent, r = this.Parent();
  1737. while (r && r.isEmbellished()) t = n, n = r.parent, r = r.Parent();
  1738. if (n && n.type === "mrow" && n.NonSpaceLength() !== 1) {
  1739. if (n.FirstNonSpace() === t) return e.FORM.PREFIX;
  1740. if (n.LastNonSpace() === t) return e.FORM.POSTFIX;
  1741. }
  1742. return e.FORM.INFIX;
  1743. },
  1744. isEmbellished: function() {
  1745. return n;
  1746. },
  1747. lineBreak: function() {
  1748. var t = this.getValues("linebreak", "linebreakstyle");
  1749. return t.linebreak === e.LINEBREAK.NEWLINE ? (t.linebreakstyle === e.LINEBREAKSTYLE.INFIXLINEBREAKSTYLE && (t.linebreakstyle = this.Get("infixlinebreakstyle")), t.linebreakstyle) : "none";
  1750. },
  1751. setTeXclass: function(t) {
  1752. return this.getValues("lspace", "rspace"), this.useMMLspacing ? (this.texClass = e.TEXCLASS.NONE, this) : (this.texClass = this.Get("texClass"), t ? (this.prevClass = t.texClass || e.TEXCLASS.ORD, this.prevLevel = t.Get("scriptlevel")) : this.prevClass = e.TEXCLASS.NONE, this.texClass !== e.TEXCLASS.BIN || this.prevClass !== e.TEXCLASS.NONE && this.prevClass !== e.TEXCLASS.BIN && this.prevClass !== e.TEXCLASS.OP && this.prevClass !== e.TEXCLASS.REL && this.prevClass !== e.TEXCLASS.OPEN && this.prevClass !== e.TEXCLASS.PUNCT ? this.prevClass === e.TEXCLASS.BIN && (this.texClass === e.TEXCLASS.REL || this.texClass === e.TEXCLASS.CLOSE || this.texClass === e.TEXCLASS.PUNCT) && (t.texClass = this.prevClass = e.TEXCLASS.ORD) : this.texClass = e.TEXCLASS.ORD, this);
  1753. }
  1754. }), e.mtext = e.mbase.Subclass({
  1755. type: "mtext",
  1756. isToken: n,
  1757. isSpacelike: function() {
  1758. return n;
  1759. },
  1760. texClass: e.TEXCLASS.ORD,
  1761. defaults: {
  1762. mathvariant: e.INHERIT,
  1763. mathsize: e.INHERIT,
  1764. mathbackground: e.INHERIT,
  1765. mathcolor: e.INHERIT
  1766. }
  1767. }), e.mspace = e.mbase.Subclass({
  1768. type: "mspace",
  1769. isToken: n,
  1770. isSpacelike: function() {
  1771. return n;
  1772. },
  1773. defaults: {
  1774. mathbackground: e.INHERIT,
  1775. mathcolor: e.INHERIT,
  1776. width: "0em",
  1777. height: "0ex",
  1778. depth: "0ex",
  1779. linebreak: e.LINEBREAK.AUTO
  1780. },
  1781. lineBreak: function() {
  1782. return this.Get("linebreak") === e.LINEBREAK.NEWLINE ? e.LINEBREAKSTYLE.AFTER : "none";
  1783. }
  1784. }), e.ms = e.mbase.Subclass({
  1785. type: "ms",
  1786. isToken: n,
  1787. texClass: e.TEXCLASS.ORD,
  1788. defaults: {
  1789. mathvariant: e.INHERIT,
  1790. mathsize: e.INHERIT,
  1791. mathbackground: e.INHERIT,
  1792. mathcolor: e.INHERIT,
  1793. lquote: '"',
  1794. rquote: '"'
  1795. }
  1796. }), e.mglyph = e.mbase.Subclass({
  1797. type: "mglyph",
  1798. isToken: n,
  1799. texClass: e.TEXCLASS.ORD,
  1800. defaults: {
  1801. mathbackground: e.INHERIT,
  1802. mathcolor: e.INHERIT,
  1803. alt: "",
  1804. src: "",
  1805. width: e.AUTO,
  1806. height: e.AUTO,
  1807. valign: "0em"
  1808. }
  1809. }), e.mrow = e.mbase.Subclass({
  1810. type: "mrow",
  1811. isSpacelike: e.mbase.childrenSpacelike,
  1812. inferred: t,
  1813. isEmbellished: function() {
  1814. var e = t;
  1815. for (var r = 0, i = this.data.length; r < i; r++) {
  1816. if (this.data[r] == null) continue;
  1817. if (this.data[r].isEmbellished()) {
  1818. if (e) return t;
  1819. e = n, this.core = r;
  1820. } else if (!this.data[r].isSpacelike()) return t;
  1821. }
  1822. return e;
  1823. },
  1824. NonSpaceLength: function() {
  1825. var e = 0;
  1826. for (var t = 0, n = this.data.length; t < n; t++) this.data[t] && !this.data[t].isSpacelike() && e++;
  1827. return e;
  1828. },
  1829. FirstNonSpace: function() {
  1830. for (var e = 0, t = this.data.length; e < t; e++) if (this.data[e] && !this.data[e].isSpacelike()) return this.data[e];
  1831. return null;
  1832. },
  1833. LastNonSpace: function() {
  1834. for (var e = this.data.length - 1; e >= 0; e--) if (this.data[0] && !this.data[e].isSpacelike()) return this.data[e];
  1835. return null;
  1836. },
  1837. Core: function() {
  1838. return !this.isEmbellished() || typeof this.core == "undefined" ? this : this.data[this.core];
  1839. },
  1840. CoreMO: function() {
  1841. return !this.isEmbellished() || typeof this.core == "undefined" ? this : this.data[this.core].CoreMO();
  1842. },
  1843. toString: function() {
  1844. return this.inferred ? "[" + this.data.join(",") + "]" : this.SUPER(arguments).toString.call(this);
  1845. },
  1846. setTeXclass: function(e) {
  1847. for (var t = 0, n = this.data.length; t < n; t++) this.data[t] && (e = this.data[t].setTeXclass(e));
  1848. return this.data[0] && this.updateTeXclass(this.data[0]), e;
  1849. }
  1850. }), e.mfrac = e.mbase.Subclass({
  1851. type: "mfrac",
  1852. num: 0,
  1853. den: 1,
  1854. texClass: e.TEXCLASS.INNER,
  1855. isEmbellished: e.mbase.childEmbellished,
  1856. Core: e.mbase.childCore,
  1857. CoreMO: e.mbase.childCoreMO,
  1858. defaults: {
  1859. mathbackground: e.INHERIT,
  1860. mathcolor: e.INHERIT,
  1861. linethickness: e.LINETHICKNESS.MEDIUM,
  1862. numalign: e.ALIGN.CENTER,
  1863. denomalign: e.ALIGN.CENTER,
  1864. bevelled: t
  1865. },
  1866. adjustChild_displaystyle: function(e) {
  1867. return t;
  1868. },
  1869. adjustChild_scriptlevel: function(e) {
  1870. var t = this.Get("scriptlevel");
  1871. return (!this.Get("displaystyle") || t > 0) && t++, t;
  1872. },
  1873. adjustChild_texprimestyle: function(e) {
  1874. return e == this.den ? !0 : this.Get("texprimestyle");
  1875. },
  1876. setTeXclass: e.mbase.setSeparateTeXclasses
  1877. }), e.msqrt = e.mbase.Subclass({
  1878. type: "msqrt",
  1879. inferRow: n,
  1880. texClass: e.TEXCLASS.ORD,
  1881. setTeXclass: e.mbase.setSeparateTeXclasses,
  1882. adjustChild_texprimestyle: function(e) {
  1883. return n;
  1884. }
  1885. }), e.mroot = e.mbase.Subclass({
  1886. type: "mroot",
  1887. texClass: e.TEXCLASS.ORD,
  1888. adjustChild_displaystyle: function(e) {
  1889. return e === 1 ? t : this.Get("displaystyle");
  1890. },
  1891. adjustChild_scriptlevel: function(e) {
  1892. var t = this.Get("scriptlevel");
  1893. return e === 1 && (t += 2), t;
  1894. },
  1895. adjustChild_texprimestyle: function(e) {
  1896. return e === 0 ? n : this.Get("texprimestyle");
  1897. },
  1898. setTeXclass: e.mbase.setSeparateTeXclasses
  1899. }), e.mstyle = e.mbase.Subclass({
  1900. type: "mstyle",
  1901. isSpacelike: e.mbase.childrenSpacelike,
  1902. isEmbellished: e.mbase.childEmbellished,
  1903. Core: e.mbase.childCore,
  1904. CoreMO: e.mbase.childCoreMO,
  1905. inferRow: n,
  1906. defaults: {
  1907. scriptlevel: e.INHERIT,
  1908. displaystyle: e.INHERIT,
  1909. scriptsizemultiplier: Math.sqrt(.5),
  1910. scriptminsize: "8pt",
  1911. mathbackground: e.INHERIT,
  1912. mathcolor: e.INHERIT,
  1913. infixlinebreakstyle: e.LINEBREAKSTYLE.BEFORE,
  1914. decimalseparator: "."
  1915. },
  1916. adjustChild_scriptlevel: function(e) {
  1917. var t = this.scriptlevel;
  1918. if (t == null) t = this.Get("scriptlevel"); else if (String(t).match(/^ *[-+]/)) {
  1919. delete this.scriptlevel;
  1920. var n = this.Get("scriptlevel");
  1921. this.scriptlevel = t, t = n + parseInt(t);
  1922. }
  1923. return t;
  1924. },
  1925. inheritFromMe: n,
  1926. noInherit: {
  1927. mpadded: {
  1928. width: n,
  1929. height: n,
  1930. depth: n,
  1931. lspace: n,
  1932. voffset: n
  1933. },
  1934. mtable: {
  1935. width: n,
  1936. height: n,
  1937. depth: n,
  1938. align: n
  1939. }
  1940. },
  1941. setTeXclass: e.mbase.setChildTeXclass
  1942. }), e.merror = e.mbase.Subclass({
  1943. type: "merror",
  1944. inferRow: n,
  1945. texClass: e.TEXCLASS.ORD
  1946. }), e.mpadded = e.mbase.Subclass({
  1947. type: "mpadded",
  1948. inferRow: n,
  1949. isSpacelike: e.mbase.childrenSpacelike,
  1950. isEmbellished: e.mbase.childEmbellished,
  1951. Core: e.mbase.childCore,
  1952. CoreMO: e.mbase.childCoreMO,
  1953. defaults: {
  1954. mathbackground: e.INHERIT,
  1955. mathcolor: e.INHERIT,
  1956. width: "",
  1957. height: "",
  1958. depth: "",
  1959. lspace: 0,
  1960. voffset: 0
  1961. },
  1962. setTeXclass: e.mbase.setChildTeXclass
  1963. }), e.mphantom = e.mbase.Subclass({
  1964. type: "mphantom",
  1965. texClass: e.TEXCLASS.ORD,
  1966. inferRow: n,
  1967. isSpacelike: e.mbase.childrenSpacelike,
  1968. isEmbellished: e.mbase.childEmbellished,
  1969. Core: e.mbase.childCore,
  1970. CoreMO: e.mbase.childCoreMO,
  1971. setTeXclass: e.mbase.setChildTeXclass
  1972. }), e.mfenced = e.mbase.Subclass({
  1973. type: "mfenced",
  1974. defaults: {
  1975. mathbackground: e.INHERIT,
  1976. mathcolor: e.INHERIT,
  1977. open: "(",
  1978. close: ")",
  1979. separators: ","
  1980. },
  1981. texClass: e.TEXCLASS.OPEN,
  1982. setTeXclass: function(t) {
  1983. this.getPrevClass(t);
  1984. var n = this.getValues("open", "close", "separators");
  1985. n.open = n.open.replace(/[ \t\n\r]/g, ""), n.close = n.close.replace(/[ \t\n\r]/g, ""), n.separators = n.separators.replace(/[ \t\n\r]/g, ""), n.open !== "" && (this.SetData("open", e.mo(n.open).With({
  1986. stretchy: !0,
  1987. texClass: e.TEXCLASS.OPEN
  1988. })), t = this.data.open.setTeXclass(t));
  1989. if (n.separators !== "") while (n.separators.length < this.data.length) n.separators += n.separators.charAt(n.separators.length - 1);
  1990. this.data[0] && (t = this.data[0].setTeXclass(t));
  1991. for (var r = 1, i = this.data.length; r < i; r++) this.data[r] && (n.separators !== "" && (this.SetData("sep" + r, e.mo(n.separators.charAt(r - 1))), t = this.data["sep" + r].setTeXclass(t)), t = this.data[r].setTeXclass(t));
  1992. return n.close !== "" && (this.SetData("close", e.mo(n.close).With({
  1993. stretchy: !0,
  1994. texClass: e.TEXCLASS.CLOSE
  1995. })), t = this.data.close.setTeXclass(t)), this.updateTeXclass(this.data.open), t;
  1996. }
  1997. }), e.menclose = e.mbase.Subclass({
  1998. type: "menclose",
  1999. inferRow: n,
  2000. defaults: {
  2001. mathbackground: e.INHERIT,
  2002. mathcolor: e.INHERIT,
  2003. notation: e.NOTATION.LONGDIV,
  2004. texClass: e.TEXCLASS.ORD
  2005. },
  2006. setTeXclass: e.mbase.setSeparateTeXclasses
  2007. }), e.msubsup = e.mbase.Subclass({
  2008. type: "msubsup",
  2009. base: 0,
  2010. sub: 1,
  2011. sup: 2,
  2012. isEmbellished: e.mbase.childEmbellished,
  2013. Core: e.mbase.childCore,
  2014. CoreMO: e.mbase.childCoreMO,
  2015. defaults: {
  2016. mathbackground: e.INHERIT,
  2017. mathcolor: e.INHERIT,
  2018. subscriptshift: "",
  2019. superscriptshift: "",
  2020. texClass: e.AUTO
  2021. },
  2022. autoDefault: function(t) {
  2023. return t === "texClass" ? this.isEmbellished() ? this.CoreMO().Get(t) : e.TEXCLASS.ORD : 0;
  2024. },
  2025. adjustChild_displaystyle: function(e) {
  2026. return e > 0 ? t : this.Get("displaystyle");
  2027. },
  2028. adjustChild_scriptlevel: function(e) {
  2029. var t = this.Get("scriptlevel");
  2030. return e > 0 && t++, t;
  2031. },
  2032. adjustChild_texprimestyle: function(e) {
  2033. return e === this.sub ? n : this.Get("texprimestyle");
  2034. },
  2035. setTeXclass: e.mbase.setBaseTeXclasses
  2036. }), e.msub = e.msubsup.Subclass({
  2037. type: "msub"
  2038. }), e.msup = e.msubsup.Subclass({
  2039. type: "msup",
  2040. sub: 2,
  2041. sup: 1
  2042. }), e.mmultiscripts = e.msubsup.Subclass({
  2043. type: "mmultiscripts",
  2044. adjustChild_texprimestyle: function(e) {
  2045. return e % 2 === 1 ? n : this.Get("texprimestyle");
  2046. }
  2047. }), e.mprescripts = e.mbase.Subclass({
  2048. type: "mprescripts"
  2049. }), e.none = e.mbase.Subclass({
  2050. type: "none"
  2051. }), e.munderover = e.mbase.Subclass({
  2052. type: "munderover",
  2053. base: 0,
  2054. under: 1,
  2055. over: 2,
  2056. sub: 1,
  2057. sup: 2,
  2058. ACCENTS: [ "", "accentunder", "accent" ],
  2059. isEmbellished: e.mbase.childEmbellished,
  2060. Core: e.mbase.childCore,
  2061. CoreMO: e.mbase.childCoreMO,
  2062. defaults: {
  2063. mathbackground: e.INHERIT,
  2064. mathcolor: e.INHERIT,
  2065. accent: e.AUTO,
  2066. accentunder: e.AUTO,
  2067. align: e.ALIGN.CENTER,
  2068. texClass: e.AUTO,
  2069. subscriptshift: "",
  2070. superscriptshift: ""
  2071. },
  2072. autoDefault: function(n) {
  2073. return n === "texClass" ? this.isEmbellished() ? this.CoreMO().Get(n) : e.TEXCLASS.ORD : n === "accent" && this.data[this.over] ? this.data[this.over].CoreMO().Get("accent") : n === "accentunder" && this.data[this.under] ? this.data[this.under].CoreMO().Get("accent") : t;
  2074. },
  2075. adjustChild_displaystyle: function(e) {
  2076. return e > 0 ? t : this.Get("displaystyle");
  2077. },
  2078. adjustChild_scriptlevel: function(e) {
  2079. var t = this.Get("scriptlevel");
  2080. return e == this.under && !this.Get("accentunder") && t++, e == this.over && !this.Get("accent") && t++, t;
  2081. },
  2082. adjustChild_texprimestyle: function(e) {
  2083. return e === this.base && this.data[this.over] ? n : this.Get("texprimestyle");
  2084. },
  2085. setTeXclass: e.mbase.setBaseTeXclasses
  2086. }), e.munder = e.munderover.Subclass({
  2087. type: "munder"
  2088. }), e.mover = e.munderover.Subclass({
  2089. type: "mover",
  2090. over: 1,
  2091. under: 2,
  2092. sup: 1,
  2093. sub: 2,
  2094. ACCENTS: [ "", "accent", "accentunder" ]
  2095. }), e.mtable = e.mbase.Subclass({
  2096. type: "mtable",
  2097. defaults: {
  2098. mathbackground: e.INHERIT,
  2099. mathcolor: e.INHERIT,
  2100. align: e.ALIGN.AXIS,
  2101. rowalign: e.ALIGN.BASELINE,
  2102. columnalign: e.ALIGN.CENTER,
  2103. groupalign: "{left}",
  2104. alignmentscope: n,
  2105. columnwidth: e.WIDTH.AUTO,
  2106. width: e.WIDTH.AUTO,
  2107. rowspacing: "1ex",
  2108. columnspacing: ".8em",
  2109. rowlines: e.LINES.NONE,
  2110. columnlines: e.LINES.NONE,
  2111. frame: e.LINES.NONE,
  2112. framespacing: "0.4em 0.5ex",
  2113. equalrows: t,
  2114. equalcolumns: t,
  2115. displaystyle: t,
  2116. side: e.SIDE.RIGHT,
  2117. minlabelspacing: "0.8em",
  2118. texClass: e.TEXCLASS.ORD,
  2119. useHeight: 1
  2120. },
  2121. inheritFromMe: n,
  2122. noInherit: {
  2123. mtable: {
  2124. align: n,
  2125. rowalign: n,
  2126. columnalign: n,
  2127. groupalign: n,
  2128. alignmentscope: n,
  2129. columnwidth: n,
  2130. width: n,
  2131. rowspacing: n,
  2132. columnspacing: n,
  2133. rowlines: n,
  2134. columnlines: n,
  2135. frame: n,
  2136. framespacing: n,
  2137. equalrows: n,
  2138. equalcolumns: n,
  2139. side: n,
  2140. minlabelspacing: n,
  2141. texClass: n,
  2142. useHeight: 1
  2143. }
  2144. },
  2145. Append: function() {
  2146. for (var t = 0, n = arguments.length; t < n; t++) arguments[t] instanceof e.mtr || arguments[t] instanceof e.mlabeledtr || (arguments[t] = e.mtd(arguments[t]));
  2147. this.SUPER(arguments).Append.apply(this, arguments);
  2148. },
  2149. setTeXclass: e.mbase.setSeparateTeXclasses
  2150. }), e.mtr = e.mbase.Subclass({
  2151. type: "mtr",
  2152. defaults: {
  2153. mathbackground: e.INHERIT,
  2154. mathcolor: e.INHERIT,
  2155. rowalign: e.INHERIT,
  2156. columnalign: e.INHERIT,
  2157. groupalign: e.INHERIT
  2158. },
  2159. inheritFromMe: n,
  2160. noInherit: {
  2161. mrow: {
  2162. rowalign: n,
  2163. columnalign: n,
  2164. groupalign: n
  2165. },
  2166. mtable: {
  2167. rowalign: n,
  2168. columnalign: n,
  2169. groupalign: n
  2170. }
  2171. },
  2172. Append: function() {
  2173. for (var t = 0, n = arguments.length; t < n; t++) arguments[t] instanceof e.mtd || (arguments[t] = e.mtd(arguments[t]));
  2174. this.SUPER(arguments).Append.apply(this, arguments);
  2175. },
  2176. setTeXclass: e.mbase.setSeparateTeXclasses
  2177. }), e.mtd = e.mbase.Subclass({
  2178. type: "mtd",
  2179. inferRow: n,
  2180. isEmbellished: e.mbase.childEmbellished,
  2181. Core: e.mbase.childCore,
  2182. CoreMO: e.mbase.childCoreMO,
  2183. defaults: {
  2184. mathbackground: e.INHERIT,
  2185. mathcolor: e.INHERIT,
  2186. rowspan: 1,
  2187. columnspan: 1,
  2188. rowalign: e.INHERIT,
  2189. columnalign: e.INHERIT,
  2190. groupalign: e.INHERIT
  2191. },
  2192. setTeXclass: e.mbase.setSeparateTeXclasses
  2193. }), e.maligngroup = e.mbase.Subclass({
  2194. type: "malign",
  2195. isSpacelike: function() {
  2196. return n;
  2197. },
  2198. defaults: {
  2199. mathbackground: e.INHERIT,
  2200. mathcolor: e.INHERIT,
  2201. groupalign: e.INHERIT
  2202. },
  2203. inheritFromMe: n,
  2204. noInherit: {
  2205. mrow: {
  2206. groupalign: n
  2207. },
  2208. mtable: {
  2209. groupalign: n
  2210. }
  2211. }
  2212. }), e.malignmark = e.mbase.Subclass({
  2213. type: "malignmark",
  2214. defaults: {
  2215. mathbackground: e.INHERIT,
  2216. mathcolor: e.INHERIT,
  2217. edge: e.SIDE.LEFT
  2218. },
  2219. isSpacelike: function() {
  2220. return n;
  2221. }
  2222. }), e.mlabeledtr = e.mtr.Subclass({
  2223. type: "mlabeledtr"
  2224. }), e.maction = e.mbase.Subclass({
  2225. type: "maction",
  2226. defaults: {
  2227. mathbackground: e.INHERIT,
  2228. mathcolor: e.INHERIT,
  2229. actiontype: e.ACTIONTYPE.TOGGLE,
  2230. selection: 1
  2231. },
  2232. selected: function() {
  2233. return this.data[this.Get("selection") - 1] || e.NULL;
  2234. },
  2235. isEmbellished: function() {
  2236. return this.selected().isEmbellished();
  2237. },
  2238. isSpacelike: function() {
  2239. return this.selected().isSpacelike();
  2240. },
  2241. Core: function() {
  2242. return this.selected().Core();
  2243. },
  2244. CoreMO: function() {
  2245. return this.selected().CoreMO();
  2246. },
  2247. setTeXclass: function(e) {
  2248. return this.selected().setTeXclass(e);
  2249. }
  2250. }), e.semantics = e.mbase.Subclass({
  2251. type: "semantics",
  2252. isEmbellished: e.mbase.childEmbellished,
  2253. Core: e.mbase.childCore,
  2254. CoreMO: e.mbase.childCoreMO,
  2255. defaults: {
  2256. definitionURL: null,
  2257. encoding: null
  2258. },
  2259. setTeXclass: e.mbase.setChildTeXclass
  2260. }), e.annotation = e.mbase.Subclass({
  2261. type: "annotation",
  2262. isToken: n,
  2263. defaults: {
  2264. definitionURL: null,
  2265. encoding: null,
  2266. cd: "mathmlkeys",
  2267. name: "",
  2268. src: null
  2269. }
  2270. }), e["annotation-xml"] = e.mbase.Subclass({
  2271. type: "annotation-xml",
  2272. defaults: {
  2273. definitionURL: null,
  2274. encoding: null,
  2275. cd: "mathmlkeys",
  2276. name: "",
  2277. src: null
  2278. }
  2279. }), e.math = e.mstyle.Subclass({
  2280. type: "math",
  2281. defaults: {
  2282. mathvariant: e.VARIANT.NORMAL,
  2283. mathsize: e.SIZE.NORMAL,
  2284. mathcolor: "",
  2285. mathbackground: e.COLOR.TRANSPARENT,
  2286. scriptlevel: 0,
  2287. displaystyle: e.AUTO,
  2288. display: "inline",
  2289. maxwidth: "",
  2290. overflow: e.OVERFLOW.LINEBREAK,
  2291. altimg: "",
  2292. "altimg-width": "",
  2293. "altimg-height": "",
  2294. "altimg-valign": "",
  2295. alttext: "",
  2296. cdgroup: "",
  2297. scriptsizemultiplier: Math.sqrt(.5),
  2298. scriptminsize: "8px",
  2299. infixlinebreakstyle: e.LINEBREAKSTYLE.BEFORE,
  2300. lineleading: "1ex",
  2301. indentshift: "auto",
  2302. indentalign: e.INDENTALIGN.AUTO,
  2303. indentalignfirst: e.INDENTALIGN.INDENTALIGN,
  2304. indentshiftfirst: e.INDENTSHIFT.INDENTSHIFT,
  2305. decimalseparator: ".",
  2306. texprimestyle: t
  2307. },
  2308. autoDefault: function(e) {
  2309. return e === "displaystyle" ? this.Get("display") === "block" : "";
  2310. },
  2311. setTeXclass: e.mbase.setChildTeXclass
  2312. }), e.chars = e.mbase.Subclass({
  2313. type: "chars",
  2314. Append: function() {
  2315. this.data.push.apply(this.data, arguments);
  2316. },
  2317. value: function() {
  2318. return this.data.join("");
  2319. },
  2320. toString: function() {
  2321. return this.data.join("");
  2322. }
  2323. }), e.entity = e.mbase.Subclass({
  2324. type: "entity",
  2325. Append: function() {
  2326. this.data.push.apply(this.data, arguments);
  2327. },
  2328. value: function() {
  2329. return this.data[0].substr(0, 2) === "#x" ? parseInt(this.data[0].substr(2), 16) : this.data[0].substr(0, 1) === "#" ? parseInt(this.data[0].substr(1)) : 0;
  2330. },
  2331. toString: function() {
  2332. var e = this.value();
  2333. return e <= 65535 ? String.fromCharCode(e) : this.PLANE1 + String.fromCharCode(e - 119808 + 56320);
  2334. }
  2335. }), e.xml = e.mbase.Subclass({
  2336. type: "xml",
  2337. Init: function() {
  2338. return this.div = document.createElement("div"), this.SUPER(arguments).Init.apply(this, arguments);
  2339. },
  2340. Append: function() {
  2341. for (var e = 0, t = arguments.length; e < t; e++) {
  2342. var n = this.Import(arguments[e]);
  2343. this.data.push(n), this.div.appendChild(n);
  2344. }
  2345. },
  2346. Import: function(e) {
  2347. if (document.importNode) return document.importNode(e, !0);
  2348. var t, n, r;
  2349. if (e.nodeType === 1) {
  2350. t = document.createElement(e.nodeName), e.className && (t.className = iNode.className);
  2351. for (n = 0, r = e.attributes.length; n < r; n++) {
  2352. var i = e.attributes[n];
  2353. i.specified && i.nodeValue != null && i.nodeValue != "" && t.setAttribute(i.nodeName, i.nodeValue), i.nodeName === "style" && (t.style.cssText = i.nodeValue);
  2354. }
  2355. e.className && (t.className = e.className);
  2356. } else if (e.nodeType === 3 || e.nodeType === 4) t = document.createTextNode(e.nodeValue); else {
  2357. if (e.nodeType !== 8) return document.createTextNode("");
  2358. t = document.createComment(e.nodeValue);
  2359. }
  2360. for (n = 0, r = e.childNodes.length; n < r; n++) t.appendChild(this.Import(e.childNodes[n]));
  2361. return t;
  2362. },
  2363. value: function() {
  2364. return this.div;
  2365. },
  2366. toString: function() {
  2367. return this.div.innerHTML;
  2368. }
  2369. }), e.TeXAtom = e.mbase.Subclass({
  2370. type: "texatom",
  2371. inferRow: n,
  2372. texClass: e.TEXCLASS.ORD,
  2373. setTeXclass: function(e) {
  2374. return this.getPrevClass(e), this.data[0].setTeXclass(), this;
  2375. }
  2376. }), e.NULL = e.mbase().With({
  2377. type: "null"
  2378. });
  2379. var r = e.TEXCLASS, i = {
  2380. ORD: [ 0, 0, r.ORD ],
  2381. ORD11: [ 1, 1, r.ORD ],
  2382. ORD21: [ 2, 1, r.ORD ],
  2383. ORD02: [ 0, 2, r.ORD ],
  2384. ORD55: [ 5, 5, r.ORD ],
  2385. OP: [ 1, 2, r.OP, {
  2386. largeop: !0,
  2387. movablelimits: !0,
  2388. symmetric: !0
  2389. } ],
  2390. OPFIXED: [ 1, 2, r.OP, {
  2391. largeop: !0,
  2392. movablelimits: !0
  2393. } ],
  2394. INTEGRAL: [ 0, 1, r.OP, {
  2395. largeop: !0,
  2396. symmetric: !0
  2397. } ],
  2398. INTEGRAL2: [ 1, 2, r.OP, {
  2399. largeop: !0,
  2400. symmetric: !0
  2401. } ],
  2402. BIN3: [ 3, 3, r.BIN ],
  2403. BIN4: [ 4, 4, r.BIN ],
  2404. BIN01: [ 0, 1, r.BIN ],
  2405. TALLBIN: [ 4, 4, r.BIN, {
  2406. stretchy: !0
  2407. } ],
  2408. BINOP: [ 4, 4, r.BIN, {
  2409. largeop: !0,
  2410. movablelimits: !0
  2411. } ],
  2412. REL: [ 5, 5, r.REL ],
  2413. REL1: [ 1, 1, r.REL, {
  2414. stretchy: !0
  2415. } ],
  2416. REL4: [ 4, 4, r.REL ],
  2417. WIDEREL: [ 5, 5, r.REL, {
  2418. stretchy: !0
  2419. } ],
  2420. RELACCENT: [ 5, 5, r.REL, {
  2421. accent: !0,
  2422. stretchy: !0
  2423. } ],
  2424. OPEN: [ 0, 0, r.OPEN, {
  2425. fence: !0,
  2426. stretchy: !0,
  2427. symmetric: !0
  2428. } ],
  2429. CLOSE: [ 0, 0, r.CLOSE, {
  2430. fence: !0,
  2431. stretchy: !0,
  2432. symmetric: !0
  2433. } ],
  2434. INNER: [ 0, 0, r.INNER ],
  2435. PUNCT: [ 0, 3, r.PUNCT ],
  2436. ACCENT: [ 0, 0, r.ORD, {
  2437. accent: !0
  2438. } ],
  2439. WIDEACCENT: [ 0, 0, r.ORD, {
  2440. accent: !0,
  2441. stretchy: !0
  2442. } ]
  2443. };
  2444. e.mo.Augment({
  2445. SPACE: [ "0em", "0.1111em", "0.1667em", "0.2222em", "0.2667em", "0.3333em" ],
  2446. RANGES: [ [ 32, 127, r.REL, "BasicLatin" ], [ 160, 255, r.ORD, "Latin1Supplement" ], [ 256, 383, r.ORD ], [ 384, 591, r.ORD ], [ 688, 767, r.ORD, "SpacingModLetters" ], [ 768, 879, r.ORD, "CombDiacritMarks" ], [ 880, 1023, r.ORD, "GreekAndCoptic" ], [ 7680, 7935, r.ORD ], [ 8192, 8303, r.PUNCT, "GeneralPunctuation" ], [ 8304, 8351, r.ORD ], [ 8352, 8399, r.ORD ], [ 8400, 8447, r.ORD, "CombDiactForSymbols" ], [ 8448, 8527, r.ORD, "LetterlikeSymbols" ], [ 8528, 8591, r.ORD ], [ 8592, 8703, r.REL, "Arrows" ], [ 8704, 8959, r.BIN, "MathOperators" ], [ 8960, 9215, r.ORD, "MiscTechnical" ], [ 9312, 9471, r.ORD ], [ 9632, 9727, r.ORD, "GeometricShapes" ], [ 9984, 10175, r.ORD, "Dingbats" ], [ 10176, 10223, r.ORD, "MiscMathSymbolsA" ], [ 10496, 10623, r.REL, "SupplementalArrowsB" ], [ 10624, 10751, r.ORD, "MiscMathSymbolsB" ], [ 10752, 11007, r.BIN, "SuppMathOperators" ], [ 11008, 11263, r.ORD ], [ 119808, 120831, r.ORD ] ],
  2447. OPTABLE: {
  2448. prefix: {
  2449. "\u2111": i.ORD11,
  2450. "\u2113": i.ORD11,
  2451. "\u211c": i.ORD11,
  2452. "\u2200": i.ORD21,
  2453. "\u2202": i.ORD21,
  2454. "\u2203": i.ORD21,
  2455. "\u2207": i.ORD21,
  2456. "\u220f": i.OP,
  2457. "\u2210": i.OP,
  2458. "\u2211": i.OP,
  2459. "\u2212": i.BIN01,
  2460. "\u2213": i.BIN01,
  2461. "\u221a": [ 1, 1, r.ORD, {
  2462. stretchy: !0
  2463. } ],
  2464. "\u2220": i.ORD,
  2465. "\u222b": i.INTEGRAL,
  2466. "\u222e": i.INTEGRAL,
  2467. "\u22c0": i.OP,
  2468. "\u22c1": i.OP,
  2469. "\u22c2": i.OP,
  2470. "\u22c3": i.OP,
  2471. "\u2308": i.OPEN,
  2472. "\u230a": i.OPEN,
  2473. "\u27e8": i.OPEN,
  2474. "\u2a00": i.OP,
  2475. "\u2a01": i.OP,
  2476. "\u2a02": i.OP,
  2477. "\u2a04": i.OP,
  2478. "\u2a06": i.OP,
  2479. "\u00ac": i.ORD21,
  2480. "\u00b1": i.BIN01,
  2481. "(": i.OPEN,
  2482. "+": i.BIN01,
  2483. "-": i.BIN01,
  2484. "[": i.OPEN,
  2485. "{": i.OPEN,
  2486. "|": i.OPEN
  2487. },
  2488. postfix: {
  2489. "!": [ 1, 0, r.CLOSE ],
  2490. "&": i.ORD,
  2491. "\u2032": i.ORD02,
  2492. "\u203e": i.WIDEACCENT,
  2493. "\u2309": i.CLOSE,
  2494. "\u230b": i.CLOSE,
  2495. "\u23de": i.WIDEACCENT,
  2496. "\u23df": i.WIDEACCENT,
  2497. "\u266d": i.ORD02,
  2498. "\u266e": i.ORD02,
  2499. "\u266f": i.ORD02,
  2500. "\u27e9": i.CLOSE,
  2501. "\u02c6": i.WIDEACCENT,
  2502. "\u02c7": i.WIDEACCENT,
  2503. "\u02d8": i.ACCENT,
  2504. "\u02d9": i.ACCENT,
  2505. "\u02dc": i.WIDEACCENT,
  2506. "\u0302": i.ACCENT,
  2507. "\u00a8": i.ACCENT,
  2508. "\u00af": i.WIDEACCENT,
  2509. ")": i.CLOSE,
  2510. "]": i.CLOSE,
  2511. "^": i.WIDEACCENT,
  2512. _: i.WIDEACCENT,
  2513. "`": i.ACCENT,
  2514. "|": i.CLOSE,
  2515. "}": i.CLOSE,
  2516. "~": i.WIDEACCENT
  2517. },
  2518. infix: {
  2519. "%": [ 3, 3, r.ORD ],
  2520. "\u2022": i.BIN4,
  2521. "\u2026": i.INNER,
  2522. "\u2044": i.TALLBIN,
  2523. "\u2061": i.ORD,
  2524. "\u2062": i.ORD,
  2525. "\u2063": [ 0, 0, r.ORD, {
  2526. separator: !0
  2527. } ],
  2528. "\u2064": i.ORD,
  2529. "\u2190": i.RELACCENT,
  2530. "\u2191": i.WIDEREL,
  2531. "\u2192": i.RELACCENT,
  2532. "\u2193": i.WIDEREL,
  2533. "\u2194": i.RELACCENT,
  2534. "\u2195": i.WIDEREL,
  2535. "\u2196": i.WIDEREL,
  2536. "\u2197": i.WIDEREL,
  2537. "\u2198": i.WIDEREL,
  2538. "\u2199": i.WIDEREL,
  2539. "\u21a6": i.WIDEREL,
  2540. "\u21a9": i.WIDEREL,
  2541. "\u21aa": i.WIDEREL,
  2542. "\u21bc": i.RELACCENT,
  2543. "\u21bd": i.WIDEREL,
  2544. "\u21c0": i.RELACCENT,
  2545. "\u21c1": i.WIDEREL,
  2546. "\u21cc": i.WIDEREL,
  2547. "\u21d0": i.WIDEREL,
  2548. "\u21d1": i.WIDEREL,
  2549. "\u21d2": i.WIDEREL,
  2550. "\u21d3": i.WIDEREL,
  2551. "\u21d4": i.WIDEREL,
  2552. "\u21d5": i.WIDEREL,
  2553. "\u2208": i.REL,
  2554. "\u2209": i.REL,
  2555. "\u220b": i.REL,
  2556. "\u2212": i.BIN4,
  2557. "\u2213": i.BIN4,
  2558. "\u2215": i.TALLBIN,
  2559. "\u2216": i.BIN4,
  2560. "\u2217": i.BIN4,
  2561. "\u2218": i.BIN4,
  2562. "\u2219": i.BIN4,
  2563. "\u221d": i.REL,
  2564. "\u2223": i.REL,
  2565. "\u2225": i.REL,
  2566. "\u2227": i.BIN4,
  2567. "\u2228": i.BIN4,
  2568. "\u2229": i.BIN4,
  2569. "\u222a": i.BIN4,
  2570. "\u223c": i.REL,
  2571. "\u2240": i.BIN4,
  2572. "\u2243": i.REL,
  2573. "\u2245": i.REL,
  2574. "\u2248": i.REL,
  2575. "\u224d": i.REL,
  2576. "\u2250": i.REL,
  2577. "\u2260": i.REL,
  2578. "\u2261": i.REL,
  2579. "\u2264": i.REL,
  2580. "\u2265": i.REL,
  2581. "\u226a": i.REL,
  2582. "\u226b": i.REL,
  2583. "\u227a": i.REL,
  2584. "\u227b": i.REL,
  2585. "\u2282": i.REL,
  2586. "\u2283": i.REL,
  2587. "\u2286": i.REL,
  2588. "\u2287": i.REL,
  2589. "\u228e": i.BIN4,
  2590. "\u2291": i.REL,
  2591. "\u2292": i.REL,
  2592. "\u2293": i.BIN4,
  2593. "\u2294": i.BIN4,
  2594. "\u2295": i.BIN4,
  2595. "\u2296": i.BIN4,
  2596. "\u2297": i.BIN4,
  2597. "\u2298": i.BIN4,
  2598. "\u2299": i.BIN4,
  2599. "\u22a2": i.REL,
  2600. "\u22a3": i.REL,
  2601. "\u22a4": i.ORD55,
  2602. "\u22a5": i.REL,
  2603. "\u22a8": i.REL,
  2604. "\u22c4": i.BIN4,
  2605. "\u22c5": i.BIN4,
  2606. "\u22c6": i.BIN4,
  2607. "\u22c8": i.REL,
  2608. "\u22ee": i.ORD55,
  2609. "\u22ef": i.INNER,
  2610. "\u22f1": [ 5, 5, r.INNER ],
  2611. "\u2500": [ 0, 0, r.ORD, {
  2612. stretchy: !0
  2613. } ],
  2614. "\u25b3": i.BIN4,
  2615. "\u25b5": i.BIN4,
  2616. "\u25b9": i.BIN4,
  2617. "\u25bd": i.BIN4,
  2618. "\u25bf": i.BIN4,
  2619. "\u25c3": i.BIN4,
  2620. "\u2758": [ 4, 4, r.REL, {
  2621. fence: !0,
  2622. stretchy: !0,
  2623. symmetric: !0
  2624. } ],
  2625. "\u27f5": i.REL1,
  2626. "\u27f6": i.REL1,
  2627. "\u27f7": i.REL1,
  2628. "\u27f8": i.REL1,
  2629. "\u27f9": i.REL1,
  2630. "\u27fa": i.REL1,
  2631. "\u2a2f": i.BIN4,
  2632. "\u2a3f": i.BIN4,
  2633. "\u2aaf": i.REL,
  2634. "\u2ab0": i.REL,
  2635. "\u00b1": i.BIN4,
  2636. "\u00b7": i.BIN4,
  2637. "\u00d7": i.BIN4,
  2638. "\u00f7": i.BIN4,
  2639. "*": i.BIN3,
  2640. "+": i.BIN4,
  2641. ",": [ 0, 3, r.PUNCT, {
  2642. separator: !0
  2643. } ],
  2644. "-": i.BIN4,
  2645. ".": [ 3, 3, r.ORD ],
  2646. "/": i.ORD11,
  2647. ":": [ 1, 2, r.REL ],
  2648. ";": [ 0, 3, r.PUNCT, {
  2649. separator: !0
  2650. } ],
  2651. "<": i.REL,
  2652. "=": i.REL,
  2653. ">": i.REL,
  2654. "?": [ 1, 1, r.CLOSE ],
  2655. "\\": i.ORD,
  2656. _: i.ORD11,
  2657. "|": [ 2, 2, r.ORD, {
  2658. fence: !0,
  2659. stretchy: !0,
  2660. symmetric: !0
  2661. } ],
  2662. "#": i.ORD,
  2663. $: i.ORD,
  2664. ".": [ 0, 3, r.PUNCT, {
  2665. separator: !0
  2666. } ],
  2667. "\u02b9": i.ORD,
  2668. "\u02c9": i.ACCENT,
  2669. "\u02ca": i.ACCENT,
  2670. "\u02cb": i.ACCENT,
  2671. "\u0300": i.ACCENT,
  2672. "\u0301": i.ACCENT,
  2673. "\u0303": i.WIDEACCENT,
  2674. "\u0304": i.ACCENT,
  2675. "\u0306": i.ACCENT,
  2676. "\u0307": i.ACCENT,
  2677. "\u0308": i.ACCENT,
  2678. "\u030c": i.ACCENT,
  2679. "\u0332": i.WIDEACCENT,
  2680. "\u0338": i.REL4,
  2681. "\u2015": [ 0, 0, r.ORD, {
  2682. stretchy: !0
  2683. } ],
  2684. "\u2017": [ 0, 0, r.ORD, {
  2685. stretchy: !0
  2686. } ],
  2687. "\u2020": i.BIN3,
  2688. "\u2021": i.BIN3,
  2689. "\u20d7": i.ACCENT,
  2690. "\u2118": i.ORD,
  2691. "\u2205": i.ORD,
  2692. "\u221e": i.ORD,
  2693. "\u2305": i.BIN3,
  2694. "\u2306": i.BIN3,
  2695. "\u2322": i.REL4,
  2696. "\u2323": i.REL4,
  2697. "\u2329": i.OPEN,
  2698. "\u232a": i.CLOSE,
  2699. "\u23aa": i.ORD,
  2700. "\u23af": [ 0, 0, r.ORD, {
  2701. stretchy: !0
  2702. } ],
  2703. "\u23b0": i.OPEN,
  2704. "\u23b1": i.CLOSE,
  2705. "\u25ef": i.BIN3,
  2706. "\u2660": i.ORD,
  2707. "\u2661": i.ORD,
  2708. "\u2662": i.ORD,
  2709. "\u2663": i.ORD,
  2710. "\u27ee": i.OPEN,
  2711. "\u27ef": i.CLOSE,
  2712. "\u27fc": i.REL4,
  2713. "\u3008": i.OPEN,
  2714. "\u3009": i.CLOSE,
  2715. "\ufe37": i.WIDEACCENT,
  2716. "\ufe38": i.WIDEACCENT
  2717. }
  2718. }
  2719. }, {
  2720. OPTYPES: i
  2721. });
  2722. }(MathJax.ElementJax.mml), MathJax.ElementJax.mml.loadComplete("jax.js"), MathJax.InputJax.TeX = MathJax.InputJax({
  2723. id: "TeX",
  2724. version: "1.1.1",
  2725. directory: MathJax.InputJax.directory + "/TeX",
  2726. extensionDir: MathJax.InputJax.extensionDir + "/TeX",
  2727. config: {
  2728. TagSide: "right",
  2729. TagIndent: "0.8em",
  2730. MultLineWidth: "85%"
  2731. }
  2732. }), MathJax.InputJax.TeX.Register("math/tex"), MathJax.InputJax.TeX.loadComplete("config.js"), function(e) {
  2733. var t = !0, n = !1, r, i = String.fromCharCode(160), s = MathJax.Object.Subclass({
  2734. Init: function(e) {
  2735. this.global = {}, this.data = [ o.start().With({
  2736. global: this.global
  2737. }) ], e && (this.data[0].env = e), this.env = this.data[0].env;
  2738. },
  2739. Push: function() {
  2740. var e, n, i, s;
  2741. for (e = 0, n = arguments.length; e < n; e++) {
  2742. i = arguments[e], i instanceof r.mbase && (i = o.mml(i)), i.global = this.global, s = this.data.length ? this.Top().checkItem(i) : t;
  2743. if (s instanceof Array) this.Pop(), this.Push.apply(this, s); else if (s instanceof o) this.Pop(), this.Push(s); else if (s) {
  2744. this.data.push(i);
  2745. if (i.env) {
  2746. for (var u in this.env) this.env.hasOwnProperty(u) && (i.env[u] = this.env[u]);
  2747. this.env = i.env;
  2748. } else i.env = this.env;
  2749. }
  2750. }
  2751. },
  2752. Pop: function() {
  2753. var e = this.data.pop();
  2754. return e.isOpen || delete e.env, this.env = this.data.length ? this.Top().env : {}, e;
  2755. },
  2756. Top: function(e) {
  2757. return e == null && (e = 1), this.data.length < e ? null : this.data[this.data.length - e];
  2758. },
  2759. Prev: function(e) {
  2760. var t = this.Top();
  2761. return e ? t.data[t.data.length - 1] : t.Pop();
  2762. },
  2763. toString: function() {
  2764. return "stack[\n " + this.data.join("\n ") + "\n]";
  2765. }
  2766. }), o = s.Item = MathJax.Object.Subclass({
  2767. type: "base",
  2768. closeError: "Extra close brace or missing open brace",
  2769. rightError: "Missing \\left or extra \\right",
  2770. Init: function() {
  2771. this.isOpen && (this.env = {}), this.data = [], this.Push.apply(this, arguments);
  2772. },
  2773. Push: function() {
  2774. this.data.push.apply(this.data, arguments);
  2775. },
  2776. Pop: function() {
  2777. return this.data.pop();
  2778. },
  2779. mmlData: function(e, n) {
  2780. return e == null && (e = t), this.data.length === 1 && !n ? this.data[0] : r.mrow.apply(r, this.data).With(e ? {
  2781. inferred: t
  2782. } : {});
  2783. },
  2784. checkItem: function(r) {
  2785. return r.type === "over" && this.isOpen && (r.num = this.mmlData(n), this.data = []), r.type === "cell" && this.isOpen && e.Error("Misplaced " + r.name), r.isClose && this[r.type + "Error"] && e.Error(this[r.type + "Error"]), r.isNotStack ? (this.Push(r.data[0]), n) : t;
  2786. },
  2787. With: function(e) {
  2788. for (var t in e) e.hasOwnProperty(t) && (this[t] = e[t]);
  2789. return this;
  2790. },
  2791. toString: function() {
  2792. return this.type + "[" + this.data.join("; ") + "]";
  2793. }
  2794. });
  2795. o.start = o.Subclass({
  2796. type: "start",
  2797. isOpen: t,
  2798. checkItem: function(e) {
  2799. return e.type === "stop" ? o.mml(this.mmlData()) : this.SUPER(arguments).checkItem.call(this, e);
  2800. }
  2801. }), o.stop = o.Subclass({
  2802. type: "stop",
  2803. isClose: t
  2804. }), o.open = o.Subclass({
  2805. type: "open",
  2806. isOpen: t,
  2807. stopError: "Extra open brace or missing close brace",
  2808. checkItem: function(e) {
  2809. if (e.type === "close") {
  2810. var t = this.mmlData();
  2811. return o.mml(r.TeXAtom(t));
  2812. }
  2813. return this.SUPER(arguments).checkItem.call(this, e);
  2814. }
  2815. }), o.close = o.Subclass({
  2816. type: "close",
  2817. isClose: t
  2818. }), o.subsup = o.Subclass({
  2819. type: "subsup",
  2820. stopError: "Missing superscript or subscript argument",
  2821. checkItem: function(n) {
  2822. var r = [ "", "subscript", "superscript" ][this.position];
  2823. if (n.type === "open" || n.type === "left") return t;
  2824. if (n.type === "mml") return this.data[0].SetData(this.position, n.data[0]), o.mml(this.data[0]);
  2825. this.SUPER(arguments).checkItem.call(this, n) && e.Error("Missing open brace for " + r);
  2826. },
  2827. Pop: function() {}
  2828. }), o.over = o.Subclass({
  2829. type: "over",
  2830. isClose: t,
  2831. name: "\\over",
  2832. checkItem: function(i, s) {
  2833. i.type === "over" && e.Error("Ambiguous use of " + i.name);
  2834. if (i.isClose) {
  2835. var u = r.mfrac(this.num, this.mmlData(n));
  2836. this.thickness != null && (u.linethickness = this.thickness);
  2837. if (this.open || this.close) u.texClass = r.TEXCLASS.INNER, u.texWithDelims = t, u = r.mfenced(u).With({
  2838. open: this.open,
  2839. close: this.close
  2840. });
  2841. return [ o.mml(u), i ];
  2842. }
  2843. return this.SUPER(arguments).checkItem.call(this, i);
  2844. },
  2845. toString: function() {
  2846. return "over[" + this.num + " / " + this.data.join("; ") + "]";
  2847. }
  2848. }), o.left = o.Subclass({
  2849. type: "left",
  2850. isOpen: t,
  2851. delim: "(",
  2852. stopError: "Extra \\left or missing \\right",
  2853. checkItem: function(e) {
  2854. if (e.type === "right") {
  2855. var t = r.mfenced(this.data.length === 1 ? this.data[0] : r.mrow.apply(r, this.data));
  2856. return o.mml(t.With({
  2857. open: this.delim,
  2858. close: e.delim
  2859. }));
  2860. }
  2861. return this.SUPER(arguments).checkItem.call(this, e);
  2862. }
  2863. }), o.right = o.Subclass({
  2864. type: "right",
  2865. isClose: t,
  2866. delim: ")"
  2867. }), o.begin = o.Subclass({
  2868. type: "begin",
  2869. isOpen: t,
  2870. checkItem: function(t) {
  2871. return t.type === "end" ? (t.name !== this.name && e.Error("\\begin{" + this.name + "} ended with \\end{" + t.name + "}"), this.end ? this.parse[this.end].call(this.parse, this, this.data) : o.mml(this.mmlData())) : (t.type === "stop" && e.Error("Missing \\end{" + this.name + "}"), this.SUPER(arguments).checkItem.call(this, t));
  2872. }
  2873. }), o.end = o.Subclass({
  2874. type: "end",
  2875. isClose: t
  2876. }), o.style = o.Subclass({
  2877. type: "style",
  2878. checkItem: function(e) {
  2879. if (!e.isClose) return this.SUPER(arguments).checkItem.call(this, e);
  2880. var t = r.mstyle.apply(r, this.data).With(this.styles);
  2881. return [ o.mml(t), e ];
  2882. }
  2883. }), o.position = o.Subclass({
  2884. type: "position",
  2885. checkItem: function(t) {
  2886. t.isClose && e.Error("Missing box for " + this.name);
  2887. if (t.isNotStack) {
  2888. var n = t.mmlData();
  2889. switch (this.move) {
  2890. case "vertical":
  2891. return n = r.mpadded(n).With({
  2892. height: this.dh,
  2893. depth: this.dd,
  2894. voffset: this.dh
  2895. }), [ o.mml(n) ];
  2896. case "horizontal":
  2897. return [ o.mml(this.left), t, o.mml(this.right) ];
  2898. }
  2899. }
  2900. return this.SUPER(arguments).checkItem.call(this, t);
  2901. }
  2902. }), o.array = o.Subclass({
  2903. type: "array",
  2904. isOpen: t,
  2905. arraydef: {},
  2906. Init: function() {
  2907. this.table = [], this.row = [], this.env = {}, this.SUPER(arguments).Init.apply(this, arguments);
  2908. },
  2909. checkItem: function(t) {
  2910. if (t.isClose && t.type !== "over") {
  2911. if (t.isEntry) return this.EndEntry(), this.clearEnv(), n;
  2912. if (t.isCR) return this.EndEntry(), this.EndRow(), this.clearEnv(), n;
  2913. this.EndTable(), this.clearEnv();
  2914. var i = r.mtable.apply(r, this.table).With(this.arraydef);
  2915. if (this.open || this.close) i = r.mfenced(i).With({
  2916. open: this.open,
  2917. close: this.close
  2918. });
  2919. i = o.mml(i);
  2920. if (this.requireClose) {
  2921. if (t.type === "close") return i;
  2922. e.Error("Missing close brace");
  2923. }
  2924. return [ i, t ];
  2925. }
  2926. return this.SUPER(arguments).checkItem.call(this, t);
  2927. },
  2928. EndEntry: function() {
  2929. this.row.push(r.mtd.apply(r, this.data)), this.data = [];
  2930. },
  2931. EndRow: function() {
  2932. this.table.push(r.mtr.apply(r, this.row)), this.row = [];
  2933. },
  2934. EndTable: function() {
  2935. if (this.data.length || this.row.length) this.EndEntry(), this.EndRow();
  2936. this.checkLines();
  2937. },
  2938. checkLines: function() {
  2939. if (this.arraydef.rowlines) {
  2940. var e = this.arraydef.rowlines.split(/ /);
  2941. e.length === this.table.length ? (this.arraydef.frame = e.pop(), this.arraydef.rowlines = e.join(" ")) : e.length < this.table.length - 1 && (this.arraydef.rowlines += " none");
  2942. }
  2943. },
  2944. clearEnv: function() {
  2945. for (var e in this.env) this.env.hasOwnProperty(e) && delete this.env[e];
  2946. }
  2947. }), o.cell = o.Subclass({
  2948. type: "cell",
  2949. isClose: t
  2950. }), o.mml = o.Subclass({
  2951. type: "mml",
  2952. isNotStack: t,
  2953. Push: function() {
  2954. for (var e = 0, n = arguments.length; e < n; e++) arguments[e].type !== "mo" && arguments[e].isEmbellished() && (arguments[e] = r.TeXAtom(arguments[e]).With({
  2955. isEmbellishedWrapper: t
  2956. }));
  2957. this.data.push.apply(this.data, arguments);
  2958. },
  2959. Add: function() {
  2960. return this.data.push.apply(this.data, arguments), this;
  2961. }
  2962. });
  2963. var u = {}, a = function() {
  2964. r = MathJax.ElementJax.mml, MathJax.Hub.Insert(u, {
  2965. letter: /[a-z]/i,
  2966. digit: /[0-9.]/,
  2967. number: /^(?:[0-9]+(?:\{,\}[0-9]{3})*(?:\.[0-9]*)*|\.[0-9]+)/,
  2968. special: {
  2969. "\\": "ControlSequence",
  2970. "{": "Open",
  2971. "}": "Close",
  2972. "~": "Tilde",
  2973. "^": "Superscript",
  2974. _: "Subscript",
  2975. " ": "Space",
  2976. " ": "Space",
  2977. "\r": "Space",
  2978. "\n": "Space",
  2979. "'": "Prime",
  2980. "%": "Comment",
  2981. "&": "Entry",
  2982. "#": "Hash",
  2983. "\u2019": "Prime"
  2984. },
  2985. remap: {
  2986. "-": "2212",
  2987. "*": "2217"
  2988. },
  2989. mathchar0mi: {
  2990. alpha: "03B1",
  2991. beta: "03B2",
  2992. gamma: "03B3",
  2993. delta: "03B4",
  2994. epsilon: "03F5",
  2995. zeta: "03B6",
  2996. eta: "03B7",
  2997. theta: "03B8",
  2998. iota: "03B9",
  2999. kappa: "03BA",
  3000. lambda: "03BB",
  3001. mu: "03BC",
  3002. nu: "03BD",
  3003. xi: "03BE",
  3004. omicron: "03BF",
  3005. pi: "03C0",
  3006. rho: "03C1",
  3007. sigma: "03C3",
  3008. tau: "03C4",
  3009. upsilon: "03C5",
  3010. phi: "03D5",
  3011. chi: "03C7",
  3012. psi: "03C8",
  3013. omega: "03C9",
  3014. varepsilon: "03B5",
  3015. vartheta: "03D1",
  3016. varpi: "03D6",
  3017. varrho: "03F1",
  3018. varsigma: "03C2",
  3019. varphi: "03C6",
  3020. S: "00A7",
  3021. aleph: [ "2135", {
  3022. mathvariant: r.VARIANT.NORMAL
  3023. } ],
  3024. hbar: "210F",
  3025. imath: "0131",
  3026. jmath: "0237",
  3027. ell: "2113",
  3028. wp: [ "2118", {
  3029. mathvariant: r.VARIANT.NORMAL
  3030. } ],
  3031. Re: [ "211C", {
  3032. mathvariant: r.VARIANT.NORMAL
  3033. } ],
  3034. Im: [ "2111", {
  3035. mathvariant: r.VARIANT.NORMAL
  3036. } ],
  3037. partial: [ "2202", {
  3038. mathvariant: r.VARIANT.NORMAL
  3039. } ],
  3040. infty: [ "221E", {
  3041. mathvariant: r.VARIANT.NORMAL
  3042. } ],
  3043. prime: [ "2032", {
  3044. mathvariant: r.VARIANT.NORMAL
  3045. } ],
  3046. emptyset: [ "2205", {
  3047. mathvariant: r.VARIANT.NORMAL
  3048. } ],
  3049. nabla: [ "2207", {
  3050. mathvariant: r.VARIANT.NORMAL
  3051. } ],
  3052. top: [ "22A4", {
  3053. mathvariant: r.VARIANT.NORMAL
  3054. } ],
  3055. bot: [ "22A5", {
  3056. mathvariant: r.VARIANT.NORMAL
  3057. } ],
  3058. angle: [ "2220", {
  3059. mathvariant: r.VARIANT.NORMAL
  3060. } ],
  3061. triangle: [ "25B3", {
  3062. mathvariant: r.VARIANT.NORMAL
  3063. } ],
  3064. backslash: [ "2216", {
  3065. mathvariant: r.VARIANT.NORMAL
  3066. } ],
  3067. forall: [ "2200", {
  3068. mathvariant: r.VARIANT.NORMAL
  3069. } ],
  3070. exists: [ "2203", {
  3071. mathvariant: r.VARIANT.NORMAL
  3072. } ],
  3073. neg: [ "00AC", {
  3074. mathvariant: r.VARIANT.NORMAL
  3075. } ],
  3076. lnot: [ "00AC", {
  3077. mathvariant: r.VARIANT.NORMAL
  3078. } ],
  3079. flat: [ "266D", {
  3080. mathvariant: r.VARIANT.NORMAL
  3081. } ],
  3082. natural: [ "266E", {
  3083. mathvariant: r.VARIANT.NORMAL
  3084. } ],
  3085. sharp: [ "266F", {
  3086. mathvariant: r.VARIANT.NORMAL
  3087. } ],
  3088. clubsuit: [ "2663", {
  3089. mathvariant: r.VARIANT.NORMAL
  3090. } ],
  3091. diamondsuit: [ "2662", {
  3092. mathvariant: r.VARIANT.NORMAL
  3093. } ],
  3094. heartsuit: [ "2661", {
  3095. mathvariant: r.VARIANT.NORMAL
  3096. } ],
  3097. spadesuit: [ "2660", {
  3098. mathvariant: r.VARIANT.NORMAL
  3099. } ]
  3100. },
  3101. mathchar0mo: {
  3102. surd: "221A",
  3103. coprod: [ "2210", {
  3104. texClass: r.TEXCLASS.OP,
  3105. movesupsub: t
  3106. } ],
  3107. bigvee: [ "22C1", {
  3108. texClass: r.TEXCLASS.OP,
  3109. movesupsub: t
  3110. } ],
  3111. bigwedge: [ "22C0", {
  3112. texClass: r.TEXCLASS.OP,
  3113. movesupsub: t
  3114. } ],
  3115. biguplus: [ "2A04", {
  3116. texClass: r.TEXCLASS.OP,
  3117. movesupsub: t
  3118. } ],
  3119. bigcap: [ "22C2", {
  3120. texClass: r.TEXCLASS.OP,
  3121. movesupsub: t
  3122. } ],
  3123. bigcup: [ "22C3", {
  3124. texClass: r.TEXCLASS.OP,
  3125. movesupsub: t
  3126. } ],
  3127. "int": [ "222B", {
  3128. texClass: r.TEXCLASS.OP
  3129. } ],
  3130. intop: [ "222B", {
  3131. texClass: r.TEXCLASS.OP,
  3132. movesupsub: t,
  3133. movablelimits: t
  3134. } ],
  3135. iint: [ "222C", {
  3136. texClass: r.TEXCLASS.OP
  3137. } ],
  3138. iiint: [ "222D", {
  3139. texClass: r.TEXCLASS.OP
  3140. } ],
  3141. prod: [ "220F", {
  3142. texClass: r.TEXCLASS.OP,
  3143. movesupsub: t
  3144. } ],
  3145. sum: [ "2211", {
  3146. texClass: r.TEXCLASS.OP,
  3147. movesupsub: t
  3148. } ],
  3149. bigotimes: [ "2A02", {
  3150. texClass: r.TEXCLASS.OP,
  3151. movesupsub: t
  3152. } ],
  3153. bigoplus: [ "2A01", {
  3154. texClass: r.TEXCLASS.OP,
  3155. movesupsub: t
  3156. } ],
  3157. bigodot: [ "2A00", {
  3158. texClass: r.TEXCLASS.OP,
  3159. movesupsub: t
  3160. } ],
  3161. oint: [ "222E", {
  3162. texClass: r.TEXCLASS.OP
  3163. } ],
  3164. bigsqcup: [ "2A06", {
  3165. texClass: r.TEXCLASS.OP,
  3166. movesupsub: t
  3167. } ],
  3168. smallint: [ "222B", {
  3169. largeop: n
  3170. } ],
  3171. triangleleft: "25C3",
  3172. triangleright: "25B9",
  3173. bigtriangleup: "25B3",
  3174. bigtriangledown: "25BD",
  3175. wedge: "2227",
  3176. land: "2227",
  3177. vee: "2228",
  3178. lor: "2228",
  3179. cap: "2229",
  3180. cup: "222A",
  3181. ddagger: "2021",
  3182. dagger: "2020",
  3183. sqcap: "2293",
  3184. sqcup: "2294",
  3185. uplus: "228E",
  3186. amalg: "2A3F",
  3187. diamond: "22C4",
  3188. bullet: "2219",
  3189. wr: "2240",
  3190. div: "00F7",
  3191. odot: [ "2299", {
  3192. largeop: n
  3193. } ],
  3194. oslash: [ "2298", {
  3195. largeop: n
  3196. } ],
  3197. otimes: [ "2297", {
  3198. largeop: n
  3199. } ],
  3200. ominus: [ "2296", {
  3201. largeop: n
  3202. } ],
  3203. oplus: [ "2295", {
  3204. largeop: n
  3205. } ],
  3206. mp: "2213",
  3207. pm: "00B1",
  3208. circ: "2218",
  3209. bigcirc: "25EF",
  3210. setminus: "2216",
  3211. cdot: "22C5",
  3212. ast: "2217",
  3213. times: "00D7",
  3214. star: "22C6",
  3215. propto: "221D",
  3216. sqsubseteq: "2291",
  3217. sqsupseteq: "2292",
  3218. parallel: "2225",
  3219. mid: "2223",
  3220. dashv: "22A3",
  3221. vdash: "22A2",
  3222. leq: "2264",
  3223. le: "2264",
  3224. geq: "2265",
  3225. ge: "2265",
  3226. lt: "003C",
  3227. gt: "003E",
  3228. succ: "227B",
  3229. prec: "227A",
  3230. approx: "2248",
  3231. succeq: "2AB0",
  3232. preceq: "2AAF",
  3233. supset: "2283",
  3234. subset: "2282",
  3235. supseteq: "2287",
  3236. subseteq: "2286",
  3237. "in": "2208",
  3238. ni: "220B",
  3239. notin: "2209",
  3240. owns: "220B",
  3241. gg: "226B",
  3242. ll: "226A",
  3243. sim: "223C",
  3244. simeq: "2243",
  3245. perp: "22A5",
  3246. equiv: "2261",
  3247. asymp: "224D",
  3248. smile: "2323",
  3249. frown: "2322",
  3250. ne: "2260",
  3251. neq: "2260",
  3252. cong: "2245",
  3253. doteq: "2250",
  3254. bowtie: "22C8",
  3255. models: "22A8",
  3256. notChar: "0338",
  3257. Leftrightarrow: "21D4",
  3258. Leftarrow: "21D0",
  3259. Rightarrow: "21D2",
  3260. leftrightarrow: "2194",
  3261. leftarrow: "2190",
  3262. gets: "2190",
  3263. rightarrow: "2192",
  3264. to: "2192",
  3265. mapsto: "21A6",
  3266. leftharpoonup: "21BC",
  3267. leftharpoondown: "21BD",
  3268. rightharpoonup: "21C0",
  3269. rightharpoondown: "21C1",
  3270. nearrow: "2197",
  3271. searrow: "2198",
  3272. nwarrow: "2196",
  3273. swarrow: "2199",
  3274. rightleftharpoons: "21CC",
  3275. hookrightarrow: "21AA",
  3276. hookleftarrow: "21A9",
  3277. longleftarrow: "27F5",
  3278. Longleftarrow: "27F8",
  3279. longrightarrow: "27F6",
  3280. Longrightarrow: "27F9",
  3281. Longleftrightarrow: "27FA",
  3282. longleftrightarrow: "27F7",
  3283. longmapsto: "27FC",
  3284. ldots: "2026",
  3285. cdots: "22EF",
  3286. vdots: "22EE",
  3287. ddots: "22F1",
  3288. dots: "2026",
  3289. dotsc: "2026",
  3290. dotsb: "22EF",
  3291. dotsm: "22EF",
  3292. dotsi: "22EF",
  3293. dotso: "2026",
  3294. ldotp: [ "002E", {
  3295. texClass: r.TEXCLASS.PUNCT
  3296. } ],
  3297. cdotp: [ "22C5", {
  3298. texClass: r.TEXCLASS.PUNCT
  3299. } ],
  3300. colon: [ "003A", {
  3301. texClass: r.TEXCLASS.PUNCT
  3302. } ]
  3303. },
  3304. mathchar7: {
  3305. Gamma: "0393",
  3306. Delta: "0394",
  3307. Theta: "0398",
  3308. Lambda: "039B",
  3309. Xi: "039E",
  3310. Pi: "03A0",
  3311. Sigma: "03A3",
  3312. Upsilon: "03A5",
  3313. Phi: "03A6",
  3314. Psi: "03A8",
  3315. Omega: "03A9",
  3316. _: "005F",
  3317. "#": "0023",
  3318. $: "0024",
  3319. "%": "0025",
  3320. "&": "0026",
  3321. And: "0026"
  3322. },
  3323. delimiter: {
  3324. "(": "(",
  3325. ")": ")",
  3326. "[": "[",
  3327. "]": "]",
  3328. "<": "27E8",
  3329. ">": "27E9",
  3330. "\\lt": "27E8",
  3331. "\\gt": "27E9",
  3332. "/": "/",
  3333. "|": [ "|", {
  3334. texClass: r.TEXCLASS.ORD
  3335. } ],
  3336. ".": "",
  3337. "\\\\": "\\",
  3338. "\\lmoustache": "23B0",
  3339. "\\rmoustache": "23B1",
  3340. "\\lgroup": "27EE",
  3341. "\\rgroup": "27EF",
  3342. "\\arrowvert": "23D0",
  3343. "\\Arrowvert": "2016",
  3344. "\\bracevert": "23AA",
  3345. "\\Vert": [ "2225", {
  3346. texClass: r.TEXCLASS.ORD
  3347. } ],
  3348. "\\|": [ "2225", {
  3349. texClass: r.TEXCLASS.ORD
  3350. } ],
  3351. "\\vert": [ "|", {
  3352. texClass: r.TEXCLASS.ORD
  3353. } ],
  3354. "\\uparrow": "2191",
  3355. "\\downarrow": "2193",
  3356. "\\updownarrow": "2195",
  3357. "\\Uparrow": "21D1",
  3358. "\\Downarrow": "21D3",
  3359. "\\Updownarrow": "21D5",
  3360. "\\backslash": "\\",
  3361. "\\rangle": "27E9",
  3362. "\\langle": "27E8",
  3363. "\\rbrace": "}",
  3364. "\\lbrace": "{",
  3365. "\\}": "}",
  3366. "\\{": "{",
  3367. "\\rceil": "2309",
  3368. "\\lceil": "2308",
  3369. "\\rfloor": "230B",
  3370. "\\lfloor": "230A",
  3371. "\\lbrack": "[",
  3372. "\\rbrack": "]"
  3373. },
  3374. macros: {
  3375. displaystyle: [ "SetStyle", "D", t, 0 ],
  3376. textstyle: [ "SetStyle", "T", n, 0 ],
  3377. scriptstyle: [ "SetStyle", "S", n, 1 ],
  3378. scriptscriptstyle: [ "SetStyle", "SS", n, 2 ],
  3379. rm: [ "SetFont", r.VARIANT.NORMAL ],
  3380. mit: [ "SetFont", r.VARIANT.ITALIC ],
  3381. oldstyle: [ "SetFont", r.VARIANT.OLDSTYLE ],
  3382. cal: [ "SetFont", r.VARIANT.CALIGRAPHIC ],
  3383. it: [ "SetFont", r.VARIANT.ITALIC ],
  3384. bf: [ "SetFont", r.VARIANT.BOLD ],
  3385. bbFont: [ "SetFont", r.VARIANT.DOUBLESTRUCK ],
  3386. scr: [ "SetFont", r.VARIANT.SCRIPT ],
  3387. frak: [ "SetFont", r.VARIANT.FRAKTUR ],
  3388. sf: [ "SetFont", r.VARIANT.SANSSERIF ],
  3389. tt: [ "SetFont", r.VARIANT.MONOSPACE ],
  3390. tiny: [ "SetSize", .5 ],
  3391. Tiny: [ "SetSize", .6 ],
  3392. scriptsize: [ "SetSize", .7 ],
  3393. small: [ "SetSize", .85 ],
  3394. normalsize: [ "SetSize", 1 ],
  3395. large: [ "SetSize", 1.2 ],
  3396. Large: [ "SetSize", 1.44 ],
  3397. LARGE: [ "SetSize", 1.73 ],
  3398. huge: [ "SetSize", 2.07 ],
  3399. Huge: [ "SetSize", 2.49 ],
  3400. arcsin: [ "NamedOp", 0 ],
  3401. arccos: [ "NamedOp", 0 ],
  3402. arctan: [ "NamedOp", 0 ],
  3403. arg: [ "NamedOp", 0 ],
  3404. cos: [ "NamedOp", 0 ],
  3405. cosh: [ "NamedOp", 0 ],
  3406. cot: [ "NamedOp", 0 ],
  3407. coth: [ "NamedOp", 0 ],
  3408. csc: [ "NamedOp", 0 ],
  3409. deg: [ "NamedOp", 0 ],
  3410. det: "NamedOp",
  3411. dim: [ "NamedOp", 0 ],
  3412. exp: [ "NamedOp", 0 ],
  3413. gcd: "NamedOp",
  3414. hom: [ "NamedOp", 0 ],
  3415. inf: "NamedOp",
  3416. ker: [ "NamedOp", 0 ],
  3417. lg: [ "NamedOp", 0 ],
  3418. lim: "NamedOp",
  3419. liminf: [ "NamedOp", null, "lim&thinsp;inf" ],
  3420. limsup: [ "NamedOp", null, "lim&thinsp;sup" ],
  3421. ln: [ "NamedOp", 0 ],
  3422. log: [ "NamedOp", 0 ],
  3423. max: "NamedOp",
  3424. min: "NamedOp",
  3425. Pr: "NamedOp",
  3426. sec: [ "NamedOp", 0 ],
  3427. sin: [ "NamedOp", 0 ],
  3428. sinh: [ "NamedOp", 0 ],
  3429. sup: "NamedOp",
  3430. tan: [ "NamedOp", 0 ],
  3431. tanh: [ "NamedOp", 0 ],
  3432. limits: [ "Limits", 1 ],
  3433. nolimits: [ "Limits", 0 ],
  3434. overline: [ "UnderOver", "203E" ],
  3435. underline: [ "UnderOver", "005F" ],
  3436. overbrace: [ "UnderOver", "23DE", 1 ],
  3437. underbrace: [ "UnderOver", "23DF", 1 ],
  3438. overrightarrow: [ "UnderOver", "2192" ],
  3439. underrightarrow: [ "UnderOver", "2192" ],
  3440. overleftarrow: [ "UnderOver", "2190" ],
  3441. underleftarrow: [ "UnderOver", "2190" ],
  3442. overleftrightarrow: [ "UnderOver", "2194" ],
  3443. underleftrightarrow: [ "UnderOver", "2194" ],
  3444. overset: "Overset",
  3445. underset: "Underset",
  3446. stackrel: [ "Macro", "\\mathrel{\\mathop{#2}\\limits^{#1}}", 2 ],
  3447. over: "Over",
  3448. overwithdelims: "Over",
  3449. atop: "Over",
  3450. atopwithdelims: "Over",
  3451. above: "Over",
  3452. abovewithdelims: "Over",
  3453. brace: [ "Over", "{", "}" ],
  3454. brack: [ "Over", "[", "]" ],
  3455. choose: [ "Over", "(", ")" ],
  3456. frac: "Frac",
  3457. sqrt: "Sqrt",
  3458. root: "Root",
  3459. uproot: [ "MoveRoot", "upRoot" ],
  3460. leftroot: [ "MoveRoot", "leftRoot" ],
  3461. left: "LeftRight",
  3462. right: "LeftRight",
  3463. llap: "Lap",
  3464. rlap: "Lap",
  3465. raise: "RaiseLower",
  3466. lower: "RaiseLower",
  3467. moveleft: "MoveLeftRight",
  3468. moveright: "MoveLeftRight",
  3469. ",": [ "Spacer", r.LENGTH.THINMATHSPACE ],
  3470. ":": [ "Spacer", r.LENGTH.THINMATHSPACE ],
  3471. ">": [ "Spacer", r.LENGTH.MEDIUMMATHSPACE ],
  3472. ";": [ "Spacer", r.LENGTH.THICKMATHSPACE ],
  3473. "!": [ "Spacer", r.LENGTH.NEGATIVETHINMATHSPACE ],
  3474. enspace: [ "Spacer", ".5em" ],
  3475. quad: [ "Spacer", "1em" ],
  3476. qquad: [ "Spacer", "2em" ],
  3477. thinspace: [ "Spacer", r.LENGTH.THINMATHSPACE ],
  3478. negthinspace: [ "Spacer", r.LENGTH.NEGATIVETHINMATHSPACE ],
  3479. hskip: "Hskip",
  3480. hspace: "Hskip",
  3481. kern: "Hskip",
  3482. mskip: "Hskip",
  3483. mspace: "Hskip",
  3484. mkern: "Hskip",
  3485. Rule: [ "Rule" ],
  3486. Space: [ "Rule", "blank" ],
  3487. big: [ "MakeBig", r.TEXCLASS.ORD, .85 ],
  3488. Big: [ "MakeBig", r.TEXCLASS.ORD, 1.15 ],
  3489. bigg: [ "MakeBig", r.TEXCLASS.ORD, 1.45 ],
  3490. Bigg: [ "MakeBig", r.TEXCLASS.ORD, 1.75 ],
  3491. bigl: [ "MakeBig", r.TEXCLASS.OPEN, .85 ],
  3492. Bigl: [ "MakeBig", r.TEXCLASS.OPEN, 1.15 ],
  3493. biggl: [ "MakeBig", r.TEXCLASS.OPEN, 1.45 ],
  3494. Biggl: [ "MakeBig", r.TEXCLASS.OPEN, 1.75 ],
  3495. bigr: [ "MakeBig", r.TEXCLASS.CLOSE, .85 ],
  3496. Bigr: [ "MakeBig", r.TEXCLASS.CLOSE, 1.15 ],
  3497. biggr: [ "MakeBig", r.TEXCLASS.CLOSE, 1.45 ],
  3498. Biggr: [ "MakeBig", r.TEXCLASS.CLOSE, 1.75 ],
  3499. bigm: [ "MakeBig", r.TEXCLASS.REL, .85 ],
  3500. Bigm: [ "MakeBig", r.TEXCLASS.REL, 1.15 ],
  3501. biggm: [ "MakeBig", r.TEXCLASS.REL, 1.45 ],
  3502. Biggm: [ "MakeBig", r.TEXCLASS.REL, 1.75 ],
  3503. mathord: [ "TeXAtom", r.TEXCLASS.ORD ],
  3504. mathop: [ "TeXAtom", r.TEXCLASS.OP ],
  3505. mathopen: [ "TeXAtom", r.TEXCLASS.OPEN ],
  3506. mathclose: [ "TeXAtom", r.TEXCLASS.CLOSE ],
  3507. mathbin: [ "TeXAtom", r.TEXCLASS.BIN ],
  3508. mathrel: [ "TeXAtom", r.TEXCLASS.REL ],
  3509. mathpunct: [ "TeXAtom", r.TEXCLASS.PUNCT ],
  3510. mathinner: [ "TeXAtom", r.TEXCLASS.INNER ],
  3511. vcenter: [ "TeXAtom", r.TEXCLASS.VCENTER ],
  3512. mathchoice: [ "Extension", "mathchoice" ],
  3513. buildrel: "BuildRel",
  3514. hbox: [ "HBox", 0 ],
  3515. text: "HBox",
  3516. mbox: [ "HBox", 0 ],
  3517. fbox: "FBox",
  3518. strut: "Strut",
  3519. mathstrut: [ "Macro", "\\vphantom{(}" ],
  3520. phantom: "Phantom",
  3521. vphantom: [ "Phantom", 1, 0 ],
  3522. hphantom: [ "Phantom", 0, 1 ],
  3523. smash: "Smash",
  3524. acute: [ "Accent", "02CA" ],
  3525. grave: [ "Accent", "02CB" ],
  3526. ddot: [ "Accent", "00A8" ],
  3527. tilde: [ "Accent", "02DC" ],
  3528. bar: [ "Accent", "02C9" ],
  3529. breve: [ "Accent", "02D8" ],
  3530. check: [ "Accent", "02C7" ],
  3531. hat: [ "Accent", "02C6" ],
  3532. vec: [ "Accent", "20D7" ],
  3533. dot: [ "Accent", "02D9" ],
  3534. widetilde: [ "Accent", "02DC", 1 ],
  3535. widehat: [ "Accent", "02C6", 1 ],
  3536. matrix: "Matrix",
  3537. array: "Matrix",
  3538. pmatrix: [ "Matrix", "(", ")" ],
  3539. cases: [ "Matrix", "{", "", "left left", null, ".1em" ],
  3540. eqalign: [ "Matrix", null, null, "right left", r.LENGTH.THICKMATHSPACE, ".5em", "D" ],
  3541. displaylines: [ "Matrix", null, null, "center", null, ".5em", "D" ],
  3542. cr: "Cr",
  3543. "\\": "Cr",
  3544. newline: "Cr",
  3545. hline: [ "HLine", "solid" ],
  3546. hdashline: [ "HLine", "dashed" ],
  3547. eqalignno: [ "Matrix", null, null, "right left right", r.LENGTH.THICKMATHSPACE + " 3em", ".5em", "D" ],
  3548. leqalignno: [ "Matrix", null, null, "right left right", r.LENGTH.THICKMATHSPACE + " 3em", ".5em", "D" ],
  3549. bmod: [ "Macro", "\\mathbin{\\rm mod}" ],
  3550. pmod: [ "Macro", "\\pod{{\\rm mod}\\kern 6mu #1}", 1 ],
  3551. mod: [ "Macro", "\\mathchoice{\\kern18mu}{\\kern12mu}{\\kern12mu}{\\kern12mu}{\\rm mod}\\,\\,#1", 1 ],
  3552. pod: [ "Macro", "\\mathchoice{\\kern18mu}{\\kern8mu}{\\kern8mu}{\\kern8mu}(#1)", 1 ],
  3553. iff: [ "Macro", "\\;\\Longleftrightarrow\\;" ],
  3554. skew: [ "Macro", "{{#2{#3\\mkern#1mu}\\mkern-#1mu}{}}", 3 ],
  3555. mathcal: [ "Macro", "{\\cal #1}", 1 ],
  3556. mathscr: [ "Macro", "{\\scr #1}", 1 ],
  3557. mathrm: [ "Macro", "{\\rm #1}", 1 ],
  3558. mathbf: [ "Macro", "{\\bf #1}", 1 ],
  3559. mathbb: [ "Macro", "{\\bbFont #1}", 1 ],
  3560. Bbb: [ "Macro", "{\\bbFont #1}", 1 ],
  3561. mathit: [ "Macro", "{\\it #1}", 1 ],
  3562. mathfrak: [ "Macro", "{\\frak #1}", 1 ],
  3563. mathsf: [ "Macro", "{\\sf #1}", 1 ],
  3564. mathtt: [ "Macro", "{\\tt #1}", 1 ],
  3565. textrm: [ "Macro", "\\mathord{\\rm\\text{#1}}", 1 ],
  3566. textit: [ "Macro", "\\mathord{\\it{\\text{#1}}}", 1 ],
  3567. textbf: [ "Macro", "\\mathord{\\bf{\\text{#1}}}", 1 ],
  3568. pmb: [ "Macro", "\\rlap{#1}\\kern1px{#1}", 1 ],
  3569. TeX: [ "Macro", "T\\kern-.14em\\lower.5ex{E}\\kern-.115em X" ],
  3570. LaTeX: [ "Macro", "L\\kern-.325em\\raise.21em{\\scriptstyle{A}}\\kern-.17em\\TeX" ],
  3571. not: [ "Macro", "\\mathrel{\\rlap{\\kern.5em\\notChar}}" ],
  3572. " ": [ "Macro", "\\text{ }" ],
  3573. space: "Tilde",
  3574. begin: "Begin",
  3575. end: "End",
  3576. newcommand: [ "Extension", "newcommand" ],
  3577. renewcommand: [ "Extension", "newcommand" ],
  3578. newenvironment: [ "Extension", "newcommand" ],
  3579. def: [ "Extension", "newcommand" ],
  3580. verb: [ "Extension", "verb" ],
  3581. boldsymbol: [ "Extension", "boldsymbol" ],
  3582. tag: [ "Extension", "AMSmath" ],
  3583. notag: [ "Extension", "AMSmath" ],
  3584. label: [ "Macro", "", 1 ],
  3585. nonumber: [ "Macro", "" ],
  3586. unicode: [ "Extension", "unicode" ],
  3587. color: "Color",
  3588. href: [ "Extension", "HTML" ],
  3589. "class": [ "Extension", "HTML" ],
  3590. style: [ "Extension", "HTML" ],
  3591. cssId: [ "Extension", "HTML" ],
  3592. require: "Require"
  3593. },
  3594. environment: {
  3595. array: [ "Array" ],
  3596. matrix: [ "Array", null, null, null, "c" ],
  3597. pmatrix: [ "Array", null, "(", ")", "c" ],
  3598. bmatrix: [ "Array", null, "[", "]", "c" ],
  3599. Bmatrix: [ "Array", null, "\\{", "\\}", "c" ],
  3600. vmatrix: [ "Array", null, "\\vert", "\\vert", "c" ],
  3601. Vmatrix: [ "Array", null, "\\Vert", "\\Vert", "c" ],
  3602. cases: [ "Array", null, "\\{", ".", "ll", null, ".1em" ],
  3603. eqnarray: [ "Array", null, null, null, "rcl", r.LENGTH.THICKMATHSPACE, ".5em", "D" ],
  3604. "eqnarray*": [ "Array", null, null, null, "rcl", r.LENGTH.THICKMATHSPACE, ".5em", "D" ],
  3605. equation: [ null, "Equation" ],
  3606. "equation*": [ null, "Equation" ],
  3607. align: [ "ExtensionEnv", null, "AMSmath" ],
  3608. "align*": [ "ExtensionEnv", null, "AMSmath" ],
  3609. aligned: [ "ExtensionEnv", null, "AMSmath" ],
  3610. multline: [ "ExtensionEnv", null, "AMSmath" ],
  3611. "multline*": [ "ExtensionEnv", null, "AMSmath" ],
  3612. split: [ "ExtensionEnv", null, "AMSmath" ],
  3613. gather: [ "ExtensionEnv", null, "AMSmath" ],
  3614. "gather*": [ "ExtensionEnv", null, "AMSmath" ],
  3615. gathered: [ "ExtensionEnv", null, "AMSmath" ],
  3616. alignat: [ "ExtensionEnv", null, "AMSmath" ],
  3617. "alignat*": [ "ExtensionEnv", null, "AMSmath" ],
  3618. alignedat: [ "ExtensionEnv", null, "AMSmath" ]
  3619. },
  3620. p_height: 1.2 / .85
  3621. });
  3622. if (this.config.Macros) {
  3623. var e = this.config.Macros;
  3624. for (var i in e) e.hasOwnProperty(i) && (typeof e[i] == "string" ? u.macros[i] = [ "Macro", e[i] ] : u.macros[i] = [ "Macro" ].concat(e[i]));
  3625. }
  3626. }, f = MathJax.Object.Subclass({
  3627. Init: function(t, n) {
  3628. this.string = t, this.i = 0, this.macroCount = 0;
  3629. var r;
  3630. if (n) {
  3631. r = {};
  3632. for (var i in n) n.hasOwnProperty(i) && (r[i] = n[i]);
  3633. }
  3634. this.stack = e.Stack(r), this.Parse(), this.Push(o.stop());
  3635. },
  3636. Parse: function() {
  3637. var e;
  3638. while (this.i < this.string.length) e = this.string.charAt(this.i++), u.special[e] ? this[u.special[e]](e) : u.letter.test(e) ? this.Variable(e) : u.digit.test(e) ? this.Number(e) : this.Other(e);
  3639. },
  3640. Push: function() {
  3641. this.stack.Push.apply(this.stack, arguments);
  3642. },
  3643. mml: function() {
  3644. return this.stack.Top().type !== "mml" ? null : this.stack.Top().data[0];
  3645. },
  3646. mmlToken: function(e) {
  3647. return e;
  3648. },
  3649. ControlSequence: function(e) {
  3650. var t = this.GetCS(), i, s;
  3651. if (u.macros[t]) {
  3652. var o = u.macros[t];
  3653. o instanceof Array || (o = [ o ]);
  3654. var a = o[0];
  3655. a instanceof Function || (a = this[a]), a.apply(this, [ "\\" + t ].concat(o.slice(1)));
  3656. } else if (u.mathchar0mi[t]) i = u.mathchar0mi[t], s = {
  3657. mathvariant: r.VARIANT.ITALIC
  3658. }, i instanceof Array && (s = i[1], i = i[0]), this.Push(this.mmlToken(r.mi(r.entity("#x" + i)).With(s))); else if (u.mathchar0mo[t]) i = u.mathchar0mo[t], s = {
  3659. stretchy: n
  3660. }, i instanceof Array && (s = i[1], s.stretchy = n, i = i[0]), this.Push(this.mmlToken(r.mo(r.entity("#x" + i)).With(s))); else if (u.mathchar7[t]) i = u.mathchar7[t], s = {
  3661. mathvariant: r.VARIANT.NORMAL
  3662. }, i instanceof Array && (s = i[1], i = i[0]), this.stack.env.font && (s.mathvariant = this.stack.env.font), this.Push(this.mmlToken(r.mi(r.entity("#x" + i)).With(s))); else if (u.delimiter["\\" + t] != null) {
  3663. var f = u.delimiter["\\" + t];
  3664. s = {}, f instanceof Array && (s = f[1], f = f[0]), f.length === 4 ? f = r.entity("#x" + f) : f = r.chars(f), this.Push(this.mmlToken(r.mo(f).With({
  3665. fence: n,
  3666. stretchy: n
  3667. }).With(s)));
  3668. } else this.csUndefined("\\" + t);
  3669. },
  3670. csUndefined: function(t) {
  3671. e.Error("Undefined control sequence " + t);
  3672. },
  3673. Variable: function(e) {
  3674. var t = {};
  3675. this.stack.env.font && (t.mathvariant = this.stack.env.font), this.Push(this.mmlToken(r.mi(r.chars(e)).With(t)));
  3676. },
  3677. Number: function(e) {
  3678. var t, n = this.string.slice(this.i - 1).match(u.number);
  3679. n ? (t = r.mn(n[0].replace(/[{}]/g, "")), this.i += n[0].length - 1) : t = r.mo(r.chars(e)), this.stack.env.font && (t.mathvariant = this.stack.env.font), this.Push(this.mmlToken(t));
  3680. },
  3681. Open: function(e) {
  3682. this.Push(o.open());
  3683. },
  3684. Close: function(e) {
  3685. this.Push(o.close());
  3686. },
  3687. Tilde: function(e) {
  3688. this.Push(r.mtext(r.chars(i)));
  3689. },
  3690. Space: function(e) {},
  3691. Superscript: function(n) {
  3692. var i, s = this.stack.Prev();
  3693. s || (s = r.mi("")), s.isEmbellishedWrapper && (s = s.data[0].data[0]);
  3694. if (s.type === "msubsup") s.data[s.sup] && (s.data[s.sup].isPrime || e.Error("Double exponent: use braces to clarify"), s = r.msubsup(s, null, null)), i = s.sup; else if (s.movesupsub) {
  3695. if (s.type !== "munderover" || s.data[s.over]) s = r.munderover(s, null, null).With({
  3696. movesupsub: t
  3697. });
  3698. i = s.over;
  3699. } else s = r.msubsup(s, null, null), i = s.sup;
  3700. this.Push(o.subsup(s).With({
  3701. position: i
  3702. }));
  3703. },
  3704. Subscript: function(n) {
  3705. var i, s = this.stack.Prev();
  3706. s || (s = r.mi("")), s.isEmbellishedWrapper && (s = s.data[0].data[0]);
  3707. if (s.type === "msubsup") s.data[s.sub] && e.Error("Double subscripts: use braces to clarify"), i = s.sub; else if (s.movesupsub) {
  3708. if (s.type !== "munderover" || s.data[s.under]) s = r.munderover(s, null, null).With({
  3709. movesupsub: t
  3710. });
  3711. i = s.under;
  3712. } else s = r.msubsup(s, null, null), i = s.sub;
  3713. this.Push(o.subsup(s).With({
  3714. position: i
  3715. }));
  3716. },
  3717. PRIME: String.fromCharCode(8242),
  3718. SMARTQUOTE: String.fromCharCode(8217),
  3719. Prime: function(n) {
  3720. var i = this.stack.Prev();
  3721. i || (i = r.mi()), i.type === "msubsup" && i.data[i.sup] && e.Error("Prime causes double exponent: use braces to clarify");
  3722. var s = "";
  3723. this.i--;
  3724. do s += this.PRIME, this.i++, n = this.GetNext(); while (n === "'" || n === this.SMARTQUOTE);
  3725. s = this.mmlToken(r.mo(r.chars(s)).With({
  3726. isPrime: t,
  3727. variantForm: e.isSTIX
  3728. })), this.Push(r.msubsup(i, null, s));
  3729. },
  3730. Comment: function(e) {
  3731. while (this.i < this.string.length && this.string.charAt(this.i) != "\n") this.i++;
  3732. },
  3733. Hash: function(t) {
  3734. e.Error("You can't use 'macro parameter character #' in math mode");
  3735. },
  3736. Other: function(e) {
  3737. var t = {
  3738. stretchy: !1
  3739. }, n;
  3740. this.stack.env.font && (t.mathvariant = this.stack.env.font), u.remap[e] ? (e = u.remap[e], e instanceof Array && (t = e[1], e = e[0]), n = r.mo(r.entity("#x" + e))) : n = r.mo(e), n.autoDefault("texClass", true) == "" && (n = r.TeXAtom(n)), this.Push(this.mmlToken(n.With(t)));
  3741. },
  3742. SetFont: function(e, t) {
  3743. this.stack.env.font = t;
  3744. },
  3745. SetStyle: function(e, t, n, r) {
  3746. this.stack.env.style = t, this.stack.env.level = r, this.Push(o.style().With({
  3747. styles: {
  3748. displaystyle: n,
  3749. scriptlevel: r
  3750. }
  3751. }));
  3752. },
  3753. SetSize: function(e, t) {
  3754. this.stack.env.size = t, this.Push(o.style().With({
  3755. styles: {
  3756. mathsize: t + "em"
  3757. }
  3758. }));
  3759. },
  3760. Color: function(e) {
  3761. var t = this.GetArgument(e), n = this.stack.env.color;
  3762. this.stack.env.color = t;
  3763. var i = this.ParseArg(e);
  3764. n ? this.stack.env.color : delete this.stack.env.color, this.Push(r.mstyle(i).With({
  3765. mathcolor: t
  3766. }));
  3767. },
  3768. Spacer: function(e, t) {
  3769. this.Push(r.mspace().With({
  3770. width: t,
  3771. mathsize: r.SIZE.NORMAL,
  3772. scriptlevel: 1
  3773. }));
  3774. },
  3775. LeftRight: function(e) {
  3776. this.Push(o[e.substr(1)]().With({
  3777. delim: this.GetDelimiter(e)
  3778. }));
  3779. },
  3780. NamedOp: function(e, i, s) {
  3781. var o = i != null && i === 0 ? n : t;
  3782. s || (s = e.substr(1)), i = i || i == null ? t : n, s = s.replace(/&thinsp;/, String.fromCharCode(8198));
  3783. var u = r.mo(s).With({
  3784. movablelimits: i,
  3785. movesupsub: o,
  3786. form: r.FORM.PREFIX,
  3787. texClass: r.TEXCLASS.OP
  3788. });
  3789. u.useMMLspacing &= ~u.SPACE_ATTR.form, this.Push(this.mmlToken(u));
  3790. },
  3791. Limits: function(i, s) {
  3792. var o = this.stack.Prev("nopop");
  3793. o.texClass !== r.TEXCLASS.OP && e.Error(i + " is allowed only on operators"), o.movesupsub = s ? t : n, o.movablelimits = n;
  3794. },
  3795. Over: function(e, t, n) {
  3796. var r = o.over().With({
  3797. name: e
  3798. });
  3799. t || n ? (r.open = t, r.close = n) : e.match(/withdelims$/) && (r.open = this.GetDelimiter(e), r.close = this.GetDelimiter(e));
  3800. if (e.match(/^\\above/)) r.thickness = this.GetDimen(e); else if (e.match(/^\\atop/) || t || n) r.thickness = 0;
  3801. this.Push(r);
  3802. },
  3803. Frac: function(e) {
  3804. var t = this.ParseArg(e), n = this.ParseArg(e);
  3805. this.Push(r.mfrac(t, n));
  3806. },
  3807. Sqrt: function(e) {
  3808. var t = this.GetBrackets(e), n = this.ParseArg(e);
  3809. t == "" ? n = r.msqrt.apply(r, n.array()) : n = r.mroot(n, this.parseRoot(t)), this.Push(n);
  3810. },
  3811. Root: function(e) {
  3812. var t = this.GetUpTo(e, "\\of"), n = this.ParseArg(e);
  3813. this.Push(r.mroot(n, this.parseRoot(t)));
  3814. },
  3815. parseRoot: function(t) {
  3816. var n = this.stack.env, i = n.inRoot;
  3817. n.inRoot = !0;
  3818. var s = e.Parse(t, n);
  3819. t = s.mml();
  3820. var o = s.stack.global;
  3821. if (o.leftRoot || o.upRoot) t = r.mpadded(t), o.leftRoot && (t.width = o.leftRoot), o.upRoot && (t.voffset = o.upRoot, t.height = o.upRoot);
  3822. return n.inRoot = i, t;
  3823. },
  3824. MoveRoot: function(t, n) {
  3825. this.stack.env.inRoot || e.Error(t + " can appear only within a root"), this.stack.global[n] && e.Error("Multiple use of " + t);
  3826. var r = this.GetArgument(t);
  3827. r.match(/-?[0-9]+/) || e.Error("The argument to " + t + " must be an integer"), r = r / 15 + "em", r.substr(0, 1) !== "-" && (r = "+" + r), this.stack.global[n] = r;
  3828. },
  3829. Accent: function(e, i, s) {
  3830. var o = this.ParseArg(e), u = {
  3831. accent: !0
  3832. };
  3833. this.stack.env.font && (u.mathvariant = this.stack.env.font);
  3834. var a = this.mmlToken(r.mo(r.entity("#x" + i)).With(u));
  3835. a.stretchy = s ? t : n, this.Push(r.munderover(o, null, a).With({
  3836. accent: t
  3837. }));
  3838. },
  3839. UnderOver: function(e, n, i) {
  3840. var s = {
  3841. o: "over",
  3842. u: "under"
  3843. }[e.charAt(1)], o = this.ParseArg(e);
  3844. o.Get("movablelimits") && (o.movablelimits = !1);
  3845. var u = r.munderover(o, null, null);
  3846. i && (u.movesupsub = t), u.data[u[s]] = this.mmlToken(r.mo(r.entity("#x" + n)).With({
  3847. stretchy: t,
  3848. accent: s == "under"
  3849. })), this.Push(u);
  3850. },
  3851. Overset: function(e) {
  3852. var t = this.ParseArg(e), n = this.ParseArg(e);
  3853. this.Push(r.munderover(n, null, t));
  3854. },
  3855. Underset: function(e) {
  3856. var t = this.ParseArg(e), n = this.ParseArg(e);
  3857. this.Push(r.munderover(n, t, null));
  3858. },
  3859. TeXAtom: function(n, i) {
  3860. var s = {
  3861. texClass: i
  3862. }, o;
  3863. if (i == r.TEXCLASS.OP) {
  3864. s.movesupsub = s.movablelimits = t;
  3865. var u = this.GetArgument(n), a = u.match(/^\s*\\rm\s+([a-zA-Z0-9 ]+)$/);
  3866. a ? (o = this.mmlToken(r.mo(a[1]).With({
  3867. movablelimits: t,
  3868. movesupsub: t,
  3869. mathvariant: r.VARIANT.NORMAL,
  3870. form: r.FORM.PREFIX,
  3871. texClass: r.TEXCLASS.OP
  3872. })), o.useMMLspacing &= ~o.SPACE_ATTR.form) : o = r.TeXAtom(e.Parse(u, this.stack.env).mml()).With(s);
  3873. } else o = r.TeXAtom(this.ParseArg(n)).With(s);
  3874. this.Push(o);
  3875. },
  3876. Strut: function(e) {
  3877. this.Push(r.mpadded(r.mrow()).With({
  3878. height: "8.6pt",
  3879. depth: "3pt",
  3880. width: 0
  3881. }));
  3882. },
  3883. Phantom: function(e, t, n) {
  3884. var i = r.mphantom(this.ParseArg(e));
  3885. if (t || n) i = r.mpadded(i), n && (i.height = i.depth = 0), t && (i.width = 0);
  3886. this.Push(i);
  3887. },
  3888. Smash: function(e) {
  3889. var t = this.trimSpaces(this.GetBrackets(e)), n = r.mpadded(this.ParseArg(e));
  3890. switch (t) {
  3891. case "b":
  3892. n.depth = 0;
  3893. break;
  3894. case "t":
  3895. n.height = 0;
  3896. break;
  3897. default:
  3898. n.height = n.depth = 0;
  3899. }
  3900. this.Push(n);
  3901. },
  3902. Lap: function(e) {
  3903. var t = r.mpadded(this.ParseArg(e)).With({
  3904. width: 0
  3905. });
  3906. e === "\\llap" && (t.lspace = "-1 width"), this.Push(t);
  3907. },
  3908. RaiseLower: function(e) {
  3909. var t = this.GetDimen(e), n = o.position().With({
  3910. name: e,
  3911. move: "vertical"
  3912. });
  3913. t.charAt(0) === "-" && (t = t.slice(1), e = {
  3914. raise: "\\lower",
  3915. lower: "\\raise"
  3916. }[e.substr(1)]), e === "\\lower" ? (n.dh = "-" + t, n.dd = "+" + t) : (n.dh = "+" + t, n.dd = "-" + t), this.Push(n);
  3917. },
  3918. MoveLeftRight: function(e) {
  3919. var t = this.GetDimen(e), n = t.charAt(0) === "-" ? t.slice(1) : "-" + t;
  3920. if (e === "\\moveleft") {
  3921. var i = t;
  3922. t = n, n = i;
  3923. }
  3924. this.Push(o.position().With({
  3925. name: e,
  3926. move: "horizontal",
  3927. left: r.mspace().With({
  3928. width: t,
  3929. mathsize: r.SIZE.NORMAL,
  3930. scriptlevel: 1
  3931. }),
  3932. right: r.mspace().With({
  3933. width: n,
  3934. mathsize: r.SIZE.NORMAL,
  3935. scriptlevel: 1
  3936. })
  3937. }));
  3938. },
  3939. Hskip: function(e) {
  3940. this.Push(r.mspace().With({
  3941. width: this.GetDimen(e),
  3942. mathsize: r.SIZE.NORMAL,
  3943. scriptlevel: 0
  3944. }));
  3945. },
  3946. Rule: function(e, t) {
  3947. var n = this.GetDimen(e), i = this.GetDimen(e), s = this.GetDimen(e), o, u = {
  3948. width: n,
  3949. height: i,
  3950. depth: s
  3951. };
  3952. t !== "blank" ? (o = r.mpadded(r.mrow()).With(u), parseFloat(n) && parseFloat(i) + parseFloat(s) && (o = r.mstyle(o).With({
  3953. mathbackground: this.stack.env.color || "black"
  3954. }))) : o = r.mspace().With(u), this.Push(o);
  3955. },
  3956. MakeBig: function(e, n, i) {
  3957. i *= u.p_height, i = String(i).replace(/(\.\d\d\d).+/, "$1") + "em";
  3958. var s = this.GetDelimiter(e);
  3959. this.Push(r.TeXAtom(r.mo(s).With({
  3960. minsize: i,
  3961. maxsize: i,
  3962. scriptlevel: 0,
  3963. fence: t,
  3964. stretchy: t,
  3965. symmetric: t
  3966. })).With({
  3967. texClass: n
  3968. }));
  3969. },
  3970. BuildRel: function(e) {
  3971. var t = this.ParseUpTo(e, "\\over"), n = this.ParseArg(e);
  3972. this.Push(r.TeXAtom(r.munderover(n, null, t)).With({
  3973. mclass: r.TEXCLASS.REL
  3974. }));
  3975. },
  3976. HBox: function(e, t) {
  3977. this.Push.apply(this, this.InternalMath(this.GetArgument(e), t));
  3978. },
  3979. FBox: function(e) {
  3980. this.Push(r.menclose.apply(r, this.InternalMath(this.GetArgument(e))).With({
  3981. notation: "box"
  3982. }));
  3983. },
  3984. Require: function(e) {
  3985. var t = this.GetArgument(e);
  3986. this.Extension(null, t);
  3987. },
  3988. Extension: function(t, n, r) {
  3989. t && !typeof t === "string" && (t = t.name), n = e.extensionDir + "/" + n, n.match(/\.js$/) || (n += ".js"), MathJax.Ajax.loaded[MathJax.Ajax.fileURL(n)] || (t != null && delete u[r || "macros"][t.replace(/^\\/, "")], MathJax.Hub.RestartAfter(MathJax.Ajax.Require(n)));
  3990. },
  3991. Macro: function(t, n, r) {
  3992. if (r) {
  3993. var i = [];
  3994. for (var s = 0; s < r; s++) i.push(this.GetArgument(t));
  3995. n = this.SubstituteArgs(i, n);
  3996. }
  3997. this.string = this.AddArgs(n, this.string.slice(this.i)), this.i = 0, ++this.macroCount > e.config.MAXMACROS && e.Error("MathJax maximum macro substitution count exceeded; is there a recursive macro call?");
  3998. },
  3999. Matrix: function(n, r, i, s, u, a, f) {
  4000. var l = this.GetNext();
  4001. l === "" && e.Error("Missing argument for " + n), l === "{" ? this.i++ : (this.string = l + "}" + this.string.slice(this.i + 1), this.i = 0);
  4002. var h = o.array().With({
  4003. requireClose: t,
  4004. arraydef: {
  4005. rowspacing: a || "4pt",
  4006. columnspacing: u || "1em"
  4007. }
  4008. });
  4009. if (r || i) h.open = r, h.close = i;
  4010. f === "D" && (h.arraydef.displaystyle = t), s != null && (h.arraydef.columnalign = s), this.Push(h);
  4011. },
  4012. Entry: function(e) {
  4013. this.Push(o.cell().With({
  4014. isEntry: t,
  4015. name: e
  4016. }));
  4017. },
  4018. Cr: function(e) {
  4019. this.Push(o.cell().With({
  4020. isCR: t,
  4021. name: e
  4022. }));
  4023. },
  4024. HLine: function(t, n) {
  4025. n == null && (n = "solid");
  4026. var r = this.stack.Top();
  4027. (r.type !== "array" || r.data.length) && e.Error("Misplaced " + t);
  4028. if (r.table.length == 0) r.arraydef.frame = n; else {
  4029. var i = r.arraydef.rowlines ? r.arraydef.rowlines.split(/ /) : [];
  4030. while (i.length < r.table.length) i.push("none");
  4031. i[r.table.length - 1] = n, r.arraydef.rowlines = i.join(" ");
  4032. }
  4033. },
  4034. Begin: function(t) {
  4035. var n = this.GetArgument(t);
  4036. n.match(/[^a-z*]/i) && e.Error('Invalid environment name "' + n + '"'), u.environment[n] || e.Error('Unknown environment "' + n + '"'), ++this.macroCount > e.config.MAXMACROS && e.Error("MathJax maximum substitution count exceeded; is there a recursive latex environment?");
  4037. var r = u.environment[n];
  4038. r instanceof Array || (r = [ r ]);
  4039. var i = o.begin().With({
  4040. name: n,
  4041. end: r[1],
  4042. parse: this
  4043. });
  4044. r[0] && this[r[0]] && (i = this[r[0]].apply(this, [ i ].concat(r.slice(2)))), this.Push(i);
  4045. },
  4046. End: function(e) {
  4047. this.Push(o.end().With({
  4048. name: this.GetArgument(e)
  4049. }));
  4050. },
  4051. Equation: function(e, t) {
  4052. return t;
  4053. },
  4054. ExtensionEnv: function(e, t) {
  4055. this.Extension(e.name, t, "environment");
  4056. },
  4057. Array: function(e, r, i, s, u, a, f, l) {
  4058. s || (s = this.GetArgument("\\begin{" + e.name + "}"));
  4059. var h = ("c" + s).replace(/[^clr|:]/g, "").replace(/[^|:]([|:])+/g, "$1");
  4060. s = s.replace(/[^clr]/g, "").split("").join(" "), s = s.replace(/l/g, "left").replace(/r/g, "right").replace(/c/g, "center");
  4061. var p = o.array().With({
  4062. arraydef: {
  4063. columnalign: s,
  4064. columnspacing: u || "1em",
  4065. rowspacing: a || "4pt"
  4066. }
  4067. });
  4068. if (h.match(/[|:]/)) {
  4069. var d = (h.charAt(0) + h.charAt(h.length - 1)).replace(/[^|:]/g, "");
  4070. d !== "" && (p.arraydef.frame = {
  4071. "|": "solid",
  4072. ":": "dashed"
  4073. }[d.charAt(0)], p.arraydef.framespacing = ".5em .5ex"), h = h.substr(1, h.length - 2), p.arraydef.columnlines = h.split("").join(" ").replace(/[^|: ]/g, "none").replace(/\|/g, "solid").replace(/:/g, "dashed");
  4074. }
  4075. return r && (p.open = this.convertDelimiter(r)), i && (p.close = this.convertDelimiter(i)), f === "D" && (p.arraydef.displaystyle = t), f === "S" && (p.arraydef.scriptlevel = 1), l && (p.arraydef.useHeight = n), this.Push(e), p;
  4076. },
  4077. convertDelimiter: function(e) {
  4078. return e && (e = u.delimiter[e]), e == null ? null : (e instanceof Array && (e = e[0]), e.length === 4 && (e = String.fromCharCode(parseInt(e, 16))), e);
  4079. },
  4080. trimSpaces: function(e) {
  4081. return typeof e != "string" ? e : e.replace(/^\s+|\s+$/g, "");
  4082. },
  4083. nextIsSpace: function() {
  4084. return this.string.charAt(this.i).match(/[ \n\r\t]/);
  4085. },
  4086. GetNext: function() {
  4087. while (this.nextIsSpace()) this.i++;
  4088. return this.string.charAt(this.i);
  4089. },
  4090. GetCS: function() {
  4091. var e = this.string.slice(this.i).match(/^([a-z]+|.) ?/i);
  4092. return e ? (this.i += e[1].length, e[1]) : (this.i++, " ");
  4093. },
  4094. GetArgument: function(t, n) {
  4095. switch (this.GetNext()) {
  4096. case "":
  4097. return n || e.Error("Missing argument for " + t), null;
  4098. case "}":
  4099. return n || e.Error("Extra close brace or missing open brace"), null;
  4100. case "\\":
  4101. return this.i++, "\\" + this.GetCS();
  4102. case "{":
  4103. var r = ++this.i, i = 1;
  4104. while (this.i < this.string.length) switch (this.string.charAt(this.i++)) {
  4105. case "\\":
  4106. this.i++;
  4107. break;
  4108. case "{":
  4109. i++;
  4110. break;
  4111. case "}":
  4112. i == 0 && e.Error("Extra close brace");
  4113. if (--i == 0) return this.string.slice(r, this.i - 1);
  4114. }
  4115. e.Error("Missing close brace");
  4116. }
  4117. return this.string.charAt(this.i++);
  4118. },
  4119. GetBrackets: function(t) {
  4120. if (this.GetNext() != "[") return "";
  4121. var n = ++this.i, r = 0;
  4122. while (this.i < this.string.length) switch (this.string.charAt(this.i++)) {
  4123. case "{":
  4124. r++;
  4125. break;
  4126. case "\\":
  4127. this.i++;
  4128. break;
  4129. case "}":
  4130. r-- <= 0 && e.Error("Extra close brace while looking for ']'");
  4131. break;
  4132. case "]":
  4133. if (r == 0) return this.string.slice(n, this.i - 1);
  4134. }
  4135. e.Error("Couldn't find closing ']' for argument to " + t);
  4136. },
  4137. GetDelimiter: function(t) {
  4138. while (this.nextIsSpace()) this.i++;
  4139. var n = this.string.charAt(this.i);
  4140. if (this.i < this.string.length) {
  4141. this.i++, n == "\\" && (n += this.GetCS(t));
  4142. if (u.delimiter[n] != null) return this.convertDelimiter(n);
  4143. }
  4144. e.Error("Missing or unrecognized delimiter for " + t);
  4145. },
  4146. GetDimen: function(t) {
  4147. var n;
  4148. this.nextIsSpace() && this.i++;
  4149. if (this.string.charAt(this.i) == "{") {
  4150. n = this.GetArgument(t);
  4151. if (n.match(/^\s*([-+]?(\.\d+|\d+(\.\d*)?))\s*(pt|em|ex|mu|px|mm|cm|in|pc)\s*$/)) return n.replace(/ /g, "");
  4152. } else {
  4153. n = this.string.slice(this.i);
  4154. var r = n.match(/^\s*(([-+]?(\.\d+|\d+(\.\d*)?))\s*(pt|em|ex|mu|px|mm|cm|in|pc)) ?/);
  4155. if (r) return this.i += r[0].length, r[1].replace(/ /g, "");
  4156. }
  4157. e.Error("Missing dimension or its units for " + t);
  4158. },
  4159. GetUpTo: function(t, n) {
  4160. while (this.nextIsSpace()) this.i++;
  4161. var r = this.i, i, s, o = 0;
  4162. while (this.i < this.string.length) {
  4163. i = this.i, s = this.string.charAt(this.i++);
  4164. switch (s) {
  4165. case "\\":
  4166. s += this.GetCS();
  4167. break;
  4168. case "{":
  4169. o++;
  4170. break;
  4171. case "}":
  4172. o == 0 && e.Error("Extra close brace while looking for " + n), o--;
  4173. }
  4174. if (o == 0 && s == n) return this.string.slice(r, i);
  4175. }
  4176. e.Error("Couldn't find " + n + " for " + t);
  4177. },
  4178. ParseArg: function(t) {
  4179. return e.Parse(this.GetArgument(t), this.stack.env).mml();
  4180. },
  4181. ParseUpTo: function(t, n) {
  4182. return e.Parse(this.GetUpTo(t, n), this.stack.env).mml();
  4183. },
  4184. InternalMath: function(t, i) {
  4185. var s = {
  4186. displaystyle: n
  4187. };
  4188. i != null && (s.scriptlevel = i), this.stack.env.font && (s.mathvariant = this.stack.env.font);
  4189. if (!t.match(/\$|\\\(/)) return [ this.InternalText(t, s) ];
  4190. var o = 0, u = 0, a, f = "", l = [];
  4191. while (o < t.length) a = t.charAt(o++), a === "$" ? f === "$" ? (l.push(r.TeXAtom(e.Parse(t.slice(u, o - 1)).mml().With(s))), f = "", u = o) : f === "" && (u < o - 1 && l.push(this.InternalText(t.slice(u, o - 1), s)), f = "$", u = o) : a === "\\" && (a = t.charAt(o++), a === "(" && f === "" ? (u < o - 2 && l.push(this.InternalText(t.slice(u, o - 2), s)), f = ")", u = o) : a === ")" && f === ")" && (l.push(r.TeXAtom(e.Parse(t.slice(u, o - 2)).mml().With(s))), f = "", u = o));
  4192. return f !== "" && e.Error("Math not terminated in text box"), u < t.length && l.push(this.InternalText(t.slice(u), s)), l;
  4193. },
  4194. InternalText: function(e, t) {
  4195. return e = e.replace(/^\s+/, i).replace(/\s+$/, i), r.mtext(r.chars(e)).With(t);
  4196. },
  4197. SubstituteArgs: function(t, n) {
  4198. var r = "", i = "", s, o = 0;
  4199. while (o < n.length) s = n.charAt(o++), s === "\\" ? r += s + n.charAt(o++) : s === "#" ? (s = n.charAt(o++), s === "#" ? r += s : ((!s.match(/[1-9]/) || s > t.length) && e.Error("Illegal macro parameter reference"), i = this.AddArgs(this.AddArgs(i, r), t[s - 1]), r = "")) : r += s;
  4200. return this.AddArgs(i, r);
  4201. },
  4202. AddArgs: function(t, n) {
  4203. return n.match(/^[a-z]/i) && t.match(/(^|[^\\])(\\\\)*\\[a-z]+$/i) && (t += " "), t.length + n.length > e.config.MAXBUFFER && e.Error("MathJax internal buffer size exceeded; is there a recursive macro call?"), t + n;
  4204. }
  4205. });
  4206. e.Augment({
  4207. Stack: s,
  4208. Parse: f,
  4209. Definitions: u,
  4210. Startup: a,
  4211. config: {
  4212. MAXMACROS: 1e4,
  4213. MAXBUFFER: 5120
  4214. },
  4215. Translate: function(t) {
  4216. var n, i = t.innerHTML.replace(/^\s+/, "").replace(/\s+$/, "");
  4217. MathJax.Hub.Browser.isKonqueror && (i = i.replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&amp;/g, "&"));
  4218. var s = t.type.replace(/\n/g, " ").match(/(;|\s|\n)mode\s*=\s*display(;|\s|\n|$)/) != null;
  4219. i = e.prefilterMath(i, s, t);
  4220. try {
  4221. n = e.Parse(i).mml();
  4222. } catch (o) {
  4223. if (!o.texError) throw o;
  4224. n = this.formatError(o, i, s, t);
  4225. }
  4226. return n.inferred ? n = r.apply(MathJax.ElementJax, n.data) : n = r(n), s && (n.root.display = "block"), this.postfilterMath(n, s, t);
  4227. },
  4228. prefilterMath: function(e, t, n) {
  4229. return e.replace(/([_^]\s*\d)([0-9.,])/g, "$1 $2");
  4230. },
  4231. postfilterMath: function(e, t, n) {
  4232. return this.combineRelations(e.root), e;
  4233. },
  4234. formatError: function(e, t, n, i) {
  4235. return r.merror(e.message.replace(/\n.*/, ""));
  4236. },
  4237. Error: function(e) {
  4238. throw MathJax.Hub.Insert(Error(e), {
  4239. texError: t
  4240. });
  4241. },
  4242. Macro: function(e, t, n) {
  4243. u.macros[e] = [ "Macro" ].concat([].slice.call(arguments, 1));
  4244. },
  4245. combineRelations: function(e) {
  4246. for (var t = 0, n = e.data.length; t < n; t++) if (e.data[t]) {
  4247. if (e.isa(r.mrow)) while (t + 1 < n && e.data[t + 1] && e.data[t].isa(r.mo) && e.data[t + 1].isa(r.mo) && e.data[t].Get("texClass") === r.TEXCLASS.REL && e.data[t + 1].Get("texClass") === r.TEXCLASS.REL) e.data[t].Append.apply(e.data[t], e.data[t + 1].data), e.data.splice(t + 1, 1), n--;
  4248. e.data[t].isToken || this.combineRelations(e.data[t]);
  4249. }
  4250. }
  4251. }), e.loadComplete("jax.js");
  4252. }(MathJax.InputJax.TeX), MathJax.OutputJax["HTML-CSS"] = MathJax.OutputJax({
  4253. id: "HTML-CSS",
  4254. version: "1.1.5",
  4255. directory: MathJax.OutputJax.directory + "/HTML-CSS",
  4256. extensionDir: MathJax.OutputJax.extensionDir + "/HTML-CSS",
  4257. autoloadDir: MathJax.OutputJax.directory + "/HTML-CSS/autoload",
  4258. fontDir: MathJax.OutputJax.directory + "/HTML-CSS/fonts",
  4259. webfontDir: MathJax.OutputJax.fontDir + "/HTML-CSS",
  4260. config: {
  4261. scale: 100,
  4262. minScaleAdjust: 50,
  4263. availableFonts: [ "STIX", "TeX" ],
  4264. preferredFont: "TeX",
  4265. webFont: "TeX",
  4266. imageFont: "TeX",
  4267. undefinedFamily: "STIXGeneral,'Arial Unicode MS',serif",
  4268. showMathMenu: !0,
  4269. styles: {
  4270. ".MathJax_Display": {
  4271. "text-align": "center",
  4272. margin: "1em 0em"
  4273. },
  4274. ".MathJax .merror": {
  4275. "background-color": "#FFFF88",
  4276. color: "#CC0000",
  4277. border: "1px solid #CC0000",
  4278. padding: "1px 3px",
  4279. "font-family": "serif",
  4280. "font-style": "normal",
  4281. "font-size": "90%"
  4282. },
  4283. ".MathJax_Preview": {
  4284. color: "#888888"
  4285. },
  4286. "#MathJax_Tooltip": {
  4287. "background-color": "InfoBackground",
  4288. color: "InfoText",
  4289. border: "1px solid black",
  4290. "box-shadow": "2px 2px 5px #AAAAAA",
  4291. "-webkit-box-shadow": "2px 2px 5px #AAAAAA",
  4292. "-moz-box-shadow": "2px 2px 5px #AAAAAA",
  4293. "-khtml-box-shadow": "2px 2px 5px #AAAAAA",
  4294. filter: "progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')",
  4295. padding: "3px 4px"
  4296. }
  4297. }
  4298. }
  4299. }), MathJax.Hub.Browser.isMSIE && document.documentMode >= 9 && delete MathJax.OutputJax["HTML-CSS"].config.styles["#MathJax_Tooltip"].filter, MathJax.Hub.config.delayJaxRegistration || MathJax.OutputJax["HTML-CSS"].Register("jax/mml"), MathJax.Hub.Register.StartupHook("End Config", [ function(e, t) {
  4300. var n = e.Insert({
  4301. minBrowserVersion: {
  4302. Firefox: 3,
  4303. Opera: 9.52,
  4304. MSIE: 6,
  4305. Chrome: .3,
  4306. Safari: 2,
  4307. Konqueror: 4
  4308. },
  4309. inlineMathDelimiters: [ "$", "$" ],
  4310. displayMathDelimiters: [ "$$", "$$" ],
  4311. multilineDisplay: !0,
  4312. minBrowserTranslate: function(t) {
  4313. var r = e.getJaxFor(t), i = [ "[Math]" ], s, o = document.createElement("span", {
  4314. className: "MathJax_Preview"
  4315. });
  4316. r.inputJax.id === "TeX" && (r.root.Get("displaystyle") ? (s = n.displayMathDelimiters, i = [ s[0] + r.originalText + s[1] ], n.multilineDisplay && (i = i[0].split(/\n/))) : (s = n.inlineMathDelimiters, i = [ s[0] + r.originalText.replace(/^\s+/, "").replace(/\s+$/, "") + s[1] ]));
  4317. for (var u = 0, f = i.length; u < f; u++) o.appendChild(document.createTextNode(i[u])), u < f - 1 && o.appendChild(document.createElement("br"));
  4318. t.parentNode.insertBefore(o, t);
  4319. }
  4320. }, e.config["HTML-CSS"] || {});
  4321. e.Browser.version !== "0.0" && !e.Browser.versionAtLeast(n.minBrowserVersion[e.Browser] || 0) && (t.Translate = n.minBrowserTranslate, e.Config({
  4322. showProcessingMessages: !1
  4323. }), MathJax.Message.Set("Your browser does not support MathJax", null, 4e3), e.Startup.signal.Post("MathJax not supported"));
  4324. }, MathJax.Hub, MathJax.OutputJax["HTML-CSS"] ]), MathJax.OutputJax["HTML-CSS"].loadComplete("config.js"), function(e, t, n) {
  4325. var r, i = MathJax.Object.Subclass({
  4326. timeout: 5e3,
  4327. FontInfo: {
  4328. STIX: {
  4329. family: "STIXSizeOneSym",
  4330. testString: "() {} []"
  4331. },
  4332. TeX: {
  4333. family: "MathJax_Size1",
  4334. testString: "() {} []"
  4335. }
  4336. },
  4337. comparisonFont: [ "sans-serif", "monospace", "script", "Times", "Courier", "Arial", "Helvetica" ],
  4338. testSize: [ "40px", "50px", "60px", "30px", "20px" ],
  4339. Init: function() {
  4340. this.div = MathJax.HTML.addElement(document.body, "div", {
  4341. style: {
  4342. position: "absolute",
  4343. visibility: "hidden",
  4344. top: 0,
  4345. left: 0,
  4346. width: "auto",
  4347. padding: 0,
  4348. border: 0,
  4349. margin: 0,
  4350. textAlign: "left",
  4351. textIndent: 0,
  4352. textTransform: "none",
  4353. lineHeight: "normal",
  4354. letterSpacing: "normal",
  4355. wordSpacing: "normal",
  4356. fontSize: this.testSize[0],
  4357. fontWeight: "normal",
  4358. fontStyle: "normal"
  4359. }
  4360. }, [ "" ]), this.text = this.div.firstChild;
  4361. },
  4362. findFont: function(e, t) {
  4363. if (t && this.testCollection(t)) return t;
  4364. for (var n = 0, r = e.length; n < r; n++) {
  4365. if (e[n] === t) continue;
  4366. if (this.testCollection(e[n])) return e[n];
  4367. }
  4368. return null;
  4369. },
  4370. testCollection: function(e) {
  4371. return this.testFont(this.FontInfo[e]);
  4372. },
  4373. testFont: function(e) {
  4374. e.isWebFont && n.FontFaceBug ? this.div.style.fontWeight = this.div.style.fontStyle = "normal" : (this.div.style.fontWeight = e.weight || "normal", this.div.style.fontStyle = e.style || "normal");
  4375. var t = this.getComparisonWidths(e.testString, e.noStyleChar);
  4376. if (t) {
  4377. this.div.style.fontFamily = "'" + e.family + "'," + this.comparisonFont[0];
  4378. if (this.div.offsetWidth == t[0]) {
  4379. this.div.style.fontFamily = "'" + e.family + "'," + this.comparisonFont[t[2]];
  4380. if (this.div.offsetWidth == t[1]) return !1;
  4381. }
  4382. if (this.div.offsetWidth != t[3]) {
  4383. if (e.noStyleChar || !n.FONTDATA || !n.FONTDATA.hasStyleChar) return !0;
  4384. for (var r = 0, i = this.testSize.length; r < i; r++) if (this.testStyleChar(e, this.testSize[r])) return !0;
  4385. }
  4386. }
  4387. return !1;
  4388. },
  4389. styleChar: String.fromCharCode(61437),
  4390. versionChar: String.fromCharCode(61438),
  4391. compChar: String.fromCharCode(61439),
  4392. testStyleChar: function(e, t) {
  4393. var r = 3 + (e.weight ? 2 : 0) + (e.style ? 4 : 0), i = "", s = 0, o = this.div.style.fontSize;
  4394. this.div.style.fontSize = t, n.msieItalicWidthBug && e.style === "italic" && (this.text.nodeValue = i = this.compChar, s = this.div.offsetWidth), n.safariTextNodeBug ? this.div.innerHTML = this.compChar + i : this.text.nodeValue = this.compChar + i;
  4395. var u = this.div.offsetWidth - s;
  4396. n.safariTextNodeBug ? this.div.innerHTML = this.styleChar + i : this.text.nodeValue = this.styleChar + i;
  4397. var a = Math.floor((this.div.offsetWidth - s) / u + .5);
  4398. return a === r && (n.safariTextNodeBug ? this.div.innerHTML = this.versionChar + i : this.text.nodeValue = this.versionChar + i, e.version = Math.floor((this.div.offsetWidth - s) / u + 1.5) / 2), this.div.style.fontSize = o, a === r;
  4399. },
  4400. getComparisonWidths: function(e, t) {
  4401. n.FONTDATA && n.FONTDATA.hasStyleChar && !t && (e += this.styleChar + " " + this.compChar), n.safariTextNodeBug ? this.div.innerHTML = e : this.text.nodeValue = e, this.div.style.fontFamily = this.comparisonFont[0];
  4402. var r = this.div.offsetWidth, i = -1;
  4403. n.safariWebFontSerif && (this.div.style.fontFamily = n.safariWebFontSerif[0], i = this.div.offsetWidth);
  4404. for (var s = 1, o = this.comparisonFont.length; s < o; s++) {
  4405. this.div.style.fontFamily = this.comparisonFont[s];
  4406. if (this.div.offsetWidth != r) return [ r, this.div.offsetWidth, s, i ];
  4407. }
  4408. return null;
  4409. },
  4410. loadWebFont: function(r) {
  4411. t.Startup.signal.Post("HTML-CSS Jax - Web-Font " + n.fontInUse + "/" + r.directory);
  4412. var i = MathJax.Message.File("Web-Font " + n.fontInUse + "/" + r.directory), s = MathJax.Callback({}), o = MathJax.Callback([ "loadComplete", this, r, i, s ]);
  4413. return e.timer.start(e, [ this.checkWebFont, r, o ], 1, this.timeout), s;
  4414. },
  4415. loadComplete: function(r, i, s, o) {
  4416. MathJax.Message.Clear(i);
  4417. if (o === e.STATUS.OK) {
  4418. s();
  4419. return;
  4420. }
  4421. this.loadError(r);
  4422. if (t.Browser.isFirefox && n.allowWebFonts) {
  4423. var u = document.location.protocol + "//" + document.location.hostname;
  4424. document.location.port != "" && (u += ":" + document.location.port), u += "/", e.fileURL(n.webfontDir).substr(0, u.length) !== u && this.firefoxFontError(r);
  4425. }
  4426. n.loadWebFontError(r, s);
  4427. },
  4428. loadError: function(e) {
  4429. MathJax.Message.Set("Can't load web font " + n.fontInUse + "/" + e.directory, null, 2e3);
  4430. },
  4431. firefoxFontError: function(e) {
  4432. MathJax.Message.Set("Firefox can't load web fonts from a remote host", null, 3e3);
  4433. },
  4434. checkWebFont: function(e, t, r) {
  4435. if (e.time(r)) return;
  4436. n.Font.testFont(t) ? r(e.STATUS.OK) : setTimeout(e, e.delay);
  4437. },
  4438. fontFace: function(t) {
  4439. var r = n.allowWebFonts, i = n.FONTDATA.FONTS[t];
  4440. n.msieFontCSSBug && !i.family.match(/-Web$/) && (i.family += "-Web");
  4441. var s = e.fileURL(n.webfontDir + "/" + r), o = t.replace(/-b/, "-B").replace(/-i/, "-I").replace(/-Bold-/, "-Bold");
  4442. o.match(/-/) || (o += "-Regular"), r === "svg" ? o += ".svg#" + o : o += "." + r;
  4443. var u = {
  4444. "font-family": i.family,
  4445. src: "url('" + s + "/" + o + "')"
  4446. };
  4447. r === "svg" && (u.src += " format('svg')");
  4448. if (!n.FontFaceBug || !i.isWebFont) t.match(/-bold/) && (u["font-weight"] = "bold"), t.match(/-italic/) && (u["font-style"] = "italic");
  4449. return u;
  4450. }
  4451. });
  4452. n.Augment({
  4453. config: {
  4454. styles: {
  4455. ".MathJax": {
  4456. display: "inline",
  4457. "font-family": "serif",
  4458. "font-style": "normal",
  4459. "font-weight": "normal",
  4460. "line-height": "normal",
  4461. "font-size": "100%",
  4462. "font-size-adjust": "none",
  4463. "text-indent": 0,
  4464. "text-align": "left",
  4465. "text-transform": "none",
  4466. "letter-spacing": "normal",
  4467. "word-spacing": "normal",
  4468. "word-wrap": "normal",
  4469. "white-space": "nowrap",
  4470. "float": "none",
  4471. direction: "ltr",
  4472. border: 0,
  4473. padding: 0,
  4474. margin: 0
  4475. },
  4476. ".MathJax_Display": {
  4477. position: "relative",
  4478. display: "block",
  4479. width: "100%"
  4480. },
  4481. ".MathJax img, .MathJax nobr, .MathJax a": {
  4482. border: 0,
  4483. padding: 0,
  4484. margin: 0,
  4485. "max-width": "none",
  4486. "max-height": "none",
  4487. "vertical-align": 0,
  4488. "line-height": "normal",
  4489. "text-decoration": "none"
  4490. },
  4491. "img.MathJax_strut": {
  4492. border: "0 !important",
  4493. padding: "0 !important",
  4494. margin: "0 !important",
  4495. "vertical-align": "0 !important"
  4496. },
  4497. ".MathJax span": {
  4498. display: "inline",
  4499. position: "static",
  4500. border: 0,
  4501. padding: 0,
  4502. margin: 0,
  4503. "vertical-align": 0,
  4504. "line-height": "normal",
  4505. "text-decoration": "none"
  4506. },
  4507. ".MathJax nobr": {
  4508. "white-space": "nowrap"
  4509. },
  4510. ".MathJax img": {
  4511. display: "inline ! important"
  4512. },
  4513. ".MathJax_Processing": {
  4514. visibility: "hidden",
  4515. position: "fixed",
  4516. width: 0,
  4517. height: 0,
  4518. overflow: "hidden"
  4519. },
  4520. ".MathJax .MathJax_HitBox": {
  4521. cursor: "text"
  4522. },
  4523. "#MathJax_Tooltip": {
  4524. position: "absolute",
  4525. left: 0,
  4526. top: 0,
  4527. width: "auto",
  4528. height: "auto",
  4529. display: "none"
  4530. },
  4531. "#MathJax_Tooltip *": {
  4532. filter: "none",
  4533. background: "transparent"
  4534. }
  4535. }
  4536. },
  4537. settings: t.config.menuSettings,
  4538. LEFTBUTTON: t.Browser.isMSIE ? 1 : 0,
  4539. MENUKEY: "altKey",
  4540. Font: null,
  4541. Config: function() {
  4542. this.Font = i(), this.SUPER(arguments).Config.call(this);
  4543. var e = this.settings;
  4544. this.adjustAvailableFonts && this.adjustAvailableFonts(this.config.availableFonts), e.scale && (this.config.scale = e.scale), e.font && e.font !== "Auto" && (e.font === "TeX (local)" ? (this.config.availableFonts = [ "TeX" ], this.config.preferredFont = "TeX", this.config.webFont = "TeX") : e.font === "STIX (local)" ? (this.config.availableFonts = [ "STIX" ], this.config.preferredFont = "STIX", this.config.webFont = "TeX") : e.font === "TeX (web)" ? (this.config.availableFonts = [], this.config.preferredFont = "", this.config.webFont = "TeX") : e.font === "TeX (image)" && (this.config.availableFonts = [], this.config.preferredFont = "", this.config.webFont = ""));
  4545. var n = this.Font.findFont(this.config.availableFonts, this.config.preferredFont);
  4546. !n && this.allowWebFonts && (n = this.config.webFont, n && (this.webFonts = !0)), !n && this.config.imageFont && (n = this.config.imageFont, this.imgFonts = !0), n ? (this.fontInUse = n, this.fontDir += "/" + n, this.webfontDir += "/" + n, this.require || (this.require = []), this.require.push(this.fontDir + "/fontdata.js"), this.imgFonts && (this.require.push(this.directory + "/imageFonts.js"), t.Startup.signal.Post("HTML-CSS Jax - using image fonts"))) : (MathJax.Message.Set("Can't find a valid font using [" + this.config.availableFonts.join(", ") + "]", null, 3e3), this.FONTDATA = {
  4547. TeX_factor: 1,
  4548. baselineskip: 1.2,
  4549. lineH: .8,
  4550. lineD: .2,
  4551. ffLineH: .8,
  4552. FONTS: {},
  4553. VARIANT: {
  4554. normal: {
  4555. fonts: []
  4556. }
  4557. },
  4558. RANGES: [],
  4559. DELIMITERS: {},
  4560. RULECHAR: 45,
  4561. REMAP: {}
  4562. }, MathJax.InputJax.TeX && MathJax.InputJax.TeX.Definitions && (MathJax.InputJax.TeX.Definitions.macros.overline[1] = "002D", MathJax.InputJax.TeX.Definitions.macros.underline[1] = "002D"), t.Startup.signal.Post("HTML-CSS Jax - no valid font"));
  4563. },
  4564. Startup: function() {
  4565. var t = [], r = this.FONTDATA.VARIANT.normal.fonts;
  4566. r instanceof Array || (r = [ r ]);
  4567. for (var i = 0, s = r.length; i < s; i++) t[i] = this.FONTDATA.FONTS[r[i]].family, t[i] || (t[i] = r[i]);
  4568. this.config.styles[".MathJax .math span"] = this.config.styles["#MathJax_getScales"] = {
  4569. "font-family": t.join(",")
  4570. }, this.hiddenDiv = this.Element("div", {
  4571. style: {
  4572. visibility: "hidden",
  4573. overflow: "hidden",
  4574. position: "absolute",
  4575. top: 0,
  4576. height: "1px",
  4577. width: "auto",
  4578. padding: 0,
  4579. border: 0,
  4580. margin: 0,
  4581. textAlign: "left",
  4582. textIndent: 0,
  4583. textTransform: "none",
  4584. lineHeight: "normal",
  4585. letterSpacing: "normal",
  4586. wordSpacing: "normal"
  4587. }
  4588. }), document.body.firstChild ? document.body.insertBefore(this.hiddenDiv, document.body.firstChild) : document.body.appendChild(this.hiddenDiv), this.hiddenDiv = this.addElement(this.hiddenDiv, "div", {
  4589. id: "MathJax_Hidden"
  4590. });
  4591. var o = this.addElement(this.hiddenDiv, "div", {
  4592. style: {
  4593. width: "5in"
  4594. }
  4595. });
  4596. this.pxPerInch = o.offsetWidth / 5, this.hiddenDiv.removeChild(o), this.startMarker = n.createStrut(this.Element("span"), 10, !0), this.endMarker = this.addText(this.Element("span"), "x").parentNode, this.HDspan = this.Element("span"), this.operaHeightBug && this.createStrut(this.HDspan, 0);
  4597. if (this.msieInlineBlockAlignBug) {
  4598. this.HDimg = this.addElement(this.HDspan, "img", {
  4599. style: {
  4600. height: "0px",
  4601. width: "1px"
  4602. }
  4603. });
  4604. try {
  4605. this.HDimg.src = "about:blank";
  4606. } catch (u) {}
  4607. } else this.HDimg = n.createStrut(this.HDspan, 0);
  4608. this.HDMspan = this.Element("span", {
  4609. style: {
  4610. position: "absolute",
  4611. "font-size-adjust": "none"
  4612. }
  4613. });
  4614. if (this.msieInlineBlockAlignBug) {
  4615. this.HDMimg = this.addElement(this.HDMspan, "img", {
  4616. style: {
  4617. height: "0px",
  4618. width: "1px",
  4619. "max-width": "none",
  4620. "max-height": "none",
  4621. border: 0,
  4622. padding: 0,
  4623. margin: 0
  4624. }
  4625. });
  4626. try {
  4627. this.HDMimg.src = "about:blank";
  4628. } catch (u) {}
  4629. } else this.HDMimg = n.createStrut(this.HDMspan, 0), this.HDMimg.style.marginRight = "";
  4630. return this.marginCheck = n.Element("span", null, [ [ "span", {
  4631. style: {
  4632. display: "inline-block",
  4633. width: "5em"
  4634. }
  4635. } ] ]), this.marginMove = n.addElement(this.marginCheck, "span", {
  4636. style: {
  4637. display: "inline-block",
  4638. width: "5em",
  4639. marginLeft: "-5em"
  4640. }
  4641. }), e.Styles(this.config.styles, [ "PreloadWebFonts", this ]);
  4642. },
  4643. PreloadWebFonts: function() {
  4644. if (!n.allowWebFonts || !n.config.preloadWebFonts) return;
  4645. for (var e = 0, t = n.config.preloadWebFonts.length; e < t; e++) {
  4646. var r = n.FONTDATA.FONTS[n.config.preloadWebFonts[e]];
  4647. r.available || n.Font.testFont(r);
  4648. }
  4649. },
  4650. Translate: function(e) {
  4651. if (!e.parentNode) return;
  4652. var t = e.previousSibling;
  4653. t && String(t.className).match(/^MathJax(_MathML|_Display)?$/) && t.parentNode.removeChild(t);
  4654. var n = e.MathJax.elementJax.root, r, i, s;
  4655. r = i = s = this.Element("span", {
  4656. className: "MathJax",
  4657. oncontextmenu: this.ContextMenu,
  4658. onmousedown: this.Mousedown,
  4659. onmouseover: this.Mouseover,
  4660. onclick: this.Click,
  4661. ondblclick: this.DblClick
  4662. });
  4663. var o = n.Get("display") === "block";
  4664. o && (i = s = this.Element("div", {
  4665. className: "MathJax_Display",
  4666. style: {
  4667. width: "100%",
  4668. position: "relative"
  4669. }
  4670. }), i.appendChild(r)), i.setAttribute("role", "textbox"), i.setAttribute("aria-readonly", "true"), this.useProcessingFrame && (s = this.Element(o ? "div" : "span", {
  4671. className: "MathJax_Processing"
  4672. }), s.appendChild(i)), e.parentNode.insertBefore(s, e);
  4673. var u;
  4674. try {
  4675. this.getScales(r), u = this.em === 0 || String(this.em) === "NaN";
  4676. } catch (a) {
  4677. u = !0;
  4678. }
  4679. u && (this.hiddenDiv.appendChild(s), this.getScales(r)), this.initImg(r), this.initHTML(n, r), n.setTeXclass();
  4680. try {
  4681. n.toHTML(r, i);
  4682. } catch (a) {
  4683. throw a.restart && s.parentNode.removeChild(s), a;
  4684. }
  4685. u && e.parentNode.insertBefore(s, e), this.useProcessingFrame && s.parentNode.replaceChild(i, s);
  4686. },
  4687. ContextMenu: function(r, i) {
  4688. if (n.config.showMathMenu && (n.settings.context === "MathJax" || i)) {
  4689. n.safariContextMenuBug && setTimeout("window.getSelection().empty()", 0);
  4690. if (!r || n.msieEventBug) r = window.event;
  4691. var s = MathJax.Menu;
  4692. if (s) {
  4693. var o = this.parentNode.className === "MathJax_Display" ? this.parentNode : this;
  4694. return s.jax = t.getJaxFor(o.nextSibling), s.menu.items[1].menu.items[1].name = s.jax.inputJax.id === "MathML" ? "Original" : s.jax.inputJax.id, s.menu.Post(r);
  4695. }
  4696. if (!e.loadingMathMenu) {
  4697. e.loadingMathMenu = !0;
  4698. var u = {
  4699. pageX: r.pageX,
  4700. pageY: r.pageY,
  4701. clientX: r.clientX,
  4702. clientY: r.clientY
  4703. };
  4704. MathJax.Callback.Queue(e.Require("[MathJax]/extensions/MathMenu.js"), function() {
  4705. delete e.loadingMathMenu;
  4706. }, [ this, arguments.callee, u, i ]);
  4707. }
  4708. return r || (r = window.event), r.preventDefault && r.preventDefault(), r.stopPropagation && r.stopPropagation(), r.cancelBubble = !0, r.returnValue = !1, !1;
  4709. }
  4710. },
  4711. Mousedown: function(e) {
  4712. if (n.config.showMathMenu) {
  4713. e || (e = window.event);
  4714. if (n.settings.context === "MathJax") {
  4715. if (!n.noContextMenuBug || e.button !== 2) return;
  4716. } else if (!e[n.MENUKEY] || e.button !== n.LEFTBUTTON) return;
  4717. return n.ContextMenu.call(this, e, !0);
  4718. }
  4719. },
  4720. Mouseover: function(e) {
  4721. n.HandleEvent(e, "Mouseover", this);
  4722. },
  4723. Click: function(e) {
  4724. n.HandleEvent(e, "Click", this);
  4725. },
  4726. DblClick: function(e) {
  4727. n.HandleEvent(e, "DblClick", this);
  4728. },
  4729. HandleEvent: function(e, t, n) {},
  4730. initImg: function(e) {},
  4731. initHTML: function(e, t) {},
  4732. initFont: function(t) {
  4733. var r = n.FONTDATA.FONTS, i = n.config.availableFonts;
  4734. return i && i.length && n.Font.testFont(r[t]) ? (r[t].available = !0, null) : this.allowWebFonts ? (r[t].isWebFont = !0, n.FontFaceBug && (r[t].family = t, n.msieFontCSSBug && (r[t].family += "-Web")), e.Styles({
  4735. "@font-face": this.Font.fontFace(t)
  4736. })) : null;
  4737. },
  4738. Remove: function(e) {
  4739. var t = e.SourceElement();
  4740. if (!t) return;
  4741. t = t.previousSibling;
  4742. if (!t) return;
  4743. t.className.match(/^MathJax/) && t.parentNode.removeChild(t);
  4744. },
  4745. getScales: function(e) {
  4746. e.parentNode.insertBefore(this.HDMspan, e), this.HDMspan.className = "", this.HDMspan.id = "", this.HDMspan.style.fontSize = "", this.HDMimg.style.height = "1px", this.HDMimg.style.width = "60ex";
  4747. var t = this.HDMspan.offsetWidth / 60;
  4748. this.HDMspan.className = "MathJax", this.HDMspan.id = "MathJax_getScales", this.HDMimg.style.width = "60em";
  4749. var n = this.outerEm = this.HDMspan.offsetWidth / 60;
  4750. this.scale = Math.floor(Math.max(this.config.minScaleAdjust / 100, t / this.TeX.x_height / n) * this.config.scale), e.style.fontSize = this.HDMspan.style.fontSize = this.scale + "%", this.em = r.mbase.prototype.em = this.HDMspan.offsetWidth / 60, this.operaFontSizeBug && n === this.em && this.scale !== 100 && (this.em = r.mbase.prototype.em = n * this.scale / 100), e.parentNode.removeChild(this.HDMspan), this.msieMarginScale = this.getMarginScale(e);
  4751. },
  4752. getMarginScale: function(e) {
  4753. return 1;
  4754. },
  4755. getMSIEmarginScale: function(e) {
  4756. e.appendChild(this.marginCheck);
  4757. var t = this.marginCheck.offsetWidth, n = this.marginMove.offsetWidth, r = 2 * n - t ? n / (2 * n - t) : 1;
  4758. return e.removeChild(this.marginCheck), r;
  4759. },
  4760. getHD: function(e) {
  4761. var t = e.style.position;
  4762. e.style.position = "absolute", this.HDimg.style.height = "0px", e.appendChild(this.HDspan);
  4763. var n = {
  4764. h: e.offsetHeight
  4765. };
  4766. return this.HDimg.style.height = n.h + "px", n.d = e.offsetHeight - n.h, n.h -= n.d, n.h /= this.em, n.d /= this.em, e.removeChild(this.HDspan), e.style.position = t, n;
  4767. },
  4768. getW: function(e) {
  4769. var t = e.offsetWidth, n = e.bbox ? e.bbox.w : -1, r = e;
  4770. if ((n < 0 || this.negativeSkipBug) && t >= 0) {
  4771. if (this.negativeSkipBug) {
  4772. var i = e.style.position;
  4773. e.style.position = "absolute", r = this.startMarker, e.firstChild ? e.insertBefore(r, e.firstChild) : e.appendChild(r), r = this.startMarker;
  4774. }
  4775. e.appendChild(this.endMarker), t = this.endMarker.offsetLeft - r.offsetLeft, e.removeChild(this.endMarker), this.negativeSkipBug && (e.removeChild(r), e.style.position = i);
  4776. }
  4777. return t / this.em;
  4778. },
  4779. Measured: function(e, t) {
  4780. if (e.bbox.width == null && e.bbox.w && !e.bbox.isMultiline) {
  4781. var n = this.getW(e);
  4782. e.bbox.rw += n - e.bbox.w, e.bbox.w = n;
  4783. }
  4784. return t || (t = e.parentNode), t.bbox || (t.bbox = e.bbox), e;
  4785. },
  4786. Remeasured: function(e, t) {
  4787. t.bbox = this.Measured(e, t).bbox;
  4788. },
  4789. Em: function(e) {
  4790. return Math.abs(e) < 6e-4 ? "0em" : e.toFixed(3).replace(/\.?0+$/, "") + "em";
  4791. },
  4792. Percent: function(e) {
  4793. return (100 * e).toFixed(1).replace(/\.?0+$/, "") + "%";
  4794. },
  4795. length2percent: function(e) {
  4796. return this.Percent(this.length2em(e));
  4797. },
  4798. length2em: function(e, t) {
  4799. typeof e != "string" && (e = e.toString());
  4800. if (e === "") return "";
  4801. if (e === r.SIZE.NORMAL) return 1;
  4802. if (e === r.SIZE.BIG) return 2;
  4803. if (e === r.SIZE.SMALL) return .71;
  4804. if (e === "infinity") return n.BIGDIMEN;
  4805. var i = this.FONTDATA.TeX_factor;
  4806. if (e.match(/mathspace$/)) return n.MATHSPACE[e] * i;
  4807. var s = e.match(/^\s*([-+]?(?:\.\d+|\d+(?:\.\d*)?))?(pt|em|ex|mu|px|pc|in|mm|cm|%)?/), o = parseFloat(s[1] || "1"), u = s[2];
  4808. return t == null && (t = 1), u === "em" ? o * i : u === "ex" ? o * n.TeX.x_height * i : u === "%" ? o / 100 * t : u === "px" ? o / n.em : u === "pt" ? o / 10 * i : u === "pc" ? o * 1.2 * i : u === "in" ? o * this.pxPerInch / n.em : u === "cm" ? o * this.pxPerInch / n.em / 2.54 : u === "mm" ? o * this.pxPerInch / n.em / 25.4 : u === "mu" ? o / 18 * i : o * i * t;
  4809. },
  4810. thickness2em: function(e) {
  4811. var t = n.TeX.rule_thickness;
  4812. return e === r.LINETHICKNESS.MEDIUM ? t : e === r.LINETHICKNESS.THIN ? .67 * t : e === r.LINETHICKNESS.THICK ? 1.67 * t : this.length2em(e, t);
  4813. },
  4814. createStrut: function(e, t, n) {
  4815. var r = this.Element("span", {
  4816. style: {
  4817. display: "inline-block",
  4818. overflow: "hidden",
  4819. height: t + "px",
  4820. width: "1px",
  4821. marginRight: "-1px"
  4822. }
  4823. });
  4824. return n ? e.insertBefore(r, e.firstChild) : e.appendChild(r), r;
  4825. },
  4826. createBlank: function(e, t, n) {
  4827. var r = this.Element("span", {
  4828. style: {
  4829. display: "inline-block",
  4830. overflow: "hidden",
  4831. height: "1px",
  4832. width: this.Em(t)
  4833. }
  4834. });
  4835. return n ? e.insertBefore(r, e.firstChild) : e.appendChild(r), r;
  4836. },
  4837. createShift: function(e, t, n) {
  4838. var r = this.Element("span", {
  4839. style: {
  4840. marginLeft: this.Em(t)
  4841. }
  4842. });
  4843. return n ? e.insertBefore(r, e.firstChild) : e.appendChild(r), r;
  4844. },
  4845. createSpace: function(e, t, i, s, o) {
  4846. var u = this.Em(Math.max(0, t + i)), f = this.Em(-i);
  4847. return this.msieInlineBlockAlignBug && (f = this.Em(n.getHD(e.parentNode).d - i)), e.isBox || e.className == "mspace" ? (e.bbox = {
  4848. h: t * e.scale,
  4849. d: i * e.scale,
  4850. w: s * e.scale,
  4851. rw: s * e.scale,
  4852. lw: 0
  4853. }, e.style.height = u, e.style.verticalAlign = f) : e = this.addElement(e, "span", {
  4854. style: {
  4855. height: u,
  4856. verticalAlign: f
  4857. }
  4858. }), s >= 0 ? (e.style.width = this.Em(s), e.style.display = "inline-block") : (this.msieNegativeSpaceBug && (e.style.height = ""), e.style.marginLeft = this.Em(s), n.safariNegativeSpaceBug && e.parentNode.firstChild == e && this.createBlank(e, 0, !0)), o && o !== r.COLOR.TRANSPARENT && (e.style.backgroundColor = o), e;
  4859. },
  4860. createRule: function(e, t, r, i, s) {
  4861. var o = n.TeX.min_rule_thickness;
  4862. i > 0 && i * this.em < o && (i = o / this.em);
  4863. if (t + r > 0 && (t + r) * this.em < o) {
  4864. var u = 1 / (t + r) * (o / this.em);
  4865. t *= u, r *= u;
  4866. }
  4867. s ? s = "solid " + s : s = "solid", s = this.Em(i) + " " + s;
  4868. var a = this.Em(t + r), f = this.Em(-r), l = this.addElement(e, "span", {
  4869. style: {
  4870. borderLeft: s,
  4871. display: "inline-block",
  4872. overflow: "hidden",
  4873. width: 0,
  4874. height: a,
  4875. verticalAlign: f
  4876. },
  4877. bbox: {
  4878. h: t,
  4879. d: r,
  4880. w: i,
  4881. rw: i,
  4882. lw: 0
  4883. },
  4884. noAdjust: !0
  4885. });
  4886. i > 0 && l.offsetWidth == 0 && (l.style.width = this.Em(i));
  4887. if (e.isBox || e.className == "mspace") e.bbox = l.bbox;
  4888. return l;
  4889. },
  4890. createFrame: function(e, t, n, r, i, s) {
  4891. var o = this.msieBorderWidthBug ? 0 : 2 * i, u = this.Em(t + n - o), a = this.Em(-n - i), f = this.Em(r - o), l = this.Em(i) + " " + s, c = this.addElement(e, "span", {
  4892. style: {
  4893. border: l,
  4894. display: "inline-block",
  4895. overflow: "hidden",
  4896. width: f,
  4897. height: u
  4898. },
  4899. bbox: {
  4900. h: t,
  4901. d: n,
  4902. w: r,
  4903. rw: r,
  4904. lw: 0
  4905. },
  4906. noAdjust: !0
  4907. });
  4908. return a && (c.style.verticalAlign = a), c;
  4909. },
  4910. createStack: function(e, t, n) {
  4911. this.msiePaddingWidthBug && this.createStrut(e, 0);
  4912. var r = String(n).match(/%$/), i = !r && n != null ? n : 0;
  4913. return e = this.addElement(e, "span", {
  4914. noAdjust: !0,
  4915. style: {
  4916. display: "inline-block",
  4917. position: "relative",
  4918. width: r ? "100%" : this.Em(i),
  4919. height: 0
  4920. }
  4921. }), t || (e.parentNode.bbox = e.bbox = {
  4922. h: -this.BIGDIMEN,
  4923. d: -this.BIGDIMEN,
  4924. w: i,
  4925. lw: this.BIGDIMEN,
  4926. rw: !r && n != null ? n : -this.BIGDIMEN
  4927. }, r && (e.bbox.width = n)), e;
  4928. },
  4929. createBox: function(e, t) {
  4930. var n = this.addElement(e, "span", {
  4931. style: {
  4932. position: "absolute"
  4933. },
  4934. isBox: !0
  4935. });
  4936. return t != null && (n.style.width = t), n;
  4937. },
  4938. addBox: function(e, t) {
  4939. return t.style.position = "absolute", t.isBox = !0, e.appendChild(t);
  4940. },
  4941. placeBox: function(e, t, r, i) {
  4942. var s = e.parentNode, o = e.bbox, u = s.bbox;
  4943. this.msiePlaceBoxBug && this.addText(e, this.NBSP), this.imgSpaceBug && this.addText(e, this.imgSpace);
  4944. var a = e.offsetHeight / this.em + 1, f = 0;
  4945. e.noAdjust ? a -= 1 : this.msieInlineBlockAlignBug ? this.addElement(e, "img", {
  4946. className: "MathJax_strut",
  4947. border: 0,
  4948. src: "about:blank",
  4949. style: {
  4950. width: 0,
  4951. height: this.Em(a)
  4952. }
  4953. }) : this.addElement(e, "span", {
  4954. style: {
  4955. display: "inline-block",
  4956. width: 0,
  4957. height: this.Em(a)
  4958. }
  4959. }), e.style.top = this.Em(-r - a), e.style.left = this.Em(t + f);
  4960. if (o) {
  4961. this.negativeSkipBug && (o.lw < 0 && (f = o.lw, n.createBlank(e, -f, !0), v = 0), o.rw > o.w && n.createBlank(e, o.rw - o.w + .1));
  4962. if (!this.msieClipRectBug && !o.noclip && !i) {
  4963. var l = 3 / this.em, c = o.H == null ? o.h : o.H, h = o.D == null ? o.d : o.D, p = a - c - l, d = a + h + l, v = o.lw - 3 * l, m = 1e3;
  4964. o.isFixed && (m = o.width - v), e.style.clip = "rect(" + this.Em(p) + " " + this.Em(m) + " " + this.Em(d) + " " + this.Em(v) + ")";
  4965. }
  4966. }
  4967. o && u && (o.H != null && (u.H == null || o.H + r > u.H) && (u.H = o.H + r), o.D != null && (u.D == null || o.D - r > u.D) && (u.D = o.D - r), o.h + r > u.h && (u.h = o.h + r), o.d - r > u.d && (u.d = o.d - r), u.H != null && u.H <= u.h && delete u.H, u.D != null && u.D <= u.d && delete u.D, o.w + t > u.w && (u.w = o.w + t, u.width == null && (s.style.width = this.Em(u.w))), o.rw + t > u.rw && (u.rw = o.rw + t), o.lw + t < u.lw && (u.lw = o.lw + t), o.width != null && !o.isFixed && (u.width == null && (s.style.width = u.width = "100%"), e.style.width = o.width));
  4968. },
  4969. alignBox: function(e, n, r) {
  4970. this.placeBox(e, 0, r);
  4971. var i = e.bbox;
  4972. if (i.isMultiline) return;
  4973. var s = i.width != null && !i.isFixed, o = 0, u = -i.w / 2, a = "50%";
  4974. this.negativeSkipBug && (o = i.w - i.rw - .1, u += i.lw), u = this.Em(u * this.msieMarginScale), s && (u = "", a = 50 - parseFloat(i.width) / 2 + "%"), t.Insert(e.style, {
  4975. right: {
  4976. left: "",
  4977. right: this.Em(o)
  4978. },
  4979. center: {
  4980. left: a,
  4981. marginLeft: u
  4982. }
  4983. }[n]);
  4984. },
  4985. setStackWidth: function(e, t) {
  4986. typeof t == "number" ? (e.style.width = this.Em(Math.max(0, t)), e.bbox && (e.bbox.w = t), e.parentNode.bbox && (e.parentNode.bbox.w = t)) : (e.style.width = e.parentNode.style.width = "100%", e.bbox && (e.bbox.width = t), e.parentNode.bbox && (e.parentNode.bbox.width = t));
  4987. },
  4988. createDelimiter: function(e, t, n, i, s) {
  4989. if (!t) {
  4990. e.bbox = {
  4991. h: 0,
  4992. d: 0,
  4993. w: this.TeX.nulldelimiterspace,
  4994. lw: 0
  4995. }, e.bbox.rw = e.bbox.w, this.createSpace(e, e.bbox.h, e.bbox.d, e.bbox.w);
  4996. return;
  4997. }
  4998. i || (i = 1), n instanceof Array || (n = [ n, n ]);
  4999. var o = n[1];
  5000. n = n[0];
  5001. var u = {
  5002. alias: t
  5003. };
  5004. while (u.alias) t = u.alias, u = this.FONTDATA.DELIMITERS[t], u || (u = {
  5005. HW: [ 0, this.FONTDATA.VARIANT[r.VARIANT.NORMAL] ]
  5006. });
  5007. for (var f = 0, l = u.HW.length; f < l; f++) if (u.HW[f][0] * i >= n - .01 || f == l - 1 && !u.stretch) {
  5008. u.HW[f][2] && (i *= u.HW[f][2]), u.HW[f][3] && (t = u.HW[f][3]);
  5009. var c = this.addElement(e, "span");
  5010. this.createChar(c, [ t, u.HW[f][1] ], i, s), e.bbox = c.bbox, e.offset = .65 * e.bbox.w, e.scale = i;
  5011. return;
  5012. }
  5013. u.stretch && this["extendDelimiter" + u.dir](e, o, u.stretch, i, s);
  5014. },
  5015. extendDelimiterV: function(e, t, n, r, i) {
  5016. var s = this.createStack(e, !0), o = this.createBox(s), u = this.createBox(s);
  5017. this.createChar(o, n.top || n.ext, r, i), this.createChar(u, n.bot || n.ext, r, i);
  5018. var a = {
  5019. bbox: {
  5020. w: 0,
  5021. lw: 0,
  5022. rw: 0
  5023. }
  5024. }, f = a, l, c = o.bbox.h + o.bbox.d + u.bbox.h + u.bbox.d, h = -o.bbox.h;
  5025. this.placeBox(o, 0, h, !0), h -= o.bbox.d, n.mid && (f = this.createBox(s), this.createChar(f, n.mid, r, i), c += f.bbox.h + f.bbox.d);
  5026. if (t > c) {
  5027. a = this.Element("span"), this.createChar(a, n.ext, r, i);
  5028. var p = a.bbox.h + a.bbox.d, d = p - .05, v, m, g = n.mid ? 2 : 1;
  5029. m = v = Math.ceil((t - c) / (g * d)), n.fullExtenders || (d = (t - c) / (g * v));
  5030. var y = v / (v + 1) * (p - d);
  5031. d = p - y, h += y + d - a.bbox.h;
  5032. while (g-- > 0) {
  5033. while (v-- > 0) this.msieCloneNodeBug ? (l = this.Element("span"), this.createChar(l, n.ext, r, i)) : l = a.cloneNode(!0), h -= d, this.placeBox(this.addBox(s, l), 0, h, !0);
  5034. h += y - a.bbox.d, n.mid && g && (this.placeBox(f, 0, h - f.bbox.h, !0), v = m, h += -(f.bbox.h + f.bbox.d) + y + d - a.bbox.h);
  5035. }
  5036. } else h += (c - t) / 2, n.mid && (this.placeBox(f, 0, h - f.bbox.h, !0), h += -(f.bbox.h + f.bbox.d)), h += (c - t) / 2;
  5037. this.placeBox(u, 0, h - u.bbox.h, !0), h -= u.bbox.h + u.bbox.d, e.bbox = {
  5038. w: Math.max(o.bbox.w, a.bbox.w, u.bbox.w, f.bbox.w),
  5039. lw: Math.min(o.bbox.lw, a.bbox.lw, u.bbox.lw, f.bbox.lw),
  5040. rw: Math.max(o.bbox.rw, a.bbox.rw, u.bbox.rw, f.bbox.rw),
  5041. h: 0,
  5042. d: -h
  5043. }, e.scale = r, e.offset = .55 * e.bbox.w, e.isMultiChar = !0, this.setStackWidth(s, e.bbox.w);
  5044. },
  5045. extendDelimiterH: function(e, t, n, r, i) {
  5046. var s = this.createStack(e, !0), o = this.createBox(s), u = this.createBox(s);
  5047. this.createChar(o, n.left || n.rep, r, i), this.createChar(u, n.right || n.rep, r, i);
  5048. var a = this.Element("span");
  5049. this.createChar(a, n.rep, r, i);
  5050. var f = {
  5051. bbox: {
  5052. h: -this.BIGDIMEN,
  5053. d: -this.BIGDIMEN
  5054. }
  5055. }, l;
  5056. this.placeBox(o, -o.bbox.lw, 0, !0);
  5057. var c = o.bbox.rw - o.bbox.lw + (u.bbox.rw - u.bbox.lw) - .05, h = o.bbox.rw - o.bbox.lw - .025, p;
  5058. n.mid && (f = this.createBox(s), this.createChar(f, n.mid, r, i), c += f.bbox.w);
  5059. if (t > c) {
  5060. var d = a.bbox.rw - a.bbox.lw, v = d - .05, m, g, y = n.mid ? 2 : 1;
  5061. g = m = Math.ceil((t - c) / (y * v)), v = (t - c) / (y * m), p = m / (m + 1) * (d - v), v = d - p, h -= a.bbox.lw + p;
  5062. while (y-- > 0) {
  5063. while (m-- > 0) this.msieCloneNodeBug ? (l = this.Element("span"), this.createChar(l, n.rep, r, i)) : l = a.cloneNode(!0), this.placeBox(this.addBox(s, l), h, 0, !0), h += v;
  5064. n.mid && y && (this.placeBox(f, h, 0, !0), h += f.bbox.w - p, m = g);
  5065. }
  5066. } else p = Math.min(c - t, o.bbox.w / 2), h -= p / 2, n.mid && (this.placeBox(f, h, 0, !0), h += f.bbox.w), h -= p / 2;
  5067. this.placeBox(u, h, 0, !0), e.bbox = {
  5068. w: h + u.bbox.rw,
  5069. lw: 0,
  5070. rw: h + u.bbox.rw,
  5071. H: Math.max(o.bbox.h, a.bbox.h, u.bbox.h, f.bbox.h),
  5072. D: Math.max(o.bbox.d, a.bbox.d, u.bbox.d, f.bbox.d),
  5073. h: a.bbox.h,
  5074. d: a.bbox.d
  5075. }, e.scale = r, e.isMultiChar = !0, this.setStackWidth(s, e.bbox.w);
  5076. },
  5077. createChar: function(e, t, i, s) {
  5078. var o = e, u = "", f = {
  5079. fonts: [ t[1] ],
  5080. noRemap: !0
  5081. };
  5082. s && s === r.VARIANT.BOLD && (f.fonts = [ t[1] + "-bold", t[1] ]), typeof t[1] != "string" && (f = t[1]);
  5083. if (t[0] instanceof Array) for (var l = 0, c = t[0].length; l < c; l++) u += String.fromCharCode(t[0][l]); else u = String.fromCharCode(t[0]);
  5084. i !== 1 ? (o = this.addElement(e, "span", {
  5085. style: {
  5086. fontSize: this.Percent(i)
  5087. },
  5088. scale: i
  5089. }), this.handleVariant(o, f, u), e.bbox = o.bbox) : this.handleVariant(e, f, u), t[2] && (e.style.marginLeft = this.Em(t[2])), this.AccentBug && e.bbox.w === 0 && (o.firstChild.nodeValue += this.NBSP, n.createSpace(e, 0, 0, -e.offsetWidth / n.em));
  5090. },
  5091. positionDelimiter: function(e, t) {
  5092. t -= e.bbox.h, e.bbox.d -= t, e.bbox.h += t, t && (this.safariVerticalAlignBug || this.msieVerticalAlignBug || this.konquerorVerticalAlignBug || this.operaVerticalAlignBug && e.isMultiChar ? (e.firstChild.style.display === "" && e.style.top !== "" && (e = e.firstChild, t -= parseFloat(e.style.top)), e.style.position = "relative", e.style.top = this.Em(-t)) : (e.style.verticalAlign = this.Em(t), n.ffVerticalAlignBug && n.createRule(e.parentNode, e.bbox.h, 0, 0)));
  5093. },
  5094. handleVariant: function(e, t, n) {
  5095. var i = "", s, o, u, f, l, c, h = e;
  5096. if (n.length === 0) return;
  5097. e.bbox || (e.bbox = {
  5098. w: 0,
  5099. h: -this.BIGDIMEN,
  5100. d: -this.BIGDIMEN,
  5101. rw: -this.BIGDIMEN,
  5102. lw: this.BIGDIMEN
  5103. }), t || (t = this.FONTDATA.VARIANT[r.VARIANT.NORMAL]), c = t;
  5104. for (var p = 0, d = n.length; p < d; p++) {
  5105. t = c, s = n.charCodeAt(p), o = n.charAt(p);
  5106. if (o === this.PLANE1) {
  5107. p++, s = n.charCodeAt(p) + 119808 - 56320;
  5108. if (this.FONTDATA.RemapPlane1) {
  5109. var v = this.FONTDATA.RemapPlane1(s, t);
  5110. s = v.n, t = v.variant;
  5111. }
  5112. } else {
  5113. var m, g, y = this.FONTDATA.RANGES;
  5114. for (m = 0, g = y.length; m < g; m++) {
  5115. if (y[m].name === "alpha" && t.noLowerCase) continue;
  5116. var b = t["offset" + y[m].offset];
  5117. if (b && s >= y[m].low && s <= y[m].high) {
  5118. y[m].remap && y[m].remap[s] ? s = b + y[m].remap[s] : (s = s - y[m].low + b, y[m].add && (s += y[m].add)), t["variant" + y[m].offset] && (t = this.FONTDATA.VARIANT[t["variant" + y[m].offset]]);
  5119. break;
  5120. }
  5121. }
  5122. }
  5123. if (t.remap && t.remap[s]) if (t.remap[s] instanceof Array) {
  5124. var w = t.remap[s];
  5125. s = w[0], t = this.FONTDATA.VARIANT[w[1]];
  5126. } else s = t.remap[s], t.remap.variant && (t = this.FONTDATA.VARIANT[t.remap.variant]);
  5127. this.FONTDATA.REMAP[s] && !t.noRemap && (s = this.FONTDATA.REMAP[s]), u = this.lookupChar(t, s), o = u[s], t !== l && !o[5].img && (i.length && (this.addText(h, i), i = ""), h = e, l = f, t !== l && (l ? h = this.addElement(e, "span") : f = t), this.handleFont(h, u, h !== e), l = t), i = this.handleChar(h, u, o, s, i), o[0] / 1e3 > e.bbox.h && (e.bbox.h = o[0] / 1e3), o[1] / 1e3 > e.bbox.d && (e.bbox.d = o[1] / 1e3), e.bbox.w + o[3] / 1e3 < e.bbox.lw && (e.bbox.lw = e.bbox.w + o[3] / 1e3), e.bbox.w + o[4] / 1e3 > e.bbox.rw && (e.bbox.rw = e.bbox.w + o[4] / 1e3), e.bbox.w += o[2] / 1e3;
  5128. }
  5129. i.length && this.addText(h, i), e.scale && e.scale !== 1 && (e.bbox.h *= e.scale, e.bbox.d *= e.scale, e.bbox.w *= e.scale, e.bbox.lw *= e.scale, e.bbox.rw *= e.scale), n.length == 1 && u.skew && u.skew[s] && (e.bbox.skew = u.skew[s]);
  5130. },
  5131. handleFont: function(e, t, r) {
  5132. e.style.fontFamily = t.family;
  5133. if (!n.FontFaceBug || !t.isWebFont) {
  5134. var i = t.style || "normal", s = t.weight || "normal";
  5135. if (i !== "normal" || r) e.style.fontStyle = i;
  5136. if (s !== "normal" || r) e.style.fontWeight = s;
  5137. }
  5138. },
  5139. handleChar: function(e, t, r, i, s) {
  5140. var o = r[5];
  5141. if (o.img) return this.handleImg(e, t, r, i, s);
  5142. if (o.isUnknown && this.FONTDATA.DELIMITERS[i]) {
  5143. s.length && this.addText(e, s);
  5144. var u = e.scale;
  5145. return n.createDelimiter(e, i, 0, 1, t), e.scale = u, r[0] = e.bbox.h * 1e3, r[1] = e.bbox.d * 1e3, r[2] = e.bbox.w * 1e3, r[3] = e.bbox.lw * 1e3, r[4] = e.bbox.rw * 1e3, "";
  5146. }
  5147. return o.c == null && (i <= 65535 ? o.c = String.fromCharCode(i) : o.c = this.PLANE1 + String.fromCharCode(i - 119808 + 56320)), r[2] || !this.msieAccentBug || s.length ? s + o.c : (n.createShift(e, r[3] / 1e3), n.createShift(e, (r[4] - r[3]) / 1e3), this.addText(e, o.c), n.createShift(e, -r[4] / 1e3), "");
  5148. },
  5149. handleImg: function(e, t, n, r, i) {
  5150. return i;
  5151. },
  5152. lookupChar: function(e, t) {
  5153. var r, i;
  5154. if (!e.FONTS) {
  5155. var s = this.FONTDATA.FONTS, o = e.fonts || this.FONTDATA.VARIANT.normal.fonts;
  5156. o instanceof Array || (o = [ o ]), e.fonts != o && (e.fonts = o), e.FONTS = [];
  5157. for (r = 0, i = o.length; r < i; r++) s[o[r]] && (e.FONTS.push(s[o[r]]), s[o[r]].name = o[r]);
  5158. }
  5159. for (r = 0, i = e.FONTS.length; r < i; r++) {
  5160. var u = e.FONTS[r];
  5161. typeof u == "string" && (delete e.FONTS, this.loadFont(u));
  5162. if (u[t]) {
  5163. u[t].length === 5 && (u[t][5] = {});
  5164. if (!n.allowWebFonts || !!u.available) return u;
  5165. this.loadWebFont(u);
  5166. } else this.findBlock(u, t);
  5167. }
  5168. var a = e.defaultFont || {
  5169. family: n.config.undefinedFamily
  5170. };
  5171. return e.bold && (a.weight = "bold"), e.italic && (a.style = "italic"), a[t] = [ 800, 200, 500, 0, 500, {
  5172. isUnknown: !0
  5173. } ], a;
  5174. },
  5175. findBlock: function(e, t) {
  5176. if (e.Ranges) for (var n = 0, r = e.Ranges.length; n < r; n++) {
  5177. if (t < e.Ranges[n][0]) return;
  5178. if (t <= e.Ranges[n][1]) {
  5179. var i = e.Ranges[n][2];
  5180. for (var s = e.Ranges.length - 1; s >= 0; s--) e.Ranges[s][2] == i && e.Ranges.splice(s, 1);
  5181. this.loadFont(e.directory + "/" + i + ".js");
  5182. }
  5183. }
  5184. },
  5185. loadFont: function(r) {
  5186. var i = MathJax.Callback.Queue();
  5187. i.Push([ "Require", e, this.fontDir + "/" + r ]), this.imgFonts && (MathJax.isPacked || (r = r.replace(/\/([^\/]*)$/, n.imgPacked + "/$1")), i.Push([ "Require", e, this.webfontDir + "/png/" + r ])), t.RestartAfter(i.Push({}));
  5188. },
  5189. loadWebFont: function(e) {
  5190. e.available = e.isWebFont = !0, n.FontFaceBug && (e.family = e.name, n.msieFontCSSBug && (e.family += "-Web")), t.RestartAfter(this.Font.loadWebFont(e));
  5191. },
  5192. loadWebFontError: function(n, r) {
  5193. t.Startup.signal.Post("HTML-CSS Jax - disable web fonts"), n.isWebFont = !1, this.config.imageFont && this.config.imageFont === this.fontInUse ? (this.imgFonts = !0, t.Startup.signal.Post("HTML-CSS Jax - switch to image fonts"), t.Startup.signal.Post("HTML-CSS Jax - using image fonts"), MathJax.Message.Set("Web-Fonts not available -- using image fonts instead", null, 3e3), e.Require(this.directory + "/imageFonts.js", r)) : (this.allowWebFonts = !1, r());
  5194. },
  5195. Element: MathJax.HTML.Element,
  5196. addElement: MathJax.HTML.addElement,
  5197. TextNode: MathJax.HTML.TextNode,
  5198. addText: MathJax.HTML.addText,
  5199. ucMatch: MathJax.HTML.ucMatch,
  5200. BIGDIMEN: 1e7,
  5201. ID: 0,
  5202. idPostfix: "",
  5203. GetID: function() {
  5204. return this.ID++, this.ID;
  5205. },
  5206. MATHSPACE: {
  5207. veryverythinmathspace: 1 / 18,
  5208. verythinmathspace: 2 / 18,
  5209. thinmathspace: 3 / 18,
  5210. mediummathspace: 4 / 18,
  5211. thickmathspace: 5 / 18,
  5212. verythickmathspace: 6 / 18,
  5213. veryverythickmathspace: 7 / 18,
  5214. negativeveryverythinmathspace: -1 / 18,
  5215. negativeverythinmathspace: -2 / 18,
  5216. negativethinmathspace: -3 / 18,
  5217. negativemediummathspace: -4 / 18,
  5218. negativethickmathspace: -5 / 18,
  5219. negativeverythickmathspace: -6 / 18,
  5220. negativeveryverythickmathspace: -7 / 18
  5221. },
  5222. TeX: {
  5223. x_height: .430554,
  5224. quad: 1,
  5225. num1: .676508,
  5226. num2: .393732,
  5227. num3: .44373,
  5228. denom1: .685951,
  5229. denom2: .344841,
  5230. sup1: .412892,
  5231. sup2: .362892,
  5232. sup3: .288888,
  5233. sub1: .15,
  5234. sub2: .247217,
  5235. sup_drop: .386108,
  5236. sub_drop: .05,
  5237. delim1: 2.39,
  5238. delim2: 1,
  5239. axis_height: .25,
  5240. rule_thickness: .06,
  5241. big_op_spacing1: .111111,
  5242. big_op_spacing2: .166666,
  5243. big_op_spacing3: .2,
  5244. big_op_spacing4: .6,
  5245. big_op_spacing5: .1,
  5246. scriptspace: .1,
  5247. nulldelimiterspace: .12,
  5248. delimiterfactor: 901,
  5249. delimitershortfall: .1,
  5250. min_rule_thickness: 1.25
  5251. },
  5252. PLANE1: String.fromCharCode(55349),
  5253. NBSP: String.fromCharCode(160),
  5254. rfuzz: 0
  5255. }), MathJax.Hub.Register.StartupHook("mml Jax Ready", function() {
  5256. r = MathJax.ElementJax.mml, r.mbase.Augment({
  5257. toHTML: function(e) {
  5258. var t = this.HTMLlineBreaks();
  5259. if (t.length > 2) return this.toHTMLmultiline(e, t);
  5260. e = this.HTMLcreateSpan(e), this.type != "mrow" && (e = this.HTMLhandleSize(e));
  5261. for (var n = 0, r = this.data.length; n < r; n++) this.data[n] && this.data[n].toHTML(e);
  5262. var i = this.HTMLcomputeBBox(e), s = e.bbox.h, o = e.bbox.d;
  5263. for (n = 0, r = i.length; n < r; n++) i[n].HTMLstretchV(e, s, o);
  5264. return i.length && this.HTMLcomputeBBox(e, !0), this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5265. },
  5266. HTMLlineBreaks: function() {
  5267. var e = [ [ 0, this ] ];
  5268. for (var t = 0, n = this.data.length; t < n; t++) if (this.data[t]) {
  5269. var r = this.data[t].lineBreak();
  5270. if (r !== "none") {
  5271. var i = r === "after" ? t + 1 : t;
  5272. e.length === 0 || e[e.length - 1] !== i ? e.push([ i, this.data[t] ]) : e[e.length - 1] = [ i, this.data[t] ];
  5273. }
  5274. }
  5275. return e.push([ this.data.length, e[e.length - 1][1] ]), e;
  5276. },
  5277. toHTMLmultiline: function(e) {
  5278. r.mbase.HTMLautoloadFile("multiline");
  5279. },
  5280. HTMLcomputeBBox: function(e, t, n, r) {
  5281. n == null && (n = 0), r == null && (r = this.data.length);
  5282. var i = e.bbox = {}, s = [];
  5283. while (n < r) {
  5284. var o = this.data[n];
  5285. if (!o) continue;
  5286. !t && o.HTMLcanStretch("Vertical") && (s.push(o), o = o.CoreMO() || o), this.HTMLcombineBBoxes(o, i), n++;
  5287. }
  5288. return this.HTMLcleanBBox(i), s;
  5289. },
  5290. HTMLcombineBBoxes: function(e, t) {
  5291. t.w == null && this.HTMLemptyBBox(t);
  5292. var n = e.HTMLspanElement();
  5293. if (!n || !n.bbox) return;
  5294. var r = n.bbox;
  5295. r.d > t.d && (t.d = r.d), r.h > t.h && (t.h = r.h), r.D != null && r.D > t.D && (t.D = r.D), r.H != null && r.H > t.H && (t.H = r.H), n.style.paddingLeft && (t.w += parseFloat(n.style.paddingLeft) * (n.scale || 1)), t.w + r.lw < t.lw && (t.lw = t.w + r.lw), t.w + r.rw > t.rw && (t.rw = t.w + r.rw), t.w += r.w, n.style.paddingRight && (t.w += parseFloat(n.style.paddingRight) * (n.scale || 1)), r.width && (t.width = r.width);
  5296. },
  5297. HTMLemptyBBox: function(e) {
  5298. return e.h = e.d = e.H = e.D = e.rw = -n.BIGDIMEN, e.w = 0, e.lw = n.BIGDIMEN, e;
  5299. },
  5300. HTMLcleanBBox: function(e) {
  5301. e.h === this.BIGDIMEN && (e.h = e.d = e.H = e.D = e.w = e.rw = e.lw = 0), e.D <= e.d && delete e.D, e.H <= e.h && delete e.H;
  5302. },
  5303. HTMLzeroBBox: function() {
  5304. return {
  5305. h: 0,
  5306. d: 0,
  5307. w: 0,
  5308. lw: 0,
  5309. rw: 0
  5310. };
  5311. },
  5312. HTMLcanStretch: function(e) {
  5313. return this.isEmbellished() ? this.Core().HTMLcanStretch(e) : !1;
  5314. },
  5315. HTMLstretchH: function(e, t) {
  5316. return this.HTMLspanElement();
  5317. },
  5318. HTMLstretchV: function(e, t, n) {
  5319. return this.HTMLspanElement();
  5320. },
  5321. HTMLnotEmpty: function(e) {
  5322. while (e) {
  5323. if (e.type !== "mrow" && e.type !== "texatom" || e.data.length > 1) return !0;
  5324. e = e.data[0];
  5325. }
  5326. return !1;
  5327. },
  5328. HTMLmeasureChild: function(e, t) {
  5329. this.data[e] != null ? n.Measured(this.data[e].toHTML(t), t) : t.bbox = this.HTMLzeroBBox();
  5330. },
  5331. HTMLcreateSpan: function(e) {
  5332. if (this.spanID) {
  5333. var t = this.HTMLspanElement();
  5334. if (t) {
  5335. while (t.firstChild) t.removeChild(t.firstChild);
  5336. return t.bbox = {
  5337. w: 0,
  5338. h: 0,
  5339. d: 0,
  5340. lw: 0,
  5341. rw: 0
  5342. }, t.scale = 1, t.isMultChar = null, t.style.cssText = "", t;
  5343. }
  5344. }
  5345. return this.href && (e = n.addElement(e, "a", {
  5346. href: this.href
  5347. })), e = n.addElement(e, "span", {
  5348. className: this.type
  5349. }), n.imgHeightBug && (e.style.display = "inline-block"), this["class"] != null && (e.className += " " + this["class"]), this.style && (e.style.cssText = this.style, e.style.fontSize && (this.mathsize = e.style.fontSize, e.style.fontSize = "")), this.spanID = n.GetID(), e.id = (this.id || "MathJax-Span-" + this.spanID) + n.idPostfix, e.bbox = {
  5350. w: 0,
  5351. h: 0,
  5352. d: 0,
  5353. lw: 0,
  5354. lr: 0
  5355. }, this.href && (e.parentNode.bbox = e.bbox), e;
  5356. },
  5357. HTMLspanElement: function() {
  5358. return this.spanID ? document.getElementById((this.id || "MathJax-Span-" + this.spanID) + n.idPostfix) : null;
  5359. },
  5360. HTMLhandleVariant: function(e, t, r) {
  5361. n.handleVariant(e, t, r);
  5362. },
  5363. HTMLhandleSize: function(e) {
  5364. return e.scale || (e.scale = this.HTMLgetScale(), e.scale !== 1 && (e.style.fontSize = n.Percent(e.scale))), e;
  5365. },
  5366. HTMLhandleColor: function(e) {
  5367. var t = this.getValues("mathcolor", "color");
  5368. this.mathbackground && (t.mathbackground = this.mathbackground), this.background && (t.background = this.background), this.style && e.style.backgroundColor && (t.mathbackground = e.style.backgroundColor, e.style.backgroundColor = "transparent"), t.color && !this.mathcolor && (t.mathcolor = t.color), t.background && !this.mathbackground && (t.mathbackground = t.background), t.mathcolor && (e.style.color = t.mathcolor);
  5369. if (t.mathbackground && t.mathbackground !== r.COLOR.TRANSPARENT) {
  5370. var i = 1 / n.em, s = 0, o = 0;
  5371. this.isToken && (s = e.bbox.lw, o = e.bbox.rw - e.bbox.w), e.style.paddingLeft !== "" && (s += parseFloat(e.style.paddingLeft) * (e.scale || 1)), e.style.paddingRight !== "" && (o -= parseFloat(e.style.paddingRight) * (e.scale || 1));
  5372. var u = Math.max(0, n.getW(e) + (n.PaddingWidthBug ? 0 : o - s));
  5373. n.msieCharPaddingWidthBug && e.style.paddingLeft !== "" && (u += parseFloat(e.style.paddingLeft) * (e.scale || 1));
  5374. var f = e.bbox.h + e.bbox.d, l = -e.bbox.d;
  5375. u > 0 && (u += 2 * i, s -= i), f > 0 && (f += 2 * i, l -= i), o = -u - s;
  5376. var c = n.Element("span", {
  5377. id: "MathJax-Color-" + this.spanID + n.idPostfix,
  5378. style: {
  5379. display: "inline-block",
  5380. backgroundColor: t.mathbackground,
  5381. width: n.Em(u),
  5382. height: n.Em(f),
  5383. verticalAlign: n.Em(l),
  5384. marginLeft: n.Em(s),
  5385. marginRight: n.Em(o)
  5386. }
  5387. });
  5388. return n.msieInlineBlockAlignBug && (c.style.position = "relative", c.style.width = c.style.height = 0, c.style.verticalAlign = c.style.marginLeft = c.style.marginRight = "", n.placeBox(n.addElement(c, "span", {
  5389. noAdjust: !0,
  5390. style: {
  5391. display: "inline-block",
  5392. position: "absolute",
  5393. overflow: "hidden",
  5394. width: n.Em(u),
  5395. height: n.Em(f),
  5396. background: t.mathbackground
  5397. }
  5398. }), s, e.bbox.h + i)), e.parentNode.insertBefore(c, e), n.msieColorPositionBug && (e.style.position = "relative"), c;
  5399. }
  5400. return null;
  5401. },
  5402. HTMLremoveColor: function() {
  5403. var e = document.getElementById("MathJax-Color-" + this.spanID + n.idPostfix);
  5404. e && e.parentNode.removeChild(e);
  5405. },
  5406. HTMLhandleSpace: function(e) {
  5407. if (this.useMMLspacing) {
  5408. if (this.type !== "mo") return;
  5409. var t = this.getValues("scriptlevel", "lspace", "rspace");
  5410. if (t.scriptlevel <= 0 || this.hasValue("lspace") || this.hasValue("rspace")) {
  5411. t.lspace = Math.max(0, n.length2em(t.lspace)), t.rspace = Math.max(0, n.length2em(t.rspace));
  5412. var r = this, i = this.Parent();
  5413. while (i && i.isEmbellished() && i.Core() === r) r = i, i = i.Parent(), e = r.HTMLspanElement();
  5414. t.lspace && (e.style.paddingLeft = n.Em(t.lspace)), t.rspace && (e.style.paddingRight = n.Em(t.rspace));
  5415. }
  5416. } else {
  5417. var s = this.texSpacing();
  5418. s !== "" && (s = n.length2em(s) / (e.scale || 1), e.style.paddingLeft && (s += parseFloat(e.style.paddingLeft)), e.style.paddingLeft = n.Em(s));
  5419. }
  5420. },
  5421. HTMLgetScale: function() {
  5422. var e = 1, t = this.getValues("mathsize", "scriptlevel", "fontsize", "scriptminsize");
  5423. if (this.style) {
  5424. var r = this.HTMLspanElement();
  5425. r.style.fontSize != "" && (t.fontsize = r.style.fontSize);
  5426. }
  5427. return t.fontsize && !this.mathsize && (t.mathsize = t.fontsize), t.scriptlevel !== 0 && (t.scriptlevel > 2 && (t.scriptlevel = 2), e = Math.pow(this.Get("scriptsizemultiplier"), t.scriptlevel), t.scriptminsize = n.length2em(t.scriptminsize), e < t.scriptminsize && (e = t.scriptminsize)), e *= n.length2em(t.mathsize), e;
  5428. },
  5429. HTMLgetVariant: function() {
  5430. var e = this.getValues("mathvariant", "fontfamily", "fontweight", "fontstyle");
  5431. if (this.style) {
  5432. var t = this.HTMLspanElement();
  5433. t.style.fontFamily && (e.fontfamily = t.style.fontFamily), t.style.fontWeight && (e.fontweight = t.style.fontWeight), t.style.fontStyle && (e.fontStyle = t.style.fontStyle);
  5434. }
  5435. var i = e.mathvariant;
  5436. return this.variantForm && (i = "-" + n.fontInUse + "-variant"), e.fontfamily && !this.mathvariant ? (!e.fontweight && e.mathvariant.match(/bold/) && (e.fontweight = "bold"), !e.fontstyle && e.mathvariant.match(/italic/) && (e.fontstyle = "italic"), {
  5437. FONTS: [],
  5438. fonts: [],
  5439. noRemap: !0,
  5440. defaultFont: {
  5441. family: e.fontfamily,
  5442. style: e.fontstyle,
  5443. weight: e.fontweight
  5444. }
  5445. }) : (e.fontweight === "bold" ? i = {
  5446. normal: r.VARIANT.BOLD,
  5447. italic: r.VARIANT.BOLDITALIC,
  5448. fraktur: r.VARIANT.BOLDFRAKTUR,
  5449. script: r.VARIANT.BOLDSCRIPT,
  5450. "sans-serif": r.VARIANT.BOLDSANSSERIF,
  5451. "sans-serif-italic": r.VARIANT.SANSSERIFBOLDITALIC
  5452. }[i] || i : e.fontweight === "normal" && (i = {
  5453. bold: r.VARIANT.normal,
  5454. "bold-italic": r.VARIANT.ITALIC,
  5455. "bold-fraktur": r.VARIANT.FRAKTUR,
  5456. "bold-script": r.VARIANT.SCRIPT,
  5457. "bold-sans-serif": r.VARIANT.SANSSERIF,
  5458. "sans-serif-bold-italic": r.VARIANT.SANSSERIFITALIC
  5459. }[i] || i), e.fontstyle === "italic" ? i = {
  5460. normal: r.VARIANT.ITALIC,
  5461. bold: r.VARIANT.BOLDITALIC,
  5462. "sans-serif": r.VARIANT.SANSSERIFITALIC,
  5463. "bold-sans-serif": r.VARIANT.SANSSERIFBOLDITALIC
  5464. }[i] || i : e.fontstyle === "normal" && (i = {
  5465. italic: r.VARIANT.NORMAL,
  5466. "bold-italic": r.VARIANT.BOLD,
  5467. "sans-serif-italic": r.VARIANT.SANSSERIF,
  5468. "sans-serif-bold-italic": r.VARIANT.BOLDSANSSERIF
  5469. }[i] || i), n.FONTDATA.VARIANT[i]);
  5470. }
  5471. }, {
  5472. HTMLautoload: function() {
  5473. var r = n.autoloadDir + "/" + this.type + ".js";
  5474. t.RestartAfter(e.Require(r));
  5475. },
  5476. HTMLautoloadFile: function(r) {
  5477. var i = n.autoloadDir + "/" + r + ".js";
  5478. t.RestartAfter(e.Require(i));
  5479. },
  5480. HTMLstretchH: function(e, t) {
  5481. return this.HTMLremoveColor(), this.toHTML(e, t);
  5482. },
  5483. HTMLstretchV: function(e, t, n) {
  5484. return this.HTMLremoveColor(), this.toHTML(e, t, n);
  5485. }
  5486. }), r.chars.Augment({
  5487. toHTML: function(e, t) {
  5488. this.HTMLhandleVariant(e, t, this.data.join("").replace(/[\u2061-\u2064]/g, ""));
  5489. }
  5490. }), r.entity.Augment({
  5491. toHTML: function(e, t) {
  5492. this.HTMLhandleVariant(e, t, this.toString().replace(/[\u2061-\u2064]/g, ""));
  5493. }
  5494. }), r.mi.Augment({
  5495. toHTML: function(e) {
  5496. e = this.HTMLhandleSize(this.HTMLcreateSpan(e)), e.bbox = null;
  5497. var t = this.HTMLgetVariant();
  5498. for (var n = 0, r = this.data.length; n < r; n++) this.data[n] && this.data[n].toHTML(e, t);
  5499. return e.bbox || (e.bbox = {
  5500. w: 0,
  5501. h: 0,
  5502. d: 0,
  5503. rw: 0,
  5504. lw: 0
  5505. }), this.data.join("").length !== 1 && delete e.bbox.skew, this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5506. }
  5507. }), r.mn.Augment({
  5508. toHTML: function(e) {
  5509. e = this.HTMLhandleSize(this.HTMLcreateSpan(e)), e.bbox = null;
  5510. var t = this.HTMLgetVariant();
  5511. for (var n = 0, r = this.data.length; n < r; n++) this.data[n] && this.data[n].toHTML(e, t);
  5512. return e.bbox || (e.bbox = {
  5513. w: 0,
  5514. h: 0,
  5515. d: 0,
  5516. rw: 0,
  5517. lw: 0
  5518. }), this.data.join("").length !== 1 && delete e.bbox.skew, this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5519. }
  5520. }), r.mo.Augment({
  5521. toHTML: function(e) {
  5522. e = this.HTMLhandleSize(this.HTMLcreateSpan(e));
  5523. if (this.data.length == 0) return e;
  5524. e.bbox = null;
  5525. var t = this.data.join(""), r = this.HTMLgetVariant(), i = this.getValues("largeop", "displaystyle");
  5526. i.largeop && (r = n.FONTDATA.VARIANT[i.displaystyle ? "-largeOp" : "-smallOp"]);
  5527. for (var s = 0, o = this.data.length; s < o; s++) this.data[s] && this.data[s].toHTML(e, r);
  5528. e.bbox || (e.bbox = {
  5529. w: 0,
  5530. h: 0,
  5531. d: 0,
  5532. rw: 0,
  5533. lw: 0
  5534. }), t.length !== 1 && delete e.bbox.skew, n.AccentBug && e.bbox.w === 0 && t.length === 1 && e.firstChild && (e.firstChild.nodeValue += n.NBSP, n.createSpace(e, 0, 0, -e.offsetWidth / n.em));
  5535. if (i.largeop) {
  5536. var u = (e.bbox.h - e.bbox.d) / 2 - n.TeX.axis_height * e.scale;
  5537. n.safariVerticalAlignBug && e.lastChild.nodeName === "IMG" ? e.lastChild.style.verticalAlign = n.Em(parseFloat(e.lastChild.style.verticalAlign || 0) / n.em - u / e.scale) : n.konquerorVerticalAlignBug && e.lastChild.nodeName === "IMG" ? (e.style.position = "relative", e.lastChild.style.position = "relative", e.lastChild.style.top = n.Em(u / e.scale)) : e.style.verticalAlign = n.Em(-u / e.scale), e.bbox.h -= u, e.bbox.d += u, e.bbox.rw > e.bbox.w && (e.bbox.ic = e.bbox.rw - e.bbox.w, n.createBlank(e, e.bbox.ic), e.bbox.w = e.bbox.rw);
  5538. }
  5539. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5540. },
  5541. HTMLcanStretch: function(e) {
  5542. if (!this.Get("stretchy")) return !1;
  5543. var t = this.data.join("");
  5544. return t.length > 1 ? !1 : (t = n.FONTDATA.DELIMITERS[t.charCodeAt(0)], t && t.dir == e.substr(0, 1));
  5545. },
  5546. HTMLstretchV: function(e, t, r) {
  5547. this.HTMLremoveColor();
  5548. var i = this.getValues("symmetric", "maxsize", "minsize"), s = this.HTMLspanElement(), o, u = n.TeX.axis_height, a = s.scale;
  5549. return i.symmetric ? o = 2 * Math.max(t - u, r + u) : o = t + r, i.maxsize = n.length2em(i.maxsize, s.bbox.h + s.bbox.d), i.minsize = n.length2em(i.minsize, s.bbox.h + s.bbox.d), o = Math.max(i.minsize, Math.min(i.maxsize, o)), s = this.HTMLcreateSpan(e), n.createDelimiter(s, this.data.join("").charCodeAt(0), o, a), i.symmetric ? o = (s.bbox.h + s.bbox.d) / 2 + u : o = (s.bbox.h + s.bbox.d) * t / (t + r), n.positionDelimiter(s, o), this.HTMLhandleSpace(s), this.HTMLhandleColor(s), s;
  5550. },
  5551. HTMLstretchH: function(e, t) {
  5552. this.HTMLremoveColor();
  5553. var i = this.getValues("maxsize", "minsize", "mathvariant", "fontweight");
  5554. i.fontweight === "bold" && !this.mathvariant && (i.mathvariant = r.VARIANT.BOLD);
  5555. var s = this.HTMLspanElement(), o = s.scale;
  5556. return i.maxsize = n.length2em(i.maxsize, s.bbox.w), i.minsize = n.length2em(i.minsize, s.bbox.w), t = Math.max(i.minsize, Math.min(i.maxsize, t)), s = this.HTMLcreateSpan(e), n.createDelimiter(s, this.data.join("").charCodeAt(0), t, o, i.mathvariant), this.HTMLhandleSpace(s), this.HTMLhandleColor(s), s;
  5557. }
  5558. }), r.mtext.Augment({
  5559. toHTML: function(e) {
  5560. e = this.HTMLhandleSize(this.HTMLcreateSpan(e)), e.bbox = null;
  5561. if (this.Parent().type === "merror") {
  5562. n.addText(e, this.data.join(""));
  5563. var t = n.getHD(e), r = n.getW(e);
  5564. e.bbox = {
  5565. h: t.h,
  5566. d: t.d,
  5567. w: r,
  5568. lw: 0,
  5569. rw: r
  5570. };
  5571. } else {
  5572. var i = this.HTMLgetVariant();
  5573. for (var s = 0, o = this.data.length; s < o; s++) this.data[s] && this.data[s].toHTML(e, i);
  5574. e.bbox || (e.bbox = {
  5575. w: 0,
  5576. h: 0,
  5577. d: 0,
  5578. rw: 0,
  5579. lw: 0
  5580. }), this.data.join("").length !== 1 && delete e.bbox.skew;
  5581. }
  5582. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5583. }
  5584. }), r.ms.Augment({
  5585. toHTML: r.mbase.HTMLautoload
  5586. }), r.mglyph.Augment({
  5587. toHTML: r.mbase.HTMLautoload
  5588. }), r.mspace.Augment({
  5589. toHTML: function(e) {
  5590. e = this.HTMLhandleSize(this.HTMLcreateSpan(e));
  5591. var t = this.getValues("height", "depth", "width");
  5592. t.mathbackground = this.mathbackground, this.background && !this.mathbackground && (t.mathbackground = this.background);
  5593. var r = n.length2em(t.height), i = n.length2em(t.depth), s = n.length2em(t.width);
  5594. return n.createSpace(e, r, i, s, t.mathbackground), e;
  5595. }
  5596. }), r.mphantom.Augment({
  5597. toHTML: function(e, t, r) {
  5598. e = this.HTMLcreateSpan(e);
  5599. if (this.data[0] != null) {
  5600. var i = n.Measured(this.data[0].toHTML(e), e);
  5601. r != null ? n.Remeasured(this.data[0].HTMLstretchV(e, t, r), e) : t != null && n.Remeasured(this.data[0].HTMLstretchH(e, t), e), e.bbox = {
  5602. w: i.bbox.w,
  5603. h: i.bbox.h,
  5604. d: i.bbox.d,
  5605. lw: 0,
  5606. rw: 0
  5607. };
  5608. for (var s = 0, o = e.childNodes.length; s < o; s++) e.childNodes[s].style.visibility = "hidden";
  5609. }
  5610. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5611. },
  5612. HTMLstretchH: r.mbase.HTMLstretchH,
  5613. HTMLstretchV: r.mbase.HTMLstretchV
  5614. }), r.mpadded.Augment({
  5615. toHTML: function(e, t, r) {
  5616. e = this.HTMLcreateSpan(e);
  5617. if (this.data[0] != null) {
  5618. var i = n.createStack(e, !0), s = n.createBox(i);
  5619. n.Measured(this.data[0].toHTML(s), s), r != null ? n.Remeasured(this.data[0].HTMLstretchV(s, t, r), s) : t != null && n.Remeasured(this.data[0].HTMLstretchH(s, t), s);
  5620. var o = this.getValues("height", "depth", "width", "lspace", "voffset"), u = 0, a = 0;
  5621. o.lspace && (u = this.HTMLlength2em(s, o.lspace)), o.voffset && (a = this.HTMLlength2em(s, o.voffset)), n.placeBox(s, u, a), e.bbox = {
  5622. h: s.bbox.h,
  5623. d: s.bbox.d,
  5624. w: s.bbox.w,
  5625. lw: Math.min(0, s.bbox.lw + u),
  5626. rw: Math.max(s.bbox.w, s.bbox.rw + u),
  5627. H: Math.max(s.bbox.H == null ? -n.BIGDIMEN : s.bbox.H, s.bbox.h + a),
  5628. D: Math.max(s.bbox.D == null ? -n.BIGDIMEN : s.bbox.D, s.bbox.d - a)
  5629. }, o.height !== "" && (e.bbox.h = this.HTMLlength2em(s, o.height, "h", 0)), o.depth !== "" && (e.bbox.d = this.HTMLlength2em(s, o.depth, "d", 0)), o.width !== "" && (e.bbox.w = this.HTMLlength2em(s, o.width, "w", 0)), e.bbox.H <= e.bbox.h && delete e.bbox.H, e.bbox.D <= e.bbox.d && delete e.bbox.D, n.setStackWidth(i, e.bbox.w);
  5630. }
  5631. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5632. },
  5633. HTMLlength2em: function(e, t, r, i) {
  5634. i == null && (i = -n.BIGDIMEN);
  5635. var s = String(t).match(/width|height|depth/), o = s ? e.bbox[s[0].charAt(0)] : r ? e.bbox[r] : null, u = n.length2em(t, o);
  5636. return r && String(t).match(/^\s*[-+]/) ? Math.max(i, e.bbox[r] + u) : u;
  5637. },
  5638. HTMLstretchH: r.mbase.HTMLstretchH,
  5639. HTMLstretchV: r.mbase.HTMLstretchV
  5640. }), r.mrow.Augment({
  5641. HTMLstretchH: function(e, t) {
  5642. this.HTMLremoveColor();
  5643. var n = this.HTMLspanElement();
  5644. return this.data[this.core].HTMLstretchH(n, t), this.HTMLcomputeBBox(n, !0), this.HTMLhandleColor(n), n;
  5645. },
  5646. HTMLstretchV: function(e, t, n) {
  5647. this.HTMLremoveColor();
  5648. var r = this.HTMLspanElement();
  5649. return this.data[this.core].HTMLstretchV(r, t, n), this.HTMLcomputeBBox(r, !0), this.HTMLhandleColor(r), r;
  5650. }
  5651. }), r.mstyle.Augment({
  5652. toHTML: function(e) {
  5653. return this.data[0] != null && (e = this.data[0].toHTML(e), this.spanID = this.data[0].spanID, this.HTMLhandleSpace(e), this.HTMLhandleColor(e)), e;
  5654. },
  5655. HTMLspanElement: function() {
  5656. return this.data[0] != null ? this.data[0].HTMLspanElement() : null;
  5657. },
  5658. HTMLstretchH: function(e, t) {
  5659. return this.data[0] != null ? this.data[0].HTMLstretchH(e, t) : e;
  5660. },
  5661. HTMLstretchV: function(e, t, n) {
  5662. return this.data[0] != null ? this.data[0].HTMLstretchV(e, t, n) : e;
  5663. }
  5664. }), r.mfrac.Augment({
  5665. toHTML: function(e) {
  5666. e = this.HTMLcreateSpan(e);
  5667. var t = n.createStack(e), r = n.createBox(t), i = n.createBox(t);
  5668. this.HTMLmeasureChild(0, r), this.HTMLmeasureChild(1, i);
  5669. var s = this.getValues("displaystyle", "linethickness", "numalign", "denomalign", "bevelled"), o = this.HTMLgetScale(), u = s.displaystyle, a = n.TeX.axis_height * o;
  5670. if (s.bevelled) {
  5671. var f = u ? .4 : .15, l = Math.max(r.bbox.h + r.bbox.d, i.bbox.h + i.bbox.d) + 2 * f, c = n.createBox(t);
  5672. n.createDelimiter(c, 47, l), n.placeBox(r, 0, (r.bbox.d - r.bbox.h) / 2 + a + f), n.placeBox(c, r.bbox.w - f / 2, (c.bbox.d - c.bbox.h) / 2 + a), n.placeBox(i, r.bbox.w + c.bbox.w - f, (i.bbox.d - i.bbox.h) / 2 + a - f);
  5673. } else {
  5674. var h = Math.max(r.bbox.w, i.bbox.w), p = n.thickness2em(s.linethickness), d, v, m, g, y = n.TeX.min_rule_thickness / this.em;
  5675. u ? (m = n.TeX.num1, g = n.TeX.denom1) : (m = p === 0 ? n.TeX.num3 : n.TeX.num2, g = n.TeX.denom2), m *= o, g *= o;
  5676. if (p === 0) d = Math.max((u ? 7 : 3) * n.TeX.rule_thickness, 2 * y), v = m - r.bbox.d - (i.bbox.h - g), v < d && (m += (d - v) / 2, g += (d - v) / 2); else {
  5677. d = Math.max((u ? 2 : 0) * y + p, p / 2 + 1.5 * y), v = m - r.bbox.d - (a + p / 2), v < d && (m += d - v), v = a - p / 2 - (i.bbox.h - g), v < d && (g += d - v);
  5678. var b = n.createBox(t);
  5679. n.createRule(b, p, 0, h + 2 * p), n.placeBox(b, 0, a - p / 2);
  5680. }
  5681. n.alignBox(r, s.numalign, m), n.alignBox(i, s.denomalign, -g);
  5682. }
  5683. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5684. },
  5685. HTMLcanStretch: function(e) {
  5686. return !1;
  5687. },
  5688. HTMLhandleSpace: function(e) {
  5689. if (!this.texWithDelims) {
  5690. var t = (this.useMMLspacing ? 0 : n.length2em(this.texSpacing() || 0)) + .12;
  5691. e.style.paddingLeft = n.Em(t), e.style.paddingRight = ".12em";
  5692. }
  5693. }
  5694. }), r.msqrt.Augment({
  5695. toHTML: function(e) {
  5696. e = this.HTMLcreateSpan(e);
  5697. var t = n.createStack(e), r = n.createBox(t), i = n.createBox(t), s = n.createBox(t);
  5698. this.HTMLmeasureChild(0, r);
  5699. var o = this.HTMLgetScale(), u = n.TeX.rule_thickness * o, a, f, l, c;
  5700. this.Get("displaystyle") ? a = n.TeX.x_height * o : a = u, f = Math.max(u + a / 4, 1.5 * n.TeX.min_rule_thickness / this.em), l = r.bbox.h + r.bbox.d + f + u, c = r.bbox.w, n.createDelimiter(s, 8730, l, o), n.Measured(s);
  5701. var h = 0;
  5702. if (s.isMultiChar || n.AdjustSurd && n.imgFonts) s.bbox.w *= .95;
  5703. s.bbox.h + s.bbox.d > l && (f = (s.bbox.h + s.bbox.d - (l - u)) / 2);
  5704. var p = n.FONTDATA.DELIMITERS[n.FONTDATA.RULECHAR];
  5705. return !p || c < p.HW[0][0] * o || o < .75 ? n.createRule(i, u, 0, c) : n.createDelimiter(i, n.FONTDATA.RULECHAR, c, o), l = r.bbox.h + f + u, h = this.HTMLaddRoot(t, s, h, s.bbox.h + s.bbox.d - l, o), n.placeBox(s, h, l - s.bbox.h), n.placeBox(i, h + s.bbox.w, l - i.bbox.h + n.rfuzz), n.placeBox(r, h + s.bbox.w, 0), this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5706. },
  5707. HTMLaddRoot: function(e, t, n, r, i) {
  5708. return n;
  5709. }
  5710. }), r.mroot.Augment({
  5711. toHTML: r.msqrt.prototype.toHTML,
  5712. HTMLaddRoot: function(e, t, r, i, s) {
  5713. var o = n.createBox(e);
  5714. if (this.data[1]) {
  5715. var u = this.data[1].toHTML(o);
  5716. u.style.paddingRight = u.style.paddingLeft = "", n.Measured(u, o);
  5717. } else o.bbox = this.HTMLzeroBBox();
  5718. var a = this.HTMLrootHeight(t.bbox.h + t.bbox.d, s, o) - i, f = Math.min(o.bbox.w, o.bbox.rw);
  5719. return r = Math.max(f, t.offset), n.placeBox(o, r - f, a), r - t.offset;
  5720. },
  5721. HTMLrootHeight: function(e, t, n) {
  5722. return .45 * (e - .9 * t) + .6 * t + Math.max(0, n.bbox.d - .075);
  5723. }
  5724. }), r.mfenced.Augment({
  5725. toHTML: function(e) {
  5726. e = this.HTMLcreateSpan(e), this.data.open && this.data.open.toHTML(e), this.data[0] != null && this.data[0].toHTML(e);
  5727. for (var t = 1, n = this.data.length; t < n; t++) this.data[t] && (this.data["sep" + t] && this.data["sep" + t].toHTML(e), this.data[t].toHTML(e));
  5728. this.data.close && this.data.close.toHTML(e);
  5729. var r = this.HTMLcomputeBBox(e), i = e.bbox.h, s = e.bbox.d;
  5730. for (t = 0, n = r.length; t < n; t++) r[t].HTMLstretchV(e, i, s);
  5731. return r.length && this.HTMLcomputeBBox(e, !0), this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5732. },
  5733. HTMLcomputeBBox: function(e, t) {
  5734. var n = e.bbox = {}, r = [];
  5735. this.HTMLcheckStretchy(this.data.open, n, r, t), this.HTMLcheckStretchy(this.data[0], n, r, t);
  5736. for (var i = 1, s = this.data.length; i < s; i++) this.data[i] && (this.HTMLcheckStretchy(this.data["sep" + i], n, r, t), this.HTMLcheckStretchy(this.data[i], n, r, t));
  5737. return this.HTMLcheckStretchy(this.data.close, n, r, t), this.HTMLcleanBBox(n), r;
  5738. },
  5739. HTMLcheckStretchy: function(e, t, n, r) {
  5740. e && (!r && e.HTMLcanStretch("Vertical") && (n.push(e), e = e.CoreMO() || e), this.HTMLcombineBBoxes(e, t));
  5741. }
  5742. }), r.menclose.Augment({
  5743. toHTML: r.mbase.HTMLautoload
  5744. }), r.maction.Augment({
  5745. toHTML: r.mbase.HTMLautoload
  5746. }), r.semantics.Augment({
  5747. toHTML: function(e) {
  5748. return this.data[0] != null && (e = this.data[0].toHTML(e), this.spanID = this.data[0].spanID, this.HTMLhandleSpace(e)), e;
  5749. },
  5750. HTMLspanElement: function() {
  5751. return this.data[0] != null ? this.data[0].HTMLspanElement() : null;
  5752. },
  5753. HTMLstretchH: function(e, t) {
  5754. return this.data[0] != null ? this.data[0].HTMLstretchH(e, t) : e;
  5755. },
  5756. HTMLstretchV: function(e, t, n) {
  5757. return this.data[0] != null ? this.data[0].HTMLstretchV(e, t, n) : e;
  5758. }
  5759. }), r.munderover.Augment({
  5760. toHTML: function(e, t, i) {
  5761. var s = this.getValues("displaystyle", "accent", "accentunder", "align");
  5762. if (!s.displaystyle && this.data[this.base] != null && this.data[this.base].Get("movablelimits")) return r.msubsup.prototype.toHTML.call(this, e);
  5763. e = this.HTMLcreateSpan(e);
  5764. var o = this.HTMLgetScale(), u = n.createStack(e), f = [], l = [], c, h, p, d = -n.BIGDIMEN, v = d;
  5765. for (h = 0, p = this.data.length; h < p; h++) this.data[h] != null && (c = f[h] = n.createBox(u), n.Measured(this.data[h].toHTML(c), c), h == this.base ? (i != null ? n.Remeasured(this.data[this.base].HTMLstretchV(c, t, i), c) : t != null && n.Remeasured(this.data[this.base].HTMLstretchH(c, t), c), l[h] = i == null && t != null ? !1 : this.data[h].HTMLcanStretch("Horizontal")) : l[h] = this.data[h].HTMLcanStretch("Horizontal"), c.bbox.w > v && (v = c.bbox.w), !l[h] && v > d && (d = v));
  5766. i == null && t != null ? d = t : d == -n.BIGDIMEN && (d = v);
  5767. for (h = v = 0, p = this.data.length; h < p; h++) this.data[h] && (c = f[h], l[h] && (c.bbox = this.data[h].HTMLstretchH(c, d).bbox), c.bbox.w > v && (v = c.bbox.w));
  5768. var m = n.TeX.rule_thickness, g = n.FONTDATA.TeX_factor, y = f[this.base] || {
  5769. bbox: this.HTMLzeroBBox()
  5770. }, b = y.bbox.ic || 0, w, E, S, x, T, N, C;
  5771. for (h = 0, p = this.data.length; h < p; h++) if (this.data[h] != null) {
  5772. c = f[h], T = n.TeX.big_op_spacing5 * o;
  5773. var k = h != this.base && s[this.ACCENTS[h]];
  5774. k && c.bbox.w <= 1 / n.em + 1e-4 && (c.bbox.w = c.bbox.rw - c.bbox.lw, c.bbox.noclip = !0, c.bbox.lw && !n.zeroWidthBug && c.insertBefore(n.createSpace(c.parentNode, 0, 0, -c.bbox.lw), c.firstChild), n.createBlank(c, 0, 0, c.bbox.rw + .1)), N = {
  5775. left: 0,
  5776. center: (v - c.bbox.w) / 2,
  5777. right: v - c.bbox.w
  5778. }[s.align], w = N, E = 0, h == this.over ? (k ? (C = Math.max(m * o * g, 2.5 / this.em), T = 0, y.bbox.skew && (w += y.bbox.skew)) : (S = n.TeX.big_op_spacing1 * o * g, x = n.TeX.big_op_spacing3 * o * g, C = Math.max(S, x - Math.max(0, c.bbox.d))), C = Math.max(C, 1.5 / this.em), w += b, E = y.bbox.h + c.bbox.d + C, c.bbox.h += T) : h == this.under && (k ? (C = 3 * m * o * g, T = 0) : (S = n.TeX.big_op_spacing2 * o * g, x = n.TeX.big_op_spacing4 * o * g, C = Math.max(S, x - c.bbox.h)), C = Math.max(C, 1.5 / this.em), w -= b, E = -(y.bbox.d + c.bbox.h + C), c.bbox.d += T), n.placeBox(c, w, E);
  5779. }
  5780. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5781. },
  5782. HTMLstretchH: r.mbase.HTMLstretchH,
  5783. HTMLstretchV: r.mbase.HTMLstretchV
  5784. }), r.msubsup.Augment({
  5785. toHTML: function(e, t, r) {
  5786. e = this.HTMLcreateSpan(e);
  5787. var i = this.HTMLgetScale(), s = n.createStack(e), o, u = n.createBox(s);
  5788. this.HTMLmeasureChild(this.base, u), this.data[this.base] && (r != null ? n.Remeasured(this.data[this.base].HTMLstretchV(u, t, r), u) : t != null && n.Remeasured(this.data[this.base].HTMLstretchH(u, t), u)), n.placeBox(u, 0, 0);
  5789. var a = (this.data[this.sup] || this.data[this.sub] || this).HTMLgetScale(), f = n.TeX.x_height * i, l = n.TeX.scriptspace * i * .75, c, h;
  5790. this.HTMLnotEmpty(this.data[this.sup]) && (c = n.createBox(s), n.Measured(this.data[this.sup].toHTML(c), c), c.bbox.w += l, c.bbox.rw = Math.max(c.bbox.w, c.bbox.rw)), this.HTMLnotEmpty(this.data[this.sub]) && (h = n.createBox(s), n.Measured(this.data[this.sub].toHTML(h), h), h.bbox.w += l, h.bbox.rw = Math.max(h.bbox.w, h.bbox.rw));
  5791. var p = n.TeX.sup_drop * a, d = n.TeX.sub_drop * a, v = u.bbox.h - p, m = u.bbox.d + d, g = 0, y;
  5792. u.bbox.ic && (g = u.bbox.ic), this.data[this.base] && (this.data[this.base].type === "mi" || this.data[this.base].type === "mo") && this.data[this.base].data.join("").length === 1 && u.bbox.scale === 1 && !this.data[this.base].Get("largeop") && (v = m = 0);
  5793. var b = this.getValues("subscriptshift", "superscriptshift");
  5794. b.subscriptshift = b.subscriptshift === "" ? 0 : n.length2em(b.subscriptshift), b.superscriptshift = b.superscriptshift === "" ? 0 : n.length2em(b.superscriptshift);
  5795. if (!c) h && (m = Math.max(m, n.TeX.sub1 * i, h.bbox.h - .8 * f, b.subscriptshift), n.placeBox(h, u.bbox.w + l - g, -m, h.bbox)); else if (!h) o = this.getValues("displaystyle", "texprimestyle"), y = n.TeX[o.displaystyle ? "sup1" : o.texprimestyle ? "sup3" : "sup2"], v = Math.max(v, y * i, c.bbox.d + .25 * f, b.superscriptshift), n.placeBox(c, u.bbox.w + l, v, c.bbox); else {
  5796. m = Math.max(m, n.TeX.sub2 * i);
  5797. var w = n.TeX.rule_thickness * i;
  5798. v - c.bbox.d - (h.bbox.h - m) < 3 * w && (m = 3 * w - v + c.bbox.d + h.bbox.h, p = .8 * f - (v - c.bbox.d), p > 0 && (v += p, m -= p)), n.placeBox(c, u.bbox.w + l, Math.max(v, b.superscriptshift)), n.placeBox(h, u.bbox.w + l - g, -Math.max(m, b.subscriptshift));
  5799. }
  5800. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5801. },
  5802. HTMLstretchH: r.mbase.HTMLstretchH,
  5803. HTMLstretchV: r.mbase.HTMLstretchV
  5804. }), r.mmultiscripts.Augment({
  5805. toHTML: r.mbase.HTMLautoload
  5806. }), r.mtable.Augment({
  5807. toHTML: r.mbase.HTMLautoload
  5808. }), r["annotation-xml"].Augment({
  5809. toHTML: r.mbase.HTMLautoload
  5810. }), r.math.Augment({
  5811. toHTML: function(e, i) {
  5812. var s = this.Get("alttext");
  5813. s && i.setAttribute("aria-label", s);
  5814. var o = n.addElement(e, "nobr");
  5815. e = this.HTMLcreateSpan(o);
  5816. var u = n.createStack(e), f = n.createBox(u), l;
  5817. u.style.fontSize = o.parentNode.style.fontSize, o.parentNode.style.fontSize = "", this.data[0] != null && (n.msieColorBug && (this.background && (this.data[0].background = this.background, delete this.background), this.mathbackground && (this.data[0].mathbackground = this.mathbackground, delete this.mathbackground)), r.mbase.prototype.displayAlign = t.config.displayAlign, r.mbase.prototype.displayIndent = t.config.displayIndent, l = n.Measured(this.data[0].toHTML(f), f)), n.placeBox(f, 0, 0);
  5818. var c = n.em / n.outerEm;
  5819. n.em /= c, e.bbox.h *= c, e.bbox.d *= c, e.bbox.w *= c, e.bbox.lw *= c, e.bbox.rw *= c, l && l.bbox.width != null && (u.style.width = l.bbox.width, f.style.width = "100%"), this.HTMLhandleColor(e), l && n.createRule(e, l.bbox.h * c, l.bbox.d * c, 0);
  5820. if (!this.isMultiline && this.Get("display") === "block" && e.bbox.width == null) {
  5821. var h = this.getValues("indentalignfirst", "indentshiftfirst", "indentalign", "indentshift");
  5822. h.indentalignfirst !== r.INDENTALIGN.INDENTALIGN && (h.indentalign = h.indentalignfirst), h.indentalign === r.INDENTALIGN.AUTO && (h.indentalign = this.displayAlign), i.style.textAlign = h.indentalign, h.indentshiftfirst !== r.INDENTSHIFT.INDENTSHIFT && (h.indentshift = h.indentshiftfirst), h.indentshift === "auto" && (h.indentshift = this.displayIndent), h.indentshift && h.indentalign !== r.INDENTALIGN.CENTER && (e.style[{
  5823. left: "marginLeft",
  5824. right: "marginRight"
  5825. }[h.indentalign]] = n.Em(n.length2em(h.indentshift)));
  5826. }
  5827. return e;
  5828. }
  5829. }), r.TeXAtom.Augment({
  5830. toHTML: function(e) {
  5831. e = this.HTMLcreateSpan(e);
  5832. if (this.data[0] != null) if (this.texClass === r.TEXCLASS.VCENTER) {
  5833. var t = n.createStack(e), i = n.createBox(t);
  5834. n.Measured(this.data[0].toHTML(i), i), n.placeBox(i, 0, n.TeX.axis_height - (i.bbox.h + i.bbox.d) / 2 + i.bbox.d);
  5835. } else e.bbox = this.data[0].toHTML(e).bbox;
  5836. return this.HTMLhandleSpace(e), this.HTMLhandleColor(e), e;
  5837. }
  5838. }), MathJax.Hub.Register.StartupHook("onLoad", function() {
  5839. setTimeout(MathJax.Callback([ "loadComplete", n, "jax.js" ]), 0);
  5840. });
  5841. }), t.Register.StartupHook("End Config", function() {
  5842. t.Browser.Select({
  5843. MSIE: function(e) {
  5844. var t = e.versionAtLeast("7.0"), r = e.versionAtLeast("8.0") && document.documentMode > 7, i = document.compatMode === "BackCompat";
  5845. n.config.styles[".MathJax .MathJax_HitBox"]["background-color"] = "white", n.config.styles[".MathJax .MathJax_HitBox"].opacity = 0, n.config.styles[".MathJax .MathJax_HitBox"].filter = "alpha(opacity=0)", n.Augment({
  5846. getMarginScale: n.getMSIEmarginScale,
  5847. PaddingWidthBug: !0,
  5848. msieEventBug: e.isIE9,
  5849. msieAccentBug: !0,
  5850. msieColorBug: !0,
  5851. msieColorPositionBug: !0,
  5852. msieRelativeWidthBug: i,
  5853. msieMarginWidthBug: !0,
  5854. msiePaddingWidthBug: !0,
  5855. msieCharPaddingWidthBug: r && !i,
  5856. msieBorderWidthBug: i,
  5857. msieInlineBlockAlignBug: !r || i,
  5858. msieVerticalAlignBug: r && !i,
  5859. msiePlaceBoxBug: r && !i,
  5860. msieClipRectBug: !r,
  5861. msieNegativeSpaceBug: i,
  5862. msieCloneNodeBug: r && e.version === "8.0",
  5863. negativeSkipBug: !0,
  5864. msieIE6: !t,
  5865. msieItalicWidthBug: !0,
  5866. zeroWidthBug: !0,
  5867. FontFaceBug: !0,
  5868. msieFontCSSBug: e.isIE9,
  5869. allowWebFonts: "eot"
  5870. });
  5871. },
  5872. Firefox: function(e) {
  5873. var r = !1;
  5874. if (e.versionAtLeast("3.5")) {
  5875. var i = String(document.location).replace(/[^\/]*$/, "");
  5876. if (document.location.protocol !== "file:" || (t.config.root + "/").substr(0, i.length) === i) r = "otf";
  5877. }
  5878. n.Augment({
  5879. useProcessingFrame: !0,
  5880. ffVerticalAlignBug: !0,
  5881. AccentBug: !0,
  5882. allowWebFonts: r
  5883. });
  5884. },
  5885. Safari: function(e) {
  5886. var r = e.versionAtLeast("3.0"), i = e.versionAtLeast("3.1");
  5887. e.isMobile = navigator.appVersion.match(/Mobile/i) != null;
  5888. var s = navigator.appVersion.match(/ Android (\d+)\.(\d+)/), o = i && e.isMobile && (navigator.platform.match(/iPad|iPod|iPhone/) && !e.versionAtLeast("5.0") || s != null && (s[1] < 2 || s[1] == 2 && s[2] < 2));
  5889. n.Augment({
  5890. config: {
  5891. styles: {
  5892. ".MathJax img, .MathJax nobr, .MathJax a": {
  5893. "max-width": "5000em",
  5894. "max-height": "5000em"
  5895. }
  5896. }
  5897. },
  5898. useProcessingFrame: !0,
  5899. rfuzz: .05,
  5900. AccentBug: !0,
  5901. AdjustSurd: !0,
  5902. safariContextMenuBug: !0,
  5903. safariNegativeSpaceBug: !0,
  5904. safariVerticalAlignBug: !i,
  5905. safariTextNodeBug: !r,
  5906. safariWebFontSerif: [ "serif" ],
  5907. allowWebFonts: i && !o ? "otf" : !1
  5908. });
  5909. if (o) {
  5910. var u = t.config["HTML-CSS"];
  5911. u ? (u.availableFonts = [], u.preferredFont = null) : t.config["HTML-CSS"] = {
  5912. availableFonts: [],
  5913. preferredFont: null
  5914. };
  5915. }
  5916. },
  5917. Chrome: function(e) {
  5918. n.Augment({
  5919. useProcessingFrame: !0,
  5920. rfuzz: .05,
  5921. AccentBug: !0,
  5922. AdjustSurd: !0,
  5923. allowWebFonts: e.versionAtLeast("4.0") ? "otf" : "svg",
  5924. safariNegativeSpaceBug: !0,
  5925. safariWebFontSerif: [ "" ]
  5926. });
  5927. },
  5928. Opera: function(e) {
  5929. e.isMini = navigator.appVersion.match("Opera Mini") != null, n.config.styles[".MathJax .merror"]["vertical-align"] = null, n.Augment({
  5930. useProcessingFrame: !0,
  5931. operaHeightBug: !0,
  5932. operaVerticalAlignBug: !0,
  5933. operaFontSizeBug: e.versionAtLeast("10.61"),
  5934. negativeSkipBug: !0,
  5935. zeroWidthBug: !0,
  5936. FontFaceBug: !0,
  5937. PaddingWidthBug: !0,
  5938. allowWebFonts: e.versionAtLeast("10.0") && !e.isMini ? "otf" : !1,
  5939. adjustAvailableFonts: function(e) {
  5940. for (var t = 0, n = e.length; t < n; t++) e[t] === "STIX" && (e.splice(t, 1), n--, t--);
  5941. this.config.preferredFont === "STIX" && (this.config.preferredFont = e[0]);
  5942. }
  5943. });
  5944. },
  5945. Konqueror: function(e) {
  5946. n.Augment({
  5947. konquerorVerticalAlignBug: !0,
  5948. noContextMenuBug: !0
  5949. });
  5950. }
  5951. });
  5952. }), MathJax.Hub.Register.StartupHook("End Cookie", function() {
  5953. t.config.menuSettings.zoom !== "None" && e.Require("[MathJax]/extensions/MathZoom.js");
  5954. });
  5955. }(MathJax.Ajax, MathJax.Hub, MathJax.OutputJax["HTML-CSS"]), function(e) {
  5956. for (var t in e.loading) /KAthJax-[0-9a-f]{32}.js$/.test(t) && e.loadComplete(t);
  5957. }(MathJax.Ajax);