UNPKG

mathjax

Version:

Beautiful and accessible math in all browsers. MathJax is an open-source JavaScript display engine for LaTeX, MathML, and AsciiMath notation that works in all browsers. This package includes the packaged components (install mathjax-full to get the source

1 lines 124 kB
(()=>{"use strict";var t={d:(e,s)=>{for(var i in s)t.o(s,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:s[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{GLOBAL:()=>xt,MathJax:()=>Bt,combineConfig:()=>vt,combineDefaults:()=>Dt,combineWithMathJax:()=>St,isObject:()=>At});var s={};t.r(s),t.d(s,{AbstractDOMAdaptor:()=>Mt});var i={};t.r(i),t.d(i,{HTMLAdaptor:()=>wt});var r={};t.r(r),t.d(r,{browserAdaptor:()=>jt});var n={};t.r(n),t.d(n,{APPEND:()=>Ft,Expandable:()=>Jt,OPTIONS:()=>qt,REMOVE:()=>Xt,copy:()=>Gt,defaultOptions:()=>_t,expandable:()=>zt,insert:()=>Kt,isObject:()=>Wt,keys:()=>Ut,lookup:()=>te,makeArray:()=>$t,selectOptions:()=>Yt,selectOptionsFromKeys:()=>Zt,separateOptions:()=>Qt,userOptions:()=>Vt});var a={};t.r(a),t.d(a,{AbstractFindMath:()=>ee});var o={};t.r(o),t.d(o,{PrioritizedList:()=>se});var l={};t.r(l),t.d(l,{FunctionList:()=>ie});var h={};t.r(h),t.d(h,{AbstractInputJax:()=>re});var c={};t.r(c),t.d(c,{AbstractOutputJax:()=>ne});var d={};t.r(d),t.d(d,{END:()=>ae,LinkedList:()=>le,ListItem:()=>oe});var u={};t.r(u),t.d(u,{AbstractMathList:()=>he});var p={};t.r(p),t.d(p,{AbstractMathItem:()=>de,STATE:()=>ue,newState:()=>pe,protoItem:()=>ce});var E={};t.r(E),t.d(E,{AbstractFactory:()=>Ee});var m={};t.r(m),t.d(m,{AbstractNodeFactory:()=>me});var g={};t.r(g),t.d(g,{Attributes:()=>fe,INHERIT:()=>ge});var f={};t.r(f),t.d(f,{AbstractEmptyNode:()=>Ne,AbstractNode:()=>Re});var R={};t.r(R),t.d(R,{AbstractMmlBaseNode:()=>ve,AbstractMmlEmptyNode:()=>De,AbstractMmlLayoutNode:()=>Ae,AbstractMmlNode:()=>Oe,AbstractMmlTokenNode:()=>xe,MATHVARIANTS:()=>Ie,TEXCLASS:()=>Le,TEXCLASSNAMES:()=>be,TextNode:()=>Se,XMLNode:()=>Be,indentAttributes:()=>Te});var N={};t.r(N),t.d(N,{MmlMath:()=>Me});var L={};t.r(L),t.d(L,{MmlMi:()=>ke});var b={};t.r(b),t.d(b,{MmlMn:()=>we});var y={};t.r(y),t.d(y,{MMLSPACING:()=>Fe,MO:()=>je,OPDEF:()=>Pe,OPTABLE:()=>Xe,RANGES:()=>He,getRange:()=>We});var C={};t.r(C),t.d(C,{isPercent:()=>Ue,quotePattern:()=>Je,replaceUnicode:()=>Ke,sortLength:()=>qe,split:()=>Ge,toEntity:()=>_e,unicodeChars:()=>ze,unicodeString:()=>$e});var I={};t.r(I),t.d(I,{MmlMo:()=>Ve});var T={};t.r(T),t.d(T,{MmlMtext:()=>Ye});var O={};t.r(O),t.d(O,{MmlMspace:()=>Ze});var x={};t.r(x),t.d(x,{MmlMs:()=>Qe});var A={};t.r(A),t.d(A,{MmlInferredMrow:()=>es,MmlMrow:()=>ts});var v={};t.r(v),t.d(v,{MmlMfrac:()=>ss});var D={};t.r(D),t.d(D,{MmlMsqrt:()=>is});var S={};t.r(S),t.d(S,{MmlMroot:()=>rs});var B={};t.r(B),t.d(B,{MmlMstyle:()=>ns});var M={};t.r(M),t.d(M,{MmlMerror:()=>as});var k={};t.r(k),t.d(k,{MmlMpadded:()=>os});var w={};t.r(w),t.d(w,{MmlMphantom:()=>ls});var P={};t.r(P),t.d(P,{MmlMfenced:()=>hs});var j={};t.r(j),t.d(j,{MmlMenclose:()=>cs});var H={};t.r(H),t.d(H,{MmlMaction:()=>ds});var W={};t.r(W),t.d(W,{MmlMsub:()=>ps,MmlMsubsup:()=>us,MmlMsup:()=>Es});var F={};t.r(F),t.d(F,{MmlMover:()=>fs,MmlMunder:()=>gs,MmlMunderover:()=>ms});var X={};t.r(X),t.d(X,{MmlMmultiscripts:()=>Rs,MmlMprescripts:()=>Ns,MmlNone:()=>Ls});var q={};t.r(q),t.d(q,{MmlMtable:()=>bs});var J={};t.r(J),t.d(J,{MmlMlabeledtr:()=>Cs,MmlMtr:()=>ys});var z={};t.r(z),t.d(z,{MmlMtd:()=>Is});var $={};t.r($),t.d($,{MmlMaligngroup:()=>Ts});var U={};t.r(U),t.d(U,{MmlMalignmark:()=>Os});var G={};t.r(G),t.d(G,{MmlMglyph:()=>xs});var K={};t.r(K),t.d(K,{MmlAnnotation:()=>Ds,MmlAnnotationXML:()=>vs,MmlSemantics:()=>As});var _={};t.r(_),t.d(_,{TeXAtom:()=>Ss});var V={};t.r(V),t.d(V,{MathChoice:()=>Bs});var Y={};t.r(Y),t.d(Y,{HtmlNode:()=>Ms});var Z={};t.r(Z),t.d(Z,{MML:()=>ks});var Q={};t.r(Q),t.d(Q,{MmlFactory:()=>ws});var tt={};t.r(tt),t.d(tt,{BitField:()=>Ps,BitFieldClass:()=>js});var et={};t.r(et),t.d(et,{handleRetriesFor:()=>Hs,retryAfter:()=>Ws});var st={};t.r(st),t.d(st,{AbstractMathDocument:()=>Gs,RenderList:()=>Xs,resetAllOptions:()=>Js,resetOptions:()=>qs});var it={};t.r(it),t.d(it,{AbstractHandler:()=>_s});var rt={};t.r(rt),t.d(rt,{HandlerList:()=>Vs});var nt={};t.r(nt),t.d(nt,{AbstractVisitor:()=>Ys});var at={};t.r(at),t.d(at,{DATAMJX:()=>Zs,MmlVisitor:()=>Qs});var ot={};t.r(ot),t.d(ot,{MathMLVisitor:()=>ti});var lt={};t.r(lt),t.d(lt,{SerializedMmlVisitor:()=>ei});var ht={};t.r(ht),t.d(ht,{AbstractWrapper:()=>si});var ct={};t.r(ct),t.d(ct,{AbstractWrapperFactory:()=>ii});var dt={};t.r(dt),t.d(dt,{context:()=>ni,hasWindow:()=>ri});var ut={};t.r(ut),t.d(ut,{mathjax:()=>ai});var pt={};t.r(pt),t.d(pt,{HTMLMathItem:()=>oi});var Et={};t.r(Et),t.d(Et,{HTMLMathList:()=>li});var mt={};t.r(mt),t.d(mt,{HTMLDomStrings:()=>hi});var gt={};t.r(gt),t.d(gt,{HTMLDocument:()=>ci});var ft={};t.r(ft),t.d(ft,{HTMLHandler:()=>di});var Rt={};t.r(Rt),t.d(Rt,{RegisterHTMLHandler:()=>ui});var Nt={};t.r(Nt),t.d(Nt,{asyncLoad:()=>pi});var Lt={};t.r(Lt),t.d(Lt,{BIGDIMEN:()=>Ei,MATHSPACE:()=>fi,RELUNITS:()=>gi,UNITS:()=>mi,em:()=>Li,length2em:()=>Ri,percent:()=>Ni,px:()=>bi});var bt={};t.r(bt),t.d(bt,{BBox:()=>yi});var yt={};t.r(yt),t.d(yt,{add:()=>Oi,entities:()=>Ii,numeric:()=>Di,options:()=>Ci,remove:()=>xi,translate:()=>Ai});var Ct={};t.r(Ct),t.d(Ct,{StyleJsonSheet:()=>Si});var It={};t.r(It),t.d(It,{Styles:()=>qi,TRBL:()=>Bi,WSC:()=>Mi});var Tt={};t.r(Tt),t.d(Tt,{max:()=>zi,sum:()=>Ji});const Ot="4.0.0",xt="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:{};function At(t){return"object"==typeof t&&null!==t}function vt(t,e,s=!1){var i;for(const r of Object.keys(e))"__esModule"!==r&&t[r]!==e[r]&&null!==e[r]&&void 0!==e[r]&&(At(t[r])&&At(e[r])?vt(t[r],e[r],s||"_"===r):s&&(null===(i=Object.getOwnPropertyDescriptor(t,r))||void 0===i?void 0:i.get)||(t[r]=e[r]));return t}function Dt(t,e,s){t[e]||(t[e]={}),t=t[e];for(const e of Object.keys(s))At(t[e])&&At(s[e])?Dt(t,e,s[e]):null==t[e]&&null!=s[e]&&(t[e]=s[e]);return t}function St(t){return vt(Bt,t)}void 0!==xt.MathJax&&xt.MathJax.constructor==={}.constructor||(xt.MathJax={}),xt.MathJax.version||(xt.MathJax={version:Ot,_:{},config:xt.MathJax});const Bt=xt.MathJax;class Mt{constructor(t=null){this.canMeasureNodes=!0,this.document=t}node(t,e={},s=[],i){const r=this.create(t,i);this.setAttributes(r,e);for(const t of s)this.append(r,t);return r}setProperty(t,e,s){t[e]=s}getProperty(t,e){return t[e]}setAttributes(t,e){if(e.style&&"string"!=typeof e.style)for(const s of Object.keys(e.style))this.setStyle(t,s.replace(/-([a-z])/g,((t,e)=>e.toUpperCase())),e.style[s]);if(e.properties)for(const s of Object.keys(e.properties))t[s]=e.properties[s];for(const s of Object.keys(e))"style"===s&&"string"!=typeof e.style||"properties"===s||this.setAttribute(t,s,e[s])}replace(t,e){return this.insert(t,e),this.remove(e),e}childNode(t,e){return this.childNodes(t)[e]}allClasses(t){const e=this.getAttribute(t,"class");return e?e.replace(/ +/g," ").replace(/^ /,"").replace(/ $/,"").split(/ /):[]}cssText(t){return"style"===this.kind(t)?this.textContent(t):""}}var kt=function(t,e,s,i){return new(s||(s=Promise))((function(r,n){function a(t){try{l(i.next(t))}catch(t){n(t)}}function o(t){try{l(i.throw(t))}catch(t){n(t)}}function l(t){var e;t.done?r(t.value):(e=t.value,e instanceof s?e:new s((function(t){t(e)}))).then(a,o)}l((i=i.apply(t,e||[])).next())}))};class wt extends Mt{constructor(t){super(t.document),this.canMeasureNodes=!0,this.window=t,this.parser=new t.DOMParser}parse(t,e="text/html"){return this.parser.parseFromString(t,e)}create(t,e){return e?this.document.createElementNS(e,t):this.document.createElement(t)}text(t){return this.document.createTextNode(t)}head(t=this.document){return t.head||t}body(t=this.document){return t.body||t}root(t=this.document){return t.documentElement||t}doctype(t=this.document){return t.doctype?`<!DOCTYPE ${t.doctype.name}>`:""}tags(t,e,s=null){const i=s?t.getElementsByTagNameNS(s,e):t.getElementsByTagName(e);return Array.from(i)}getElements(t,e){let s=[];for(const e of t)"string"==typeof e?s=s.concat(Array.from(this.document.querySelectorAll(e))):Array.isArray(e)||e instanceof this.window.NodeList||e instanceof this.window.HTMLCollection?s=s.concat(Array.from(e)):s.push(e);return s}getElement(t,e=this.document){return e.querySelector(t)}contains(t,e){return t.contains(e)}parent(t){return t.parentNode}append(t,e){return t.appendChild(e)}insert(t,e){return this.parent(e).insertBefore(t,e)}remove(t){return this.parent(t).removeChild(t)}replace(t,e){return this.parent(e).replaceChild(t,e)}clone(t,e=!0){return t.cloneNode(e)}split(t,e){return t.splitText(e)}next(t){return t.nextSibling}previous(t){return t.previousSibling}firstChild(t){return t.firstChild}lastChild(t){return t.lastChild}childNodes(t){return Array.from(t.childNodes)}childNode(t,e){return t.childNodes[e]}kind(t){const e=t.nodeType;return 1===e||3===e||8===e?t.nodeName.toLowerCase():""}value(t){return t.nodeValue||""}textContent(t){return t.textContent}innerHTML(t){return t.innerHTML}outerHTML(t){return t.outerHTML}serializeXML(t){return(new this.window.XMLSerializer).serializeToString(t)}setAttribute(t,e,s,i=null){return i?(e=i.replace(/.*\//,"")+":"+e.replace(/^.*:/,""),t.setAttributeNS(i,e,s)):t.setAttribute(e,s)}getAttribute(t,e){return t.getAttribute(e)}removeAttribute(t,e){return t.removeAttribute(e)}hasAttribute(t,e){return t.hasAttribute(e)}allAttributes(t){return Array.from(t.attributes).map((t=>({name:t.name,value:t.value})))}addClass(t,e){t.classList?t.classList.add(e):t.className=(t.className+" "+e).trim()}removeClass(t,e){t.classList?t.classList.remove(e):t.className=t.className.split(/ /).filter((t=>t!==e)).join(" ")}hasClass(t,e){return t.classList?t.classList.contains(e):t.className.split(/ /).includes(e)}setStyle(t,e,s){t.style[e]=s}getStyle(t,e){return t.style[e]}allStyles(t){return t.style.cssText}insertRules(t,e){for(const s of e)try{t.sheet.insertRule(s,t.sheet.cssRules.length)}catch(t){console.warn(`MathJax: can't insert css rule '${s}': ${t.message}`)}}cssText(t){return"style"!==this.kind(t)?"":Array.from(t.sheet.cssRules).map((t=>t.cssText)).join("\n")}fontSize(t){const e=this.window.getComputedStyle(t);return parseFloat(e.fontSize)}fontFamily(t){return this.window.getComputedStyle(t).fontFamily||""}nodeSize(t,e=1,s=!1){if(s&&t.getBBox){const{width:s,height:i}=t.getBBox();return[s/e,i/e]}return[t.offsetWidth/e,t.offsetHeight/e]}nodeBBox(t){const{left:e,right:s,top:i,bottom:r}=t.getBoundingClientRect();return{left:e,right:s,top:i,bottom:r}}createWorker(t,e){return kt(this,void 0,void 0,(function*(){const{path:s,maps:i,worker:r}=e,n=`${s}/${r}`,a=`\n self.maps = '${Pt(i)}';\n importScripts('${Pt(n)}');\n `,o=URL.createObjectURL(new Blob([a],{type:"text/javascript"})),l=new Worker(o);return l.onmessage=t,URL.revokeObjectURL(o),l}))}}function Pt(t){return[...t].map((t=>("\\"===t||"'"===t?t="\\"+t:(t<" "||t>"~")&&(t=`\\u{${t.codePointAt(0).toString(16)}}`),t))).join("")}function jt(){return new wt(window)}const Ht={}.constructor;function Wt(t){return"object"==typeof t&&null!==t&&(t.constructor===Ht||t.constructor===Jt)}const Ft="[+]",Xt="[-]",qt={invalidOption:"warn",optionError:(t,e)=>{if("fatal"===qt.invalidOption)throw new Error(t);console.warn("MathJax: "+t)}};class Jt{}function zt(t){return Object.assign(Object.create(Jt.prototype),t)}function $t(t){return Array.isArray(t)?t:[t]}function Ut(t){return t?Object.keys(t).concat(Object.getOwnPropertySymbols(t)):[]}function Gt(t){const e={};for(const s of Ut(t)){const i=Object.getOwnPropertyDescriptor(t,s),r=i.value;Array.isArray(r)?i.value=Kt([],r,!1):Wt(r)&&(i.value=Gt(r)),i.enumerable&&(e[s]=i)}return Object.defineProperties(t.constructor===Jt?zt({}):{},e)}function Kt(t,e,s=!0){for(let i of Ut(e)){if(s&&void 0===t[i]&&t.constructor!==Jt){"symbol"==typeof i&&(i=i.toString()),qt.optionError(`Invalid option "${i}" (no default value).`,i);continue}const r=e[i];let n=t[i];if(!Wt(r)||null===n||"object"!=typeof n&&"function"!=typeof n)Array.isArray(r)?(t[i]=[],Kt(t[i],r,!1)):Wt(r)?t[i]=Gt(r):t[i]=r;else{const e=Ut(r);Array.isArray(n)&&(1===e.length&&(e[0]===Ft||e[0]===Xt)&&Array.isArray(r[e[0]])||2===e.length&&e.sort().join(",")===Ft+","+Xt&&Array.isArray(r[Ft])&&Array.isArray(r[Xt]))?(r[Xt]&&(n=t[i]=n.filter((t=>r[Xt].indexOf(t)<0))),r[Ft]&&(t[i]=[...n,...r[Ft]])):Kt(n,r,s)}}return t}function _t(t,...e){return e.forEach((e=>Kt(t,e,!1))),t}function Vt(t,...e){return e.forEach((e=>Kt(t,e,!0))),t}function Yt(t,...e){const s={};for(const i of e)Object.hasOwn(t,i)&&(s[i]=t[i]);return s}function Zt(t,e){return Yt(t,...Object.keys(e))}function Qt(t,...e){const s=[];for(const i of e){const e={},r={};for(const s of Object.keys(t||{}))(void 0===i[s]?r:e)[s]=t[s];s.push(e),t=r}return s.unshift(t),s}function te(t,e,s=null){return Object.hasOwn(e,t)?e[t]:s}class ee{constructor(t){const e=this.constructor;this.options=Vt(_t({},e.OPTIONS),t)}}ee.OPTIONS={};class se{constructor(){this.items=[],this.items=[]}[Symbol.iterator](){let t=0;const e=this.items;return{next:()=>({value:e[t++],done:t>e.length})}}add(t,e=se.DEFAULTPRIORITY){let s=this.items.length;do{s--}while(s>=0&&e<this.items[s].priority);return this.items.splice(s+1,0,{item:t,priority:e}),t}remove(t){let e=this.items.length;do{e--}while(e>=0&&this.items[e].item!==t);return e>=0&&this.items.splice(e,1),this}}se.DEFAULTPRIORITY=5;class ie extends se{constructor(t=null){super(),t&&this.addList(t)}addList(t){for(const e of t)Array.isArray(e)?this.add(e[0],e[1]):this.add(e)}execute(...t){for(const e of this){if(!1===e.item(...t))return!1}return!0}asyncExecute(...t){let e=-1;const s=this.items;return new Promise(((i,r)=>{!function n(){for(;++e<s.length;){const a=s[e].item(...t);if(a instanceof Promise)return void a.then(n).catch((t=>r(t)));if(!1===a)return void i(!1)}i(!0)}()}))}}class re{constructor(t={}){this.adaptor=null,this.mmlFactory=null;const e=this.constructor;this.options=Vt(_t({},e.OPTIONS),t),this.preFilters=new ie(this.options.preFilters),this.postFilters=new ie(this.options.postFilters)}get name(){return this.constructor.NAME}setAdaptor(t){this.adaptor=t}setMmlFactory(t){this.mmlFactory=t}initialize(){}reset(...t){}get processStrings(){return!0}findMath(t,e){return[]}executeFilters(t,e,s,i){const r={math:e,document:s,data:i};return t.execute(r),r.data}}re.NAME="generic",re.OPTIONS={preFilters:[],postFilters:[]};class ne{constructor(t={}){this.adaptor=null;const e=this.constructor;this.options=Vt(_t({},e.OPTIONS),t),this.preFilters=new ie(this.options.preFilters),this.postFilters=new ie(this.options.postFilters)}get name(){return this.constructor.NAME}setAdaptor(t){this.adaptor=t}initialize(){}reset(...t){}getMetrics(t){}styleSheet(t){return null}pageElements(t){return null}executeFilters(t,e,s,i){const r={math:e,document:s,data:i};return t.execute(r),r.data}}ne.NAME="generic",ne.OPTIONS={preFilters:[],postFilters:[]};const ae=Symbol();class oe{constructor(t=null){this.next=null,this.prev=null,this.data=t}}class le{constructor(...t){this.list=new oe(ae),this.list.next=this.list.prev=this.list,this.push(...t)}isBefore(t,e){return t<e}push(...t){for(const e of t){const t=new oe(e);t.next=this.list,t.prev=this.list.prev,this.list.prev=t,t.prev.next=t}return this}pop(){const t=this.list.prev;return t.data===ae?null:(this.list.prev=t.prev,t.prev.next=this.list,t.next=t.prev=null,t.data)}unshift(...t){for(const e of t.slice(0).reverse()){const t=new oe(e);t.next=this.list.next,t.prev=this.list,this.list.next=t,t.next.prev=t}return this}shift(){const t=this.list.next;return t.data===ae?null:(this.list.next=t.next,t.next.prev=this.list,t.next=t.prev=null,t.data)}remove(...t){const e=new Map;for(const s of t)e.set(s,!0);let s=this.list.next;for(;s.data!==ae;){const t=s.next;e.has(s.data)&&(s.prev.next=s.next,s.next.prev=s.prev,s.next=s.prev=null),s=t}return this}clear(){return this.list.next.prev=this.list.prev.next=null,this.list.next=this.list.prev=this.list,this}*[Symbol.iterator](){let t=this.list.next;for(;t.data!==ae;)yield t.data,t=t.next}*reversed(){let t=this.list.prev;for(;t.data!==ae;)yield t.data,t=t.prev}insert(t,e=null){null===e&&(e=this.isBefore.bind(this));const s=new oe(t);let i=this.list.next;for(;i.data!==ae&&e(i.data,s.data);)i=i.next;return s.prev=i.prev,s.next=i,i.prev.next=i.prev=s,this}sort(t=null){null===t&&(t=this.isBefore.bind(this));const e=[];for(const t of this)e.push(new le(t));for(this.list.next=this.list.prev=this.list;e.length>1;){const s=e.shift(),i=e.shift();s.merge(i,t),e.push(s)}return e.length&&(this.list=e[0].list),this}merge(t,e=null){null===e&&(e=this.isBefore.bind(this));let s=this.list.next,i=t.list.next;for(;s.data!==ae&&i.data!==ae;)e(i.data,s.data)?([i.prev.next,s.prev.next]=[s,i],[i.prev,s.prev]=[s.prev,i.prev],[this.list.prev.next,t.list.prev.next]=[t.list,this.list],[this.list.prev,t.list.prev]=[t.list.prev,this.list.prev],[s,i]=[i.next,s]):s=s.next;return i.data!==ae&&(this.list.prev.next=t.list.next,t.list.next.prev=this.list.prev,t.list.prev.next=this.list,this.list.prev=t.list.prev,t.list.next=t.list.prev=t.list),this}}class he extends le{isBefore(t,e){return t.start.i<e.start.i||t.start.i===e.start.i&&t.start.n<e.start.n}}function ce(t,e,s,i,r,n,a=null){return{open:t,math:e,close:s,n:i,start:{n:r},end:{n},display:a}}class de{get isEscaped(){return null===this.display}constructor(t,e,s=!0,i={i:0,n:0,delim:""},r={i:0,n:0,delim:""}){this.root=null,this.typesetRoot=null,this.metrics={},this.inputData={},this.outputData={},this._state=ue.UNPROCESSED,this.math=t,this.inputJax=e,this.display=s,this.start=i,this.end=r,this.root=null,this.typesetRoot=null,this.metrics={},this.inputData={},this.outputData={}}render(t){t.renderActions.renderMath(this,t)}rerender(t,e=ue.RERENDER){this.state()>=e&&this.state(e-1),t.renderActions.renderMath(this,t,e)}convert(t,e=ue.LAST){t.renderActions.renderConvert(this,t,e)}compile(t){this.state()<ue.COMPILED&&(this.root=this.inputJax.compile(this,t),this.state(ue.COMPILED))}typeset(t){this.state()<ue.TYPESET&&(this.typesetRoot=t.outputJax[this.isEscaped?"escaped":"typeset"](this,t),this.state(ue.TYPESET))}updateDocument(t){}removeFromDocument(t=!1){this.clear()}setMetrics(t,e,s,i){this.metrics={em:t,ex:e,containerWidth:s,scale:i}}state(t=null,e=!1){return null!=t&&(t<ue.INSERTED&&this._state>=ue.INSERTED&&this.removeFromDocument(e),t<ue.TYPESET&&this._state>=ue.TYPESET&&(this.outputData={}),t<ue.COMPILED&&this._state>=ue.COMPILED&&(this.inputData={}),this._state=t),this._state}reset(t=!1){this.state(ue.UNPROCESSED,t)}clear(){}}const ue={UNPROCESSED:0,FINDMATH:10,COMPILED:20,CONVERT:100,METRICS:110,RERENDER:125,TYPESET:150,INSERTED:200,LAST:1e4};function pe(t,e){if(t in ue)throw Error("State "+t+" already exists");ue[t]=e}class Ee{constructor(t=null){this.defaultKind="unknown",this.nodeMap=new Map,this.node={},null===t&&(t=this.constructor.defaultNodes);for(const e of Object.keys(t))this.setNodeClass(e,t[e])}create(t,...e){return(this.node[t]||this.node[this.defaultKind])(...e)}setNodeClass(t,e){this.nodeMap.set(t,e);const s=this.nodeMap.get(t);this.node[t]=(...t)=>new s(this,...t)}getNodeClass(t){return this.nodeMap.get(t)}deleteNodeClass(t){this.nodeMap.delete(t),delete this.node[t]}nodeIsKind(t,e){return t instanceof this.getNodeClass(e)}getKinds(){return Array.from(this.nodeMap.keys())}}Ee.defaultNodes={};class me extends Ee{create(t,e={},s=[]){return this.node[t](e,s)}}const ge="_inherit_";class fe{constructor(t,e){this.global=e,this.defaults=Object.create(e),this.inherited=Object.create(this.defaults),this.attributes=Object.create(this.inherited),Object.assign(this.defaults,t)}set(t,e){this.attributes[t]=e}setList(t){Object.assign(this.attributes,t)}unset(t){delete this.attributes[t]}get(t){let e=this.attributes[t];return e===ge&&(e=this.global[t]),e}getExplicit(t){return this.hasExplicit(t)?this.attributes[t]:void 0}hasExplicit(t){return Object.hasOwn(this.attributes,t)}hasOneOf(t){for(const e of t)if(this.hasExplicit(e))return!0;return!1}getList(...t){const e={};for(const s of t)e[s]=this.get(s);return e}setInherited(t,e){this.inherited[t]=e}getInherited(t){return this.inherited[t]}getDefault(t){return this.defaults[t]}isSet(t){return Object.hasOwn(this.attributes,t)||Object.hasOwn(this.inherited,t)}hasDefault(t){return t in this.defaults}getExplicitNames(){return Object.keys(this.attributes)}getInheritedNames(){return Object.keys(this.inherited)}getDefaultNames(){return Object.keys(this.defaults)}getGlobalNames(){return Object.keys(this.global)}getAllAttributes(){return this.attributes}getAllInherited(){return this.inherited}getAllDefaults(){return this.defaults}getAllGlobals(){return this.global}}class Re{constructor(t,e={},s=[]){this.factory=t,this.parent=null,this.properties={},this.childNodes=[];for(const t of Object.keys(e))this.setProperty(t,e[t]);s.length&&this.setChildren(s)}get kind(){return"unknown"}setProperty(t,e){this.properties[t]=e}getProperty(t){return this.properties[t]}getPropertyNames(){return Object.keys(this.properties)}getAllProperties(){return this.properties}removeProperty(...t){for(const e of t)delete this.properties[e]}isKind(t){return this.factory.nodeIsKind(this,t)}setChildren(t){this.childNodes=[];for(const e of t)this.appendChild(e)}appendChild(t){return this.childNodes.push(t),t.parent=this,t}replaceChild(t,e){const s=this.childIndex(e);return null!==s&&(this.childNodes[s]=t,t.parent=this,e.parent===this&&(e.parent=null)),t}removeChild(t){const e=this.childIndex(t);return null!==e&&(this.childNodes.splice(e,1),t.parent=null),t}childIndex(t){const e=this.childNodes.indexOf(t);return-1===e?null:e}copy(){const t=this.factory.create(this.kind);t.properties=Object.assign({},this.properties);for(const e of this.childNodes||[])e&&t.appendChild(e.copy());return t}findNodes(t){const e=[];return this.walkTree((s=>{s.isKind(t)&&e.push(s)})),e}walkTree(t,e){t(this,e);for(const s of this.childNodes)s&&s.walkTree(t,e);return e}toString(){return this.kind+"("+this.childNodes.join(",")+")"}}class Ne extends Re{setChildren(t){}appendChild(t){return t}replaceChild(t,e){return e}childIndex(t){return null}walkTree(t,e){return t(this,e),e}toString(){return this.kind}}const Le={ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,NONE:-1},be=["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER"],ye=["","thinmathspace","mediummathspace","thickmathspace"],Ce=[[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]],Ie=new Set(["normal","bold","italic","bold-italic","double-struck","fraktur","bold-fraktur","script","bold-script","sans-serif","bold-sans-serif","sans-serif-italic","sans-serif-bold-italic","monospace","inital","tailed","looped","stretched"]),Te=["indentalign","indentalignfirst","indentshift","indentshiftfirst"];class Oe extends Re{constructor(t,e={},s=[]){super(t),this.prevClass=null,this.prevLevel=null,this.texclass=null,this.arity<0&&(this.childNodes=[t.create("inferredMrow")],this.childNodes[0].parent=this),this.setChildren(s),this.attributes=new fe(t.getNodeClass(this.kind).defaults,t.getNodeClass("math").defaults),this.attributes.setList(e)}copy(t=!1){const e=this.factory.create(this.kind);if(e.properties=Object.assign({},this.properties),this.attributes){const s=this.attributes.getAllAttributes();for(const i of Object.keys(s))("id"!==i||t)&&e.attributes.set(i,s[i])}if(this.childNodes&&this.childNodes.length){let t=this.childNodes;1===t.length&&t[0].isInferred&&(t=t[0].childNodes);for(const s of t)s?e.appendChild(s.copy()):e.childNodes.push(null)}return e}get texClass(){return this.texclass}set texClass(t){this.texclass=t}get isToken(){return!1}get isEmbellished(){return!1}get isSpacelike(){return!1}get linebreakContainer(){return!1}get linebreakAlign(){return"data-align"}get arity(){return 1/0}get isInferred(){return!1}get Parent(){let t=this.parent;for(;t&&t.notParent;)t=t.Parent;return t}get notParent(){return!1}setChildren(t){return this.arity<0?this.childNodes[0].setChildren(t):super.setChildren(t)}appendChild(t){if(this.arity<0)return this.childNodes[0].appendChild(t),t;if(t.isInferred){if(this.arity===1/0)return t.childNodes.forEach((t=>super.appendChild(t))),t;const e=t;(t=this.factory.create("mrow")).setChildren(e.childNodes),t.attributes=e.attributes;for(const s of e.getPropertyNames())t.setProperty(s,e.getProperty(s))}return super.appendChild(t)}replaceChild(t,e){return this.arity<0?(this.childNodes[0].replaceChild(t,e),t):super.replaceChild(t,e)}core(){return this}coreMO(){return this}coreIndex(){return 0}childPosition(){let t=null,e=this.parent;for(;e&&e.notParent;)t=e,e=e.parent;if(t=t||this,e){let s=0;for(const i of e.childNodes){if(i===t)return s;s++}}return null}setTeXclass(t){return this.getPrevClass(t),null!=this.texClass?this:t}updateTeXclass(t){t&&(this.prevClass=t.prevClass,this.prevLevel=t.prevLevel,t.prevClass=t.prevLevel=null,this.texClass=t.texClass)}getPrevClass(t){t&&(this.prevClass=t.texClass,this.prevLevel=t.attributes.get("scriptlevel"))}texSpacing(){const t=null!=this.prevClass?this.prevClass:Le.NONE,e=this.texClass||Le.ORD;if(t===Le.NONE||e===Le.NONE)return"";const s=Ce[t][e];return(this.prevLevel>0||this.attributes.get("scriptlevel")>0)&&s>=0?"":ye[Math.abs(s)]}hasSpacingAttributes(){return this.isEmbellished&&this.coreMO().hasSpacingAttributes()}setInheritedAttributes(t={},e=!1,s=0,i=!1){var r,n,a;const o=this.attributes.getAllDefaults();for(const e of Object.keys(t)){if(Object.hasOwn(o,e)||Object.hasOwn(Oe.alwaysInherit,e)){const[s,i]=t[e];(null===(n=null===(r=Oe.noInherit[s])||void 0===r?void 0:r[this.kind])||void 0===n?void 0:n[e])||this.attributes.setInherited(e,i)}(null===(a=Oe.stopInherit[this.kind])||void 0===a?void 0:a[e])&&delete(t=Object.assign({},t))[e]}void 0===this.attributes.getExplicit("displaystyle")&&this.attributes.setInherited("displaystyle",e);void 0===this.attributes.getExplicit("scriptlevel")&&this.attributes.setInherited("scriptlevel",s),i&&this.setProperty("texprimestyle",i);const l=this.arity;if(l>=0&&l!==1/0&&(1===l&&0===this.childNodes.length||1!==l&&this.childNodes.length!==l))if(l<this.childNodes.length)this.childNodes=this.childNodes.slice(0,l);else for(;this.childNodes.length<l;)this.appendChild(this.factory.create("mrow"));if(this.linebreakContainer&&!this.isEmbellished){const e=this.linebreakAlign;if(e){const s=this.attributes.get(e)||"left";t=this.addInheritedAttributes(t,{indentalign:s,indentshift:"0",indentalignfirst:s,indentshiftfirst:"0",indentalignlast:"indentalign",indentshiftlast:"indentshift"})}}this.setChildInheritedAttributes(t,e,s,i)}setChildInheritedAttributes(t,e,s,i){for(const r of this.childNodes)r.setInheritedAttributes(t,e,s,i)}addInheritedAttributes(t,e){const s=Object.assign({},t);for(const t of Object.keys(e))"displaystyle"!==t&&"scriptlevel"!==t&&"style"!==t&&(s[t]=[this.kind,e[t]]);return s}inheritAttributesFrom(t){const e=t.attributes,s=e.get("displaystyle"),i=e.get("scriptlevel"),r=e.isSet("mathsize")?{mathsize:["math",e.get("mathsize")]}:{},n=t.getProperty("texprimestyle")||!1;this.setInheritedAttributes(r,s,i,n)}verifyTree(t=null){if(null===t)return;this.verifyAttributes(t);const e=this.arity;t.checkArity&&e>=0&&e!==1/0&&(1===e&&0===this.childNodes.length||1!==e&&this.childNodes.length!==e)&&this.mError('Wrong number of children for "'+this.kind+'" node',t,!0),this.verifyChildren(t)}verifyAttributes(t){if(t.checkAttributes){const e=this.attributes,s=[];for(const t of e.getExplicitNames())"data-"===t.substring(0,5)||void 0!==e.getDefault(t)||t.match(/^(?:class|style|id|(?:xlink:)?href)$/)||s.push(t);s.length&&this.mError("Unknown attributes for "+this.kind+" node: "+s.join(", "),t)}if(t.checkMathvariants){const e=this.attributes.getExplicit("mathvariant");!e||Ie.has(e)||this.getProperty("ignore-variant")||this.mError(`Invalid mathvariant: ${e}`,t,!0)}}verifyChildren(t){for(const e of this.childNodes)e.verifyTree(t)}mError(t,e,s=!1){if(this.parent&&this.parent.isKind("merror"))return null;const i=this.factory.create("merror");if(i.attributes.set("data-mjx-message",t),e.fullErrors||s){const s=this.factory.create("mtext"),r=this.factory.create("text");r.setText(e.fullErrors?t:this.kind),s.appendChild(r),i.appendChild(s),this.parent.replaceChild(i,this),e.fullErrors||i.attributes.set("title",t)}else this.parent.replaceChild(i,this),i.appendChild(this);return i}}Oe.defaults={mathbackground:ge,mathcolor:ge,mathsize:ge,dir:ge},Oe.noInherit={mstyle:{mpadded:{width:!0,height:!0,depth:!0,lspace:!0,voffset:!0},mtable:{width:!0,height:!0,depth:!0,align:!0}},maligngroup:{mrow:{groupalign:!0},mtable:{groupalign:!0}},mtr:{msqrt:{"data-vertical-align":!0},mroot:{"data-vertical-align":!0}},mlabeledtr:{msqrt:{"data-vertical-align":!0},mroot:{"data-vertical-align":!0}}},Oe.stopInherit={mtd:{columnalign:!0,rowalign:!0,groupalign:!0}},Oe.alwaysInherit={scriptminsize:!0,scriptsizemultiplier:!0,infixlinebreakstyle:!0},Oe.verifyDefaults={checkArity:!0,checkAttributes:!1,checkMathvariants:!0,fullErrors:!1,fixMmultiscripts:!0,fixMtables:!0};class xe extends Oe{get isToken(){return!0}getText(){let t="";for(const e of this.childNodes)e instanceof Se?t+=e.getText():"textContent"in e&&(t+=e.textContent());return t}setChildInheritedAttributes(t,e,s,i){for(const r of this.childNodes)r instanceof Oe&&r.setInheritedAttributes(t,e,s,i)}walkTree(t,e){t(this,e);for(const s of this.childNodes)s instanceof Oe&&s.walkTree(t,e);return e}}xe.defaults=Object.assign(Object.assign({},Oe.defaults),{mathvariant:"normal",mathsize:ge});class Ae extends Oe{get isSpacelike(){return this.childNodes[0].isSpacelike}get isEmbellished(){return this.childNodes[0].isEmbellished}get arity(){return-1}core(){return this.childNodes[0]}coreMO(){return this.childNodes[0].coreMO()}setTeXclass(t){return t=this.childNodes[0].setTeXclass(t),this.updateTeXclass(this.childNodes[0]),t}}Ae.defaults=Oe.defaults;class ve extends Oe{get isEmbellished(){return this.childNodes[0].isEmbellished}core(){return this.childNodes[0]}coreMO(){return this.childNodes[0].coreMO()}setTeXclass(t){this.getPrevClass(t),this.texClass=Le.ORD;const e=this.childNodes[0];let s=null;e&&(this.isEmbellished||e.isKind("mi")?(s=e.setTeXclass(t),this.updateTeXclass(this.core())):e.setTeXclass(null));for(const t of this.childNodes.slice(1))t&&t.setTeXclass(null);return s||this}}ve.defaults=Oe.defaults;class De extends Ne{get isToken(){return!1}get isEmbellished(){return!1}get isSpacelike(){return!1}get linebreakContainer(){return!1}get linebreakAlign(){return""}get arity(){return 0}get isInferred(){return!1}get notParent(){return!1}get Parent(){return this.parent}get texClass(){return Le.NONE}get prevClass(){return Le.NONE}get prevLevel(){return 0}hasSpacingAttributes(){return!1}get attributes(){return null}core(){return this}coreMO(){return this}coreIndex(){return 0}childPosition(){return 0}setTeXclass(t){return t}texSpacing(){return""}setInheritedAttributes(t,e,s,i){}inheritAttributesFrom(t){}verifyTree(t){}mError(t,e,s=!1){return null}}class Se extends De{constructor(){super(...arguments),this.text=""}get kind(){return"text"}getText(){return this.text}setText(t){return this.text=t,this}copy(){return this.factory.create(this.kind).setText(this.getText())}toString(){return this.text}}class Be extends De{constructor(){super(...arguments),this.xml=null,this.adaptor=null}get kind(){return"XML"}getXML(){return this.xml}setXML(t,e=null){return this.xml=t,this.adaptor=e,this}getSerializedXML(){return this.adaptor.serializeXML(this.xml)}copy(){return this.factory.create(this.kind).setXML(this.adaptor.clone(this.xml))}toString(){return"XML data"}}class Me extends Ae{get kind(){return"math"}get linebreakContainer(){return!0}get linebreakAlign(){return""}setChildInheritedAttributes(t,e,s,i){"display"===this.attributes.get("mode")&&this.attributes.setInherited("display","block"),t=this.addInheritedAttributes(t,this.attributes.getAllAttributes()),e=!!this.attributes.get("displaystyle")||!this.attributes.get("displaystyle")&&"block"===this.attributes.get("display"),this.attributes.setInherited("displaystyle",e),s=this.attributes.get("scriptlevel")||this.constructor.defaults.scriptlevel,super.setChildInheritedAttributes(t,e,s,i)}verifyTree(t=null){super.verifyTree(t),this.parent&&this.mError("Improper nesting of math tags",t,!0)}}Me.defaults=Object.assign(Object.assign({},Ae.defaults),{mathvariant:"normal",mathsize:"normal",mathcolor:"",mathbackground:"transparent",dir:"ltr",scriptlevel:0,displaystyle:!1,display:"inline",maxwidth:"",overflow:"linebreak",altimg:"","altimg-width":"","altimg-height":"","altimg-valign":"",alttext:"",cdgroup:"",scriptsizemultiplier:1/Math.sqrt(2),scriptminsize:".4em",infixlinebreakstyle:"before",lineleading:"100%",linebreakmultchar:"\u2062",indentshift:"auto",indentalign:"auto",indenttarget:"",indentalignfirst:"indentalign",indentshiftfirst:"indentshift",indentalignlast:"indentalign",indentshiftlast:"indentshift"});class ke extends xe{constructor(){super(...arguments),this.texclass=Le.ORD}get kind(){return"mi"}setInheritedAttributes(t={},e=!1,s=0,i=!1){super.setInheritedAttributes(t,e,s,i);this.getText().match(ke.singleCharacter)&&!t.mathvariant&&this.attributes.setInherited("mathvariant","italic")}setTeXclass(t){this.getPrevClass(t);const e=this.getText();return e.length>1&&e.match(ke.operatorName)&&"normal"===this.attributes.get("mathvariant")&&void 0===this.getProperty("autoOP")&&void 0===this.getProperty("texClass")&&(this.texClass=Le.OP,this.setProperty("autoOP",!0)),this}}ke.defaults=Object.assign({},xe.defaults),ke.operatorName=/^[a-z][a-z0-9]*$/i,ke.singleCharacter=/^[\uD800-\uDBFF]?.[\u0300-\u036F\u1AB0-\u1ABE\u1DC0-\u1DFF\u20D0-\u20EF]*$/;class we extends xe{constructor(){super(...arguments),this.texclass=Le.ORD}get kind(){return"mn"}}function Pe(t,e,s=Le.BIN,i=null){return[t,e,s,i]}we.defaults=Object.assign({},xe.defaults);const je={ORD:Pe(0,0,Le.ORD),ORD11:Pe(1,1,Le.ORD),ORD21:Pe(2,1,Le.ORD),ORD02:Pe(0,2,Le.ORD),ORD55:Pe(5,5,Le.ORD),NONE:Pe(0,0,Le.NONE),OP:Pe(1,2,Le.OP,{largeop:!0,movablelimits:!0,symmetric:!0}),OPFIXED:Pe(1,2,Le.OP,{largeop:!0,movablelimits:!0}),INTEGRAL:Pe(0,1,Le.OP,{largeop:!0,symmetric:!0}),INTEGRAL2:Pe(1,2,Le.OP,{largeop:!0,symmetric:!0}),BIN3:Pe(3,3,Le.BIN),BIN4:Pe(4,4,Le.BIN),BIN01:Pe(0,1,Le.BIN),BIN5:Pe(5,5,Le.BIN),TALLBIN:Pe(4,4,Le.BIN,{stretchy:!0}),BINOP:Pe(4,4,Le.BIN,{largeop:!0,movablelimits:!0}),REL:Pe(5,5,Le.REL),REL1:Pe(1,1,Le.REL,{stretchy:!0}),REL4:Pe(4,4,Le.REL),RELSTRETCH:Pe(5,5,Le.REL,{stretchy:!0}),RELACCENT:Pe(5,5,Le.REL,{accent:!0}),WIDEREL:Pe(5,5,Le.REL,{accent:!0,stretchy:!0}),OPEN:Pe(0,0,Le.OPEN,{fence:!0,stretchy:!0,symmetric:!0}),CLOSE:Pe(0,0,Le.CLOSE,{fence:!0,stretchy:!0,symmetric:!0}),INNER:Pe(0,0,Le.INNER),PUNCT:Pe(0,3,Le.PUNCT),ACCENT:Pe(0,0,Le.ORD,{accent:!0}),WIDEACCENT:Pe(0,0,Le.ORD,{accent:!0,stretchy:!0})},He=[[32,127,Le.REL,"mo"],[160,191,Le.ORD,"mo"],[192,591,Le.ORD,"mi"],[688,879,Le.ORD,"mo"],[880,6688,Le.ORD,"mi"],[6832,6911,Le.ORD,"mo"],[6912,7615,Le.ORD,"mi"],[7616,7679,Le.ORD,"mo"],[7680,8191,Le.ORD,"mi"],[8192,8303,Le.ORD,"mo"],[8304,8351,Le.ORD,"mo"],[8448,8527,Le.ORD,"mi"],[8528,8591,Le.ORD,"mn"],[8592,8703,Le.REL,"mo"],[8704,8959,Le.BIN,"mo"],[8960,9215,Le.ORD,"mo"],[9312,9471,Le.ORD,"mn"],[9472,10223,Le.ORD,"mo"],[10224,10239,Le.REL,"mo"],[10240,10495,Le.ORD,"mtext"],[10496,10623,Le.REL,"mo"],[10624,10751,Le.ORD,"mo"],[10752,11007,Le.BIN,"mo"],[11008,11055,Le.ORD,"mo"],[11056,11087,Le.REL,"mo"],[11088,11263,Le.ORD,"mo"],[11264,11744,Le.ORD,"mi"],[11776,11903,Le.ORD,"mo"],[11904,12255,Le.ORD,"mi","normal"],[12272,12351,Le.ORD,"mo"],[12352,42143,Le.ORD,"mi","normal"],[42192,43055,Le.ORD,"mi"],[43056,43071,Le.ORD,"mn"],[43072,55295,Le.ORD,"mi"],[63744,64255,Le.ORD,"mi","normal"],[64256,65023,Le.ORD,"mi"],[65024,65135,Le.ORD,"mo"],[65136,65791,Le.ORD,"mi"],[65792,65935,Le.ORD,"mn"],[65936,74751,Le.ORD,"mi","normal"],[74752,74879,Le.ORD,"mn"],[74880,113823,Le.ORD,"mi","normal"],[113824,119391,Le.ORD,"mo"],[119648,119679,Le.ORD,"mn"],[119808,120781,Le.ORD,"mi"],[120782,120831,Le.ORD,"mn"],[122624,129023,Le.ORD,"mo"],[129024,129279,Le.REL,"mo"],[129280,129535,Le.ORD,"mo"],[131072,195103,Le.ORD,"mi","normal"]];function We(t){const e=Xe.infix[t]||Xe.prefix[t]||Xe.postfix[t];if(e)return[0,0,e[2],"mo"];const s=t.codePointAt(0);for(const t of He)if(s<=t[1]){if(s>=t[0])return t;break}return[0,0,Le.REL,"mo"]}const Fe=[[0,0],[1,2],[3,3],[4,4],[0,0],[0,0],[0,3]],Xe={prefix:{"(":je.OPEN,"+":je.BIN01,"-":je.BIN01,"[":je.OPEN,"{":je.OPEN,"|":je.OPEN,"||":[0,0,Le.BIN,{fence:!0,stretchy:!0,symmetric:!0}],"|||":[0,0,Le.ORD,{fence:!0,stretchy:!0,symmetric:!0}],"\xac":je.ORD21,"\xb1":je.BIN01,"\u2016":[0,0,Le.ORD,{fence:!0,stretchy:!0}],"\u2018":[0,0,Le.OPEN,{fence:!0}],"\u201c":[0,0,Le.OPEN,{fence:!0}],\u2145:je.ORD21,\u2146:Pe(2,0,Le.ORD),"\u2200":je.ORD21,"\u2202":je.ORD21,"\u2203":je.ORD21,"\u2204":je.ORD21,"\u2207":je.ORD21,"\u220f":je.OP,"\u2210":je.OP,"\u2211":je.OP,"\u2212":je.BIN01,"\u2213":je.BIN01,"\u221a":[1,1,Le.ORD,{stretchy:!0}],"\u221b":je.ORD11,"\u221c":je.ORD11,"\u2220":je.ORD,"\u2221":je.ORD,"\u2222":je.ORD,"\u222b":je.INTEGRAL,"\u222c":je.INTEGRAL,"\u222d":je.INTEGRAL,"\u222e":je.INTEGRAL,"\u222f":je.INTEGRAL,"\u2230":je.INTEGRAL,"\u2231":je.INTEGRAL,"\u2232":je.INTEGRAL,"\u2233":je.INTEGRAL,"\u22c0":je.OP,"\u22c1":je.OP,"\u22c2":je.OP,"\u22c3":je.OP,"\u2308":je.OPEN,"\u230a":je.OPEN,"\u2329":je.OPEN,"\u2772":je.OPEN,"\u27e6":je.OPEN,"\u27e8":je.OPEN,"\u27ea":je.OPEN,"\u27ec":je.OPEN,"\u27ee":je.OPEN,"\u2980":[0,0,Le.ORD,{fence:!0,stretchy:!0}],"\u2983":je.OPEN,"\u2985":je.OPEN,"\u2987":je.OPEN,"\u2989":je.OPEN,"\u298b":je.OPEN,"\u298d":je.OPEN,"\u298f":je.OPEN,"\u2991":je.OPEN,"\u2993":je.OPEN,"\u2995":je.OPEN,"\u2997":je.OPEN,"\u29fc":je.OPEN,"\u2a00":je.OP,"\u2a01":je.OP,"\u2a02":je.OP,"\u2a03":je.OP,"\u2a04":je.OP,"\u2a05":je.OP,"\u2a06":je.OP,"\u2a07":je.OP,"\u2a08":je.OP,"\u2a09":je.OP,"\u2a0a":je.OP,"\u2a0b":je.INTEGRAL2,"\u2a0c":je.INTEGRAL,"\u2a0d":je.INTEGRAL2,"\u2a0e":je.INTEGRAL2,"\u2a0f":je.INTEGRAL2,"\u2a10":je.OP,"\u2a11":je.OP,"\u2a12":je.OP,"\u2a13":je.OP,"\u2a14":je.OP,"\u2a15":je.INTEGRAL2,"\u2a16":je.INTEGRAL2,"\u2a17":je.INTEGRAL2,"\u2a18":je.INTEGRAL2,"\u2a19":je.INTEGRAL2,"\u2a1a":je.INTEGRAL2,"\u2a1b":je.INTEGRAL2,"\u2a1c":je.INTEGRAL2,"\u2afc":je.OP,"\u2aff":je.OP},postfix:{"!!":Pe(1,0),"!":[1,0,Le.CLOSE,null],'"':je.ACCENT,"&":je.ORD,")":je.CLOSE,"++":Pe(0,0),"--":Pe(0,0),"..":Pe(0,0),"...":je.ORD,"'":je.ACCENT,"]":je.CLOSE,"^":je.WIDEACCENT,_:je.WIDEACCENT,"`":je.ACCENT,"|":je.CLOSE,"}":je.CLOSE,"~":je.WIDEACCENT,"||":[0,0,Le.BIN,{fence:!0,stretchy:!0,symmetric:!0}],"|||":[0,0,Le.ORD,{fence:!0,stretchy:!0,symmetric:!0}],"\xa8":je.ACCENT,\u00aa:je.ACCENT,"\xaf":je.WIDEACCENT,"\xb0":je.ORD,"\xb2":je.ACCENT,"\xb3":je.ACCENT,"\xb4":je.ACCENT,"\xb8":je.ACCENT,"\xb9":je.ACCENT,\u00ba:je.ACCENT,\u02c6:je.WIDEACCENT,\u02c7:je.WIDEACCENT,\u02c9:je.WIDEACCENT,\u02ca:je.ACCENT,\u02cb:je.ACCENT,\u02cd:je.WIDEACCENT,"\u02d8":je.ACCENT,"\u02d9":je.ACCENT,"\u02da":je.ACCENT,"\u02dc":je.WIDEACCENT,"\u02dd":je.ACCENT,"\u02f7":je.WIDEACCENT,"\u0302":je.WIDEACCENT,"\u0311":je.ACCENT,"\u03f6":je.REL,"\u2016":[0,0,Le.ORD,{fence:!0,stretchy:!0}],"\u2019":[0,0,Le.CLOSE,{fence:!0}],"\u201a":je.ACCENT,"\u201b":je.ACCENT,"\u201d":[0,0,Le.CLOSE,{fence:!0}],"\u201e":je.ACCENT,"\u201f":je.ACCENT,"\u2032":je.ORD,"\u2033":je.ORD,"\u2034":je.ORD,"\u2035":je.ORD,"\u2036":je.ORD,"\u2037":je.ORD,"\u203e":je.WIDEACCENT,"\u2057":je.ORD,"\u20db":je.ACCENT,"\u20dc":je.ACCENT,"\u2309":je.CLOSE,"\u230b":je.CLOSE,"\u232a":je.CLOSE,"\u23b4":je.WIDEACCENT,"\u23b5":je.WIDEACCENT,"\u23dc":je.WIDEACCENT,"\u23dd":je.WIDEACCENT,"\u23de":je.WIDEACCENT,"\u23df":je.WIDEACCENT,"\u23e0":je.WIDEACCENT,"\u23e1":je.WIDEACCENT,"\u25a0":je.BIN3,"\u25a1":je.BIN3,"\u25aa":je.BIN3,"\u25ab":je.BIN3,"\u25ad":je.BIN3,"\u25ae":je.BIN3,"\u25af":je.BIN3,"\u25b0":je.BIN3,"\u25b1":je.BIN3,"\u25b2":je.BIN4,"\u25b4":je.BIN4,"\u25b6":je.BIN4,"\u25b7":je.BIN4,"\u25b8":je.BIN4,"\u25bc":je.BIN4,"\u25be":je.BIN4,"\u25c0":je.BIN4,"\u25c1":je.BIN4,"\u25c2":je.BIN4,"\u25c4":je.BIN4,"\u25c5":je.BIN4,"\u25c6":je.BIN4,"\u25c7":je.BIN4,"\u25c8":je.BIN4,"\u25c9":je.BIN4,"\u25cc":je.BIN4,"\u25cd":je.BIN4,"\u25ce":je.BIN4,"\u25cf":je.BIN4,"\u25d6":je.BIN4,"\u25d7":je.BIN4,"\u25e6":je.BIN4,"\u266d":je.ORD02,"\u266e":je.ORD02,"\u266f":je.ORD02,"\u2773":je.CLOSE,"\u27e7":je.CLOSE,"\u27e9":je.CLOSE,"\u27eb":je.CLOSE,"\u27ed":je.CLOSE,"\u27ef":je.CLOSE,"\u2980":[0,0,Le.ORD,{fence:!0,stretchy:!0}],"\u2984":je.CLOSE,"\u2986":je.CLOSE,"\u2988":je.CLOSE,"\u298a":je.CLOSE,"\u298c":je.CLOSE,"\u298e":je.CLOSE,"\u2990":je.CLOSE,"\u2992":je.CLOSE,"\u2994":je.CLOSE,"\u2996":je.CLOSE,"\u2998":je.CLOSE,"\u29fd":je.CLOSE},infix:{"!=":je.BIN4,"#":je.ORD,$:je.ORD,"%":[3,3,Le.ORD,null],"&&":je.BIN4,"":je.ORD,"*":je.BIN3,"**":Pe(1,1),"*=":je.BIN4,"+":je.BIN4,"+=":je.BIN4,",":[0,3,Le.PUNCT,{linebreakstyle:"after",separator:!0}],"-":je.BIN4,"-=":je.BIN4,"->":je.BIN5,".":[0,3,Le.PUNCT,{linebreakstyle:"after",separator:!0}],"/":je.ORD11,"//":Pe(1,1),"/=":je.BIN4,":":[1,2,Le.REL,null],":=":je.BIN4,";":[0,3,Le.PUNCT,{linebreakstyle:"after",separator:!0}],"<":je.REL,"<=":je.BIN5,"<>":Pe(1,1),"=":je.REL,"==":je.BIN4,">":je.REL,">=":je.BIN5,"?":[1,1,Le.CLOSE,null],"@":je.ORD11,"\\":je.ORD,"^":je.ORD11,_:je.ORD11,"|":[2,2,Le.ORD,{fence:!0,stretchy:!0,symmetric:!0}],"||":[2,2,Le.BIN,{fence:!0,stretchy:!0,symmetric:!0}],"|||":[2,2,Le.ORD,{fence:!0,stretchy:!0,symmetric:!0}],"\xb1":je.BIN4,"\xb7":je.BIN4,"\xd7":je.BIN4,"\xf7":je.BIN4,\u02b9:je.ORD,"\u0300":je.ACCENT,"\u0301":je.ACCENT,"\u0303":je.WIDEACCENT,"\u0304":je.ACCENT,"\u0306":je.ACCENT,"\u0307":je.ACCENT,"\u0308":je.ACCENT,"\u030c":je.ACCENT,"\u0332":je.WIDEACCENT,"\u0338":je.REL4,"\u2015":[0,0,Le.ORD,{stretchy:!0}],"\u2017":[0,0,Le.ORD,{stretchy:!0}],"\u2020":je.BIN3,"\u2021":je.BIN3,"\u2022":je.BIN4,"\u2026":je.INNER,"\u2043":je.BIN4,"\u2044":je.TALLBIN,"\u2061":je.NONE,"\u2062":je.NONE,"\u2063":[0,0,Le.NONE,{linebreakstyle:"after",separator:!0}],"\u2064":je.NONE,"\u20d7":je.ACCENT,\u2111:je.ORD,\u2113:je.ORD,\u2118:je.ORD,\u211c:je.ORD,"\u2190":je.WIDEREL,"\u2191":je.RELSTRETCH,"\u2192":je.WIDEREL,"\u2193":je.RELSTRETCH,"\u2194":je.WIDEREL,"\u2195":je.RELSTRETCH,"\u2196":je.RELSTRETCH,"\u2197":je.RELSTRETCH,"\u2198":je.RELSTRETCH,"\u2199":je.RELSTRETCH,"\u219a":je.RELACCENT,"\u219b":je.RELACCENT,"\u219c":je.WIDEREL,"\u219d":je.WIDEREL,"\u219e":je.WIDEREL,"\u219f":je.WIDEREL,"\u21a0":je.WIDEREL,"\u21a1":je.RELSTRETCH,"\u21a2":je.WIDEREL,"\u21a3":je.WIDEREL,"\u21a4":je.WIDEREL,"\u21a5":je.RELSTRETCH,"\u21a6":je.WIDEREL,"\u21a7":je.RELSTRETCH,"\u21a8":je.RELSTRETCH,"\u21a9":je.WIDEREL,"\u21aa":je.WIDEREL,"\u21ab":je.WIDEREL,"\u21ac":je.WIDEREL,"\u21ad":je.WIDEREL,"\u21ae":je.RELACCENT,"\u21af":je.RELSTRETCH,"\u21b0":je.RELSTRETCH,"\u21b1":je.RELSTRETCH,"\u21b2":je.RELSTRETCH,"\u21b3":je.RELSTRETCH,"\u21b4":je.RELSTRETCH,"\u21b5":je.RELSTRETCH,"\u21b6":je.RELACCENT,"\u21b7":je.RELACCENT,"\u21b8":je.REL,"\u21b9":je.WIDEREL,"\u21ba":je.REL,"\u21bb":je.REL,"\u21bc":je.WIDEREL,"\u21bd":je.WIDEREL,"\u21be":je.RELSTRETCH,"\u21bf":je.RELSTRETCH,"\u21c0":je.WIDEREL,"\u21c1":je.WIDEREL,"\u21c2":je.RELSTRETCH,"\u21c3":je.RELSTRETCH,"\u21c4":je.WIDEREL,"\u21c5":je.RELSTRETCH,"\u21c6":je.WIDEREL,"\u21c7":je.WIDEREL,"\u21c8":je.RELSTRETCH,"\u21c9":je.WIDEREL,"\u21ca":je.RELSTRETCH,"\u21cb":je.WIDEREL,"\u21cc":je.WIDEREL,"\u21cd":je.RELACCENT,"\u21ce":je.RELACCENT,"\u21cf":je.RELACCENT,"\u21d0":je.WIDEREL,"\u21d1":je.RELSTRETCH,"\u21d2":je.WIDEREL,"\u21d3":je.RELSTRETCH,"\u21d4":je.WIDEREL,"\u21d5":je.RELSTRETCH,"\u21d6":je.RELSTRETCH,"\u21d7":je.RELSTRETCH,"\u21d8":je.RELSTRETCH,"\u21d9":je.RELSTRETCH,"\u21da":je.WIDEREL,"\u21db":je.WIDEREL,"\u21dc":je.WIDEREL,"\u21dd":je.WIDEREL,"\u21de":je.REL,"\u21df":je.REL,"\u21e0":je.WIDEREL,"\u21e1":je.RELSTRETCH,"\u21e2":je.WIDEREL,"\u21e3":je.RELSTRETCH,"\u21e4":je.WIDEREL,"\u21e5":je.WIDEREL,"\u21e6":je.WIDEREL,"\u21e7":je.RELSTRETCH,"\u21e8":je.WIDEREL,"\u21e9":je.RELSTRETCH,"\u21ea":je.RELSTRETCH,"\u21eb":je.RELSTRETCH,"\u21ec":je.RELSTRETCH,"\u21ed":je.RELSTRETCH,"\u21ee":je.RELSTRETCH,"\u21ef":je.RELSTRETCH,"\u21f0":je.WIDEREL,"\u21f1":je.REL,"\u21f2":je.REL,"\u21f3":je.RELSTRETCH,"\u21f4":je.RELACCENT,"\u21f5":je.RELSTRETCH,"\u21f6":je.WIDEREL,"\u21f7":je.RELACCENT,"\u21f8":je.RELACCENT,"\u21f9":je.RELACCENT,"\u21fa":je.RELACCENT,"\u21fb":je.RELACCENT,"\u21fc":je.RELACCENT,"\u21fd":je.WIDEREL,"\u21fe":je.WIDEREL,"\u21ff":je.WIDEREL,"\u2201":Pe(1,2,Le.ORD),"\u2205":je.ORD,"\u2206":je.BIN3,"\u2208":je.REL,"\u2209":je.REL,"\u220a":je.REL,"\u220b":je.REL,"\u220c":je.REL,"\u220d":je.REL,"\u220e":je.BIN3,"\u2212":je.BIN4,"\u2213":je.BIN4,"\u2214":je.BIN4,"\u2215":je.TALLBIN,"\u2216":je.BIN4,"\u2217":je.BIN4,"\u2218":je.BIN4,"\u2219":je.BIN4,"\u221d":je.REL,"\u221e":je.ORD,"\u221f":je.REL,"\u2223":je.REL,"\u2224":je.REL,"\u2225":je.REL,"\u2226":je.REL,"\u2227":je.BIN4,"\u2228":je.BIN4,"\u2229":je.BIN4,"\u222a":je.BIN4,"\u2234":je.REL,"\u2235":je.REL,"\u2236":je.REL,"\u2237":je.REL,"\u2238":je.BIN4,"\u2239":je.REL,"\u223a":je.BIN4,"\u223b":je.REL,"\u223c":je.REL,"\u223d":je.REL,"\u223d\u0331":je.BIN3,"\u223e":je.REL,"\u223f":je.BIN3,"\u2240":je.BIN4,"\u2241":je.REL,"\u2242":je.REL,"\u2242\u0338":je.REL,"\u2243":je.REL,"\u2244":je.REL,"\u2245":je.REL,"\u2246":je.REL,"\u2247":je.REL,"\u2248":je.REL,"\u2249":je.REL,"\u224a":je.REL,"\u224b":je.REL,"\u224c":je.REL,"\u224d":je.REL,"\u224e":je.REL,"\u224e\u0338":je.REL,"\u224f":je.REL,"\u224f\u0338":je.REL,"\u2250":je.REL,"\u2251":je.REL,"\u2252":je.REL,"\u2253":je.REL,"\u2254":je.REL,"\u2255":je.REL,"\u2256":je.REL,"\u2257":je.REL,"\u2258":je.REL,"\u2259":je.REL,"\u225a":je.REL,"\u225b":je.REL,"\u225c":je.REL,"\u225d":je.REL,"\u225e":je.REL,"\u225f":je.REL,"\u2260":je.REL,"\u2261":je.REL,"\u2262":je.REL,"\u2263":je.REL,"\u2264":je.REL,"\u2265":je.REL,"\u2266":je.REL,"\u2266\u0338":je.REL,"\u2267":je.REL,"\u2268":je.REL,"\u2269":je.REL,"\u226a":je.REL,"\u226a\u0338":je.REL,"\u226b":je.REL,"\u226b\u0338":je.REL,"\u226c":je.REL,"\u226d":je.REL,"\u226e":je.REL,"\u226f":je.REL,"\u2270":je.REL,"\u2271":je.REL,"\u2272":je.REL,"\u2273":je.REL,"\u2274":je.REL,"\u2275":je.REL,"\u2276":je.REL,"\u2277":je.REL,"\u2278":je.REL,"\u2279":je.REL,"\u227a":je.REL,"\u227b":je.REL,"\u227c":je.REL,"\u227d":je.REL,"\u227e":je.REL,"\u227f":je.REL,"\u227f\u0338":je.REL,"\u2280":je.REL,"\u2281":je.REL,"\u2282":je.REL,"\u2282\u20d2":je.REL,"\u2283":je.REL,"\u2283\u20d2":je.REL,"\u2284":je.REL,"\u2285":je.REL,"\u2286":je.REL,"\u2287":je.REL,"\u2288":je.REL,"\u2289":je.REL,"\u228a":je.REL,"\u228b":je.REL,"\u228c":je.BIN4,"\u228d":je.BIN4,"\u228e":je.BIN4,"\u228f":je.REL,"\u228f\u0338":je.REL,"\u2290":je.REL,"\u2290\u0338":je.REL,"\u2291":je.REL,"\u2292":je.REL,"\u2293":je.BIN4,"\u2294":je.BIN4,"\u2295":je.BIN4,"\u2296":je.BIN4,"\u2297":je.BIN4,"\u2298":je.BIN4,"\u2299":je.BIN4,"\u229a":je.BIN4,"\u229b":je.BIN4,"\u229c":je.BIN4,"\u229d":je.BIN4,"\u229e":je.BIN4,"\u229f":je.BIN4,"\u22a0":je.BIN4,"\u22a1":je.BIN4,"\u22a2":je.REL,"\u22a3":je.REL,"\u22a4":je.ORD55,"\u22a5":je.REL,"\u22a6":je.REL,"\u22a7":je.REL,"\u22a8":je.REL,"\u22a9":je.REL,"\u22aa":je.REL,"\u22ab":je.REL,"\u22ac":je.REL,"\u22ad":je.REL,"\u22ae":je.REL,"\u22af":je.REL,"\u22b0":je.REL,"\u22b1":je.REL,"\u22b2":je.REL,"\u22b3":je.REL,"\u22b4":je.REL,"\u22b5":je.REL,"\u22b6":je.REL,"\u22b7":je.REL,"\u22b8":je.REL,"\u22b9":je.REL,"\u22ba":je.BIN4,"\u22bb":je.BIN4,"\u22bc":je.BIN4,"\u22bd":je.BIN4,"\u22be":je.BIN3,"\u22bf":je.BIN3,"\u22c4":je.BIN4,"\u22c5":je.BIN4,"\u22c6":je.BIN4,"\u22c7":je.BIN4,"\u22c8":je.REL,"\u22c9":je.BIN4,"\u22ca":je.BIN4,"\u22cb":je.BIN4,"\u22cc":je.BIN4,"\u22cd":je.REL,"\u22ce":je.BIN4,"\u22cf":je.BIN4,"\u22d0":je.REL,"\u22d1":je.REL,"\u22d2":je.BIN4,"\u22d3":je.BIN4,"\u22d4":je.REL,"\u22d5":je.REL,"\u22d6":je.REL,"\u22d7":je.REL,"\u22d8":je.REL,"\u22d9":je.REL,"\u22da":je.REL,"\u22db":je.REL,"\u22dc":je.REL,"\u22dd":je.REL,"\u22de":je.REL,"\u22df":je.REL,"\u22e0":je.REL,"\u22e1":je.REL,"\u22e2":je.REL,"\u22e3":je.REL,"\u22e4":je.REL,"\u22e5":je.REL,"\u22e6":je.REL,"\u22e7":je.REL,"\u22e8":je.REL,"\u22e9":je.REL,"\u22ea":je.REL,"\u22eb":je.REL,"\u22ec":je.REL,"\u22ed":je.REL,"\u22ee":je.ORD55,"\u22ef":je.INNER,"\u22f0":je.REL,"\u22f1":[5,5,Le.INNER,null],"\u22f2":je.REL,"\u22f3":je.REL,"\u22f4":je.REL,"\u22f5":je.REL,"\u22f6":je.REL,"\u22f7":je.REL,"\u22f8":je.REL,"\u22f9":je.REL,"\u22fa":je.REL,"\u22fb":je.REL,"\u22fc":je.REL,"\u22fd":je.REL,"\u22fe":je.REL,"\u22ff":je.REL,"\u2305":je.BIN3,"\u2306":je.BIN3,"\u2322":je.REL4,"\u2323":je.REL4,"\u2329":je.OPEN,"\u232a":je.CLOSE,"\u23aa":je.ORD,"\u23af":[0,0,Le.ORD,{stretchy:!0}],"\u23b0":je.OPEN,"\u23b1":je.CLOSE,"\u2500":je.ORD,"\u25b3":je.BIN4,"\u25b5":je.BIN4,"\u25b9":je.BIN4,"\u25bd":je.BIN4,"\u25bf":je.BIN4,"\u25c3":je.BIN4,"\u25ef":je.BIN3,"\u2660":je.ORD,"\u2661":je.ORD,"\u2662":je.ORD,"\u2663":je.ORD,"\u2758":je.REL,"\u27f0":je.RELSTRETCH,"\u27f1":je.RELSTRETCH,"\u27f5":je.WIDEREL,"\u27f6":je.WIDEREL,"\u27f7":je.WIDEREL,"\u27f8":je.WIDEREL,"\u27f9":je.WIDEREL,"\u27fa":je.WIDEREL,"\u27fb":je.WIDEREL,"\u27fc":je.WIDEREL,"\u27fd":je.WIDEREL,"\u27fe":je.WIDEREL,"\u27ff":je.WIDEREL,"\u2900":je.RELACCENT,"\u2901":je.RELACCENT,"\u2902":je.RELACCENT,"\u2903":je.RELACCENT,"\u2904":je.RELACCENT,"\u2905":je.RELACCENT,"\u2906":je.RELACCENT,"\u2907":je.RELACCENT,"\u2908":je.REL,"\u2909":je.REL,"\u290a":je.RELSTRETCH,"\u290b":je.RELSTRETCH,"\u290c":je.WIDEREL,"\u290d":je.WIDEREL,"\u290e":je.WIDEREL,"\u290f":je.WIDEREL,"\u2910":je.WIDEREL,"\u2911":je.RELACCENT,"\u2912":je.RELSTRETCH,"\u2913":je.RELSTRETCH,"\u2914":je.RELACCENT,"\u2915":je.RELACCENT,"\u2916":je.RELACCENT,"\u2917":je.RELACCENT,"\u2918":je.RELACCENT,"\u2919":je.RELACCENT,"\u291a":je.RELACCENT,"\u291b":je.RELACCENT,"\u291c":je.RELACCENT,"\u291d":je.RELACCENT,"\u291e":je.RELACCENT,"\u291f":je.RELACCENT,"\u2920":je.RELACCENT,"\u2921":je.RELSTRETCH,"\u2922":je.RELSTRETCH,"\u2923":je.REL,"\u2924":je.REL,"\u2925":je.REL,"\u2926":je.REL,"\u2927":je.REL,"\u2928":je.REL,"\u2929":je.REL,"\u292a":je.REL,"\u292b":je.REL,"\u292c":je.REL,"\u2