From 17377df48abdf10b6a064d6afdc1a4c95441ae20 Mon Sep 17 00:00:00 2001 From: rootavish Date: Tue, 19 Aug 2014 00:16:41 +0530 Subject: Mathjax Support The Mathjax files will be installed to $(backenddir)/epub/MathJax This was as small as the install got. --- .../epub/MathJax/jax/input/AsciiMath/Makefile.am | 6 ++++ backend/epub/MathJax/jax/input/AsciiMath/config.js | 19 +++++++++++++ backend/epub/MathJax/jax/input/AsciiMath/jax.js | 19 +++++++++++++ backend/epub/MathJax/jax/input/Makefile.am | 6 ++++ backend/epub/MathJax/jax/input/MathML/Makefile.am | 8 ++++++ backend/epub/MathJax/jax/input/MathML/config.js | 19 +++++++++++++ .../MathJax/jax/input/MathML/entities/Makefile.am | 33 ++++++++++++++++++++++ .../epub/MathJax/jax/input/MathML/entities/a.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/b.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/c.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/d.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/e.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/f.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/fr.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/g.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/h.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/i.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/j.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/k.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/l.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/m.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/n.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/o.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/opf.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/p.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/q.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/r.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/s.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/scr.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/t.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/u.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/v.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/w.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/x.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/y.js | 19 +++++++++++++ .../epub/MathJax/jax/input/MathML/entities/z.js | 19 +++++++++++++ backend/epub/MathJax/jax/input/MathML/jax.js | 19 +++++++++++++ backend/epub/MathJax/jax/input/TeX/Makefile.am | 6 ++++ backend/epub/MathJax/jax/input/TeX/config.js | 19 +++++++++++++ backend/epub/MathJax/jax/input/TeX/jax.js | 19 +++++++++++++ 40 files changed, 724 insertions(+) create mode 100644 backend/epub/MathJax/jax/input/AsciiMath/Makefile.am create mode 100644 backend/epub/MathJax/jax/input/AsciiMath/config.js create mode 100644 backend/epub/MathJax/jax/input/AsciiMath/jax.js create mode 100644 backend/epub/MathJax/jax/input/Makefile.am create mode 100644 backend/epub/MathJax/jax/input/MathML/Makefile.am create mode 100644 backend/epub/MathJax/jax/input/MathML/config.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/Makefile.am create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/a.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/b.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/c.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/d.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/e.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/f.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/fr.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/g.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/h.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/i.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/j.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/k.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/l.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/m.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/n.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/o.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/opf.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/p.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/q.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/r.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/s.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/scr.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/t.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/u.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/v.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/w.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/x.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/y.js create mode 100644 backend/epub/MathJax/jax/input/MathML/entities/z.js create mode 100644 backend/epub/MathJax/jax/input/MathML/jax.js create mode 100644 backend/epub/MathJax/jax/input/TeX/Makefile.am create mode 100644 backend/epub/MathJax/jax/input/TeX/config.js create mode 100644 backend/epub/MathJax/jax/input/TeX/jax.js (limited to 'backend/epub/MathJax/jax/input') diff --git a/backend/epub/MathJax/jax/input/AsciiMath/Makefile.am b/backend/epub/MathJax/jax/input/AsciiMath/Makefile.am new file mode 100644 index 00000000..aed74992 --- /dev/null +++ b/backend/epub/MathJax/jax/input/AsciiMath/Makefile.am @@ -0,0 +1,6 @@ +MathJaxAMInputJaxdir= $(backenddir)/epub/MathJax/jax/input/AsciiMath + +MathJaxAMInputJax_DATA= config.js jax.js + +-include $(top_srcdir)/git.mk + diff --git a/backend/epub/MathJax/jax/input/AsciiMath/config.js b/backend/epub/MathJax/jax/input/AsciiMath/config.js new file mode 100644 index 00000000..d15a808e --- /dev/null +++ b/backend/epub/MathJax/jax/input/AsciiMath/config.js @@ -0,0 +1,19 @@ +/* + * /MathJax/jax/input/AsciiMath/config.js + * + * Copyright (c) 2009-2014 The MathJax Consortium + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +MathJax.InputJax.AsciiMath=MathJax.InputJax({id:"AsciiMath",version:"2.4.0",directory:MathJax.InputJax.directory+"/AsciiMath",extensionDir:MathJax.InputJax.extensionDir+"/AsciiMath",config:{fixphi:true,useMathMLspacing:true,displaystyle:true,decimalsign:"."}});MathJax.InputJax.AsciiMath.Register("math/asciimath");MathJax.InputJax.AsciiMath.loadComplete("config.js"); diff --git a/backend/epub/MathJax/jax/input/AsciiMath/jax.js b/backend/epub/MathJax/jax/input/AsciiMath/jax.js new file mode 100644 index 00000000..f0c82c97 --- /dev/null +++ b/backend/epub/MathJax/jax/input/AsciiMath/jax.js @@ -0,0 +1,19 @@ +/* + * /MathJax/jax/input/AsciiMath/jax.js + * + * Copyright (c) 2009-2014 The MathJax Consortium + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +(function(ag){var k;var aa=MathJax.Object.Subclass({firstChild:null,lastChild:null,Init:function(){this.childNodes=[]},appendChild:function(i){if(i.parent){i.parent.removeChild(i)}if(this.lastChild){this.lastChild.nextSibling=i}if(!this.firstChild){this.firstChild=i}this.childNodes.push(i);i.parent=this;this.lastChild=i;return i},removeChild:function(ak){for(var aj=0,ai=this.childNodes.length;aj=ai-1){this.lastChild=al}this.childNodes[ak]=al;al.nextSibling=aj.nextSibling;aj.nextSibling=aj.parent=null;return aj},toString:function(){return"{"+this.childNodes.join("")+"}"}});var E=function(){k=MathJax.ElementJax.mml;var i=k.mbase.prototype.Init;k.mbase.Augment({firstChild:null,lastChild:null,nodeValue:null,nextSibling:null,Init:function(){var ai=i.apply(this,arguments)||this;ai.childNodes=ai.data;ai.nodeName=ai.type;return ai},appendChild:function(al){if(al.parent){al.parent.removeChild(al)}var aj=arguments;if(al.isa(aa)){aj=al.childNodes;al.data=al.childNodes=[];al.firstChild=al.lastChild=null}for(var ak=0,ai=aj.length;ak=ai-1){this.lastChild=al}this.SetData(ak,al);al.nextSibling=aj.nextSibling;aj.nextSibling=aj.parent=null;return aj},setAttribute:function(ai,aj){this[ai]=aj}})};var S={};var g={getElementById:true,createElementNS:function(ai,i){var aj=k[i]();if(i==="mo"&&ag.config.useMathMLspacing){aj.useMMLspacing=128}return aj},createTextNode:function(i){return k.chars(i).With({nodeValue:i})},createDocumentFragment:function(){return aa()}};var O={appName:"MathJax"};var ac;var I="red";var ad="serif";var t=true;var C=true;var f=".";var q=g.createElementNS==null;function V(i){if(q){return g.createElement(i)}else{return g.createElementNS("http://www.w3.org/1999/xhtml",i)}}var J=[61237,8492,61238,61239,8496,8497,61240,8459,8464,61241,61242,8466,8499,61243,61244,61245,61246,8475,61247,61248,61249,61250,61251,61252,61253,61254];var N=[61277,61278,8493,61279,61280,61281,61282,8460,8465,61283,61284,61285,61286,61287,61288,61289,61290,8476,61291,61292,61293,61294,61295,61296,61297,8488];var D=[61324,61325,8450,61326,61327,61328,61329,8461,61330,61331,61332,61333,61334,8469,61335,8473,8474,8477,61336,61337,61338,61339,61340,61341,61342,8484];var d=0,H=1,X=2,m=3,b=4,l=5,a=6,P=7,Z=8,r=9,ab=10;var j={input:"sqrt",tag:"msqrt",output:"sqrt",tex:null,ttype:H},af={input:"root",tag:"mroot",output:"root",tex:null,ttype:X},A={input:"frac",tag:"mfrac",output:"/",tex:null,ttype:X},Q={input:"/",tag:"mfrac",output:"/",tex:null,ttype:m},o={input:"stackrel",tag:"mover",output:"stackrel",tex:null,ttype:X},s={input:"_",tag:"msub",output:"_",tex:null,ttype:m},h={input:"^",tag:"msup",output:"^",tex:null,ttype:m},ah={input:"text",tag:"mtext",output:"text",tex:null,ttype:ab},x={input:"mbox",tag:"mtext",output:"mbox",tex:null,ttype:ab},p={input:'"',tag:"mtext",output:"mbox",tex:null,ttype:ab};var G=[{input:"alpha",tag:"mi",output:"\u03B1",tex:null,ttype:d},{input:"beta",tag:"mi",output:"\u03B2",tex:null,ttype:d},{input:"chi",tag:"mi",output:"\u03C7",tex:null,ttype:d},{input:"delta",tag:"mi",output:"\u03B4",tex:null,ttype:d},{input:"Delta",tag:"mo",output:"\u0394",tex:null,ttype:d},{input:"epsi",tag:"mi",output:"\u03B5",tex:"epsilon",ttype:d},{input:"varepsilon",tag:"mi",output:"\u025B",tex:null,ttype:d},{input:"eta",tag:"mi",output:"\u03B7",tex:null,ttype:d},{input:"gamma",tag:"mi",output:"\u03B3",tex:null,ttype:d},{input:"Gamma",tag:"mo",output:"\u0393",tex:null,ttype:d},{input:"iota",tag:"mi",output:"\u03B9",tex:null,ttype:d},{input:"kappa",tag:"mi",output:"\u03BA",tex:null,ttype:d},{input:"lambda",tag:"mi",output:"\u03BB",tex:null,ttype:d},{input:"Lambda",tag:"mo",output:"\u039B",tex:null,ttype:d},{input:"mu",tag:"mi",output:"\u03BC",tex:null,ttype:d},{input:"nu",tag:"mi",output:"\u03BD",tex:null,ttype:d},{input:"omega",tag:"mi",output:"\u03C9",tex:null,ttype:d},{input:"Omega",tag:"mo",output:"\u03A9",tex:null,ttype:d},{input:"phi",tag:"mi",output:"\u03C6",tex:null,ttype:d},{input:"varphi",tag:"mi",output:"\u03D5",tex:null,ttype:d},{input:"Phi",tag:"mo",output:"\u03A6",tex:null,ttype:d},{input:"pi",tag:"mi",output:"\u03C0",tex:null,ttype:d},{input:"Pi",tag:"mo",output:"\u03A0",tex:null,ttype:d},{input:"psi",tag:"mi",output:"\u03C8",tex:null,ttype:d},{input:"Psi",tag:"mi",output:"\u03A8",tex:null,ttype:d},{input:"rho",tag:"mi",output:"\u03C1",tex:null,ttype:d},{input:"sigma",tag:"mi",output:"\u03C3",tex:null,ttype:d},{input:"Sigma",tag:"mo",output:"\u03A3",tex:null,ttype:d},{input:"tau",tag:"mi",output:"\u03C4",tex:null,ttype:d},{input:"theta",tag:"mi",output:"\u03B8",tex:null,ttype:d},{input:"vartheta",tag:"mi",output:"\u03D1",tex:null,ttype:d},{input:"Theta",tag:"mo",output:"\u0398",tex:null,ttype:d},{input:"upsilon",tag:"mi",output:"\u03C5",tex:null,ttype:d},{input:"xi",tag:"mi",output:"\u03BE",tex:null,ttype:d},{input:"Xi",tag:"mo",output:"\u039E",tex:null,ttype:d},{input:"zeta",tag:"mi",output:"\u03B6",tex:null,ttype:d},{input:"*",tag:"mo",output:"\u22C5",tex:"cdot",ttype:d},{input:"**",tag:"mo",output:"\u22C6",tex:"star",ttype:d},{input:"//",tag:"mo",output:"/",tex:null,ttype:d},{input:"\\\\",tag:"mo",output:"\\",tex:"backslash",ttype:d},{input:"setminus",tag:"mo",output:"\\",tex:null,ttype:d},{input:"xx",tag:"mo",output:"\u00D7",tex:"times",ttype:d},{input:"-:",tag:"mo",output:"\u00F7",tex:"divide",ttype:d},{input:"@",tag:"mo",output:"\u2218",tex:"circ",ttype:d},{input:"o+",tag:"mo",output:"\u2295",tex:"oplus",ttype:d},{input:"ox",tag:"mo",output:"\u2297",tex:"otimes",ttype:d},{input:"o.",tag:"mo",output:"\u2299",tex:"odot",ttype:d},{input:"sum",tag:"mo",output:"\u2211",tex:null,ttype:P},{input:"prod",tag:"mo",output:"\u220F",tex:null,ttype:P},{input:"^^",tag:"mo",output:"\u2227",tex:"wedge",ttype:d},{input:"^^^",tag:"mo",output:"\u22C0",tex:"bigwedge",ttype:P},{input:"vv",tag:"mo",output:"\u2228",tex:"vee",ttype:d},{input:"vvv",tag:"mo",output:"\u22C1",tex:"bigvee",ttype:P},{input:"nn",tag:"mo",output:"\u2229",tex:"cap",ttype:d},{input:"nnn",tag:"mo",output:"\u22C2",tex:"bigcap",ttype:P},{input:"uu",tag:"mo",output:"\u222A",tex:"cup",ttype:d},{input:"uuu",tag:"mo",output:"\u22C3",tex:"bigcup",ttype:P},{input:"!=",tag:"mo",output:"\u2260",tex:"ne",ttype:d},{input:":=",tag:"mo",output:":=",tex:null,ttype:d},{input:"lt",tag:"mo",output:"<",tex:null,ttype:d},{input:"<=",tag:"mo",output:"\u2264",tex:"le",ttype:d},{input:"lt=",tag:"mo",output:"\u2264",tex:"leq",ttype:d},{input:">=",tag:"mo",output:"\u2265",tex:"ge",ttype:d},{input:"geq",tag:"mo",output:"\u2265",tex:null,ttype:d},{input:"-<",tag:"mo",output:"\u227A",tex:"prec",ttype:d},{input:"-lt",tag:"mo",output:"\u227A",tex:null,ttype:d},{input:">-",tag:"mo",output:"\u227B",tex:"succ",ttype:d},{input:"in",tag:"mo",output:"\u2208",tex:null,ttype:d},{input:"!in",tag:"mo",output:"\u2209",tex:"notin",ttype:d},{input:"sub",tag:"mo",output:"\u2282",tex:"subset",ttype:d},{input:"sup",tag:"mo",output:"\u2283",tex:"supset",ttype:d},{input:"sube",tag:"mo",output:"\u2286",tex:"subseteq",ttype:d},{input:"supe",tag:"mo",output:"\u2287",tex:"supseteq",ttype:d},{input:"-=",tag:"mo",output:"\u2261",tex:"equiv",ttype:d},{input:"~=",tag:"mo",output:"\u2245",tex:"cong",ttype:d},{input:"~~",tag:"mo",output:"\u2248",tex:"approx",ttype:d},{input:"prop",tag:"mo",output:"\u221D",tex:"propto",ttype:d},{input:"and",tag:"mtext",output:"and",tex:null,ttype:a},{input:"or",tag:"mtext",output:"or",tex:null,ttype:a},{input:"not",tag:"mo",output:"\u00AC",tex:"neg",ttype:d},{input:"=>",tag:"mo",output:"\u21D2",tex:"implies",ttype:d},{input:"if",tag:"mo",output:"if",tex:null,ttype:a},{input:"<=>",tag:"mo",output:"\u21D4",tex:"iff",ttype:d},{input:"AA",tag:"mo",output:"\u2200",tex:"forall",ttype:d},{input:"EE",tag:"mo",output:"\u2203",tex:"exists",ttype:d},{input:"_|_",tag:"mo",output:"\u22A5",tex:"bot",ttype:d},{input:"TT",tag:"mo",output:"\u22A4",tex:"top",ttype:d},{input:"|--",tag:"mo",output:"\u22A2",tex:"vdash",ttype:d},{input:"|==",tag:"mo",output:"\u22A8",tex:"models",ttype:d},{input:"(",tag:"mo",output:"(",tex:null,ttype:b},{input:")",tag:"mo",output:")",tex:null,ttype:l},{input:"[",tag:"mo",output:"[",tex:null,ttype:b},{input:"]",tag:"mo",output:"]",tex:null,ttype:l},{input:"{",tag:"mo",output:"{",tex:null,ttype:b},{input:"}",tag:"mo",output:"}",tex:null,ttype:l},{input:"|",tag:"mo",output:"|",tex:null,ttype:r},{input:"(:",tag:"mo",output:"\u2329",tex:"langle",ttype:b},{input:":)",tag:"mo",output:"\u232A",tex:"rangle",ttype:l},{input:"<<",tag:"mo",output:"\u2329",tex:null,ttype:b},{input:">>",tag:"mo",output:"\u232A",tex:null,ttype:l},{input:"{:",tag:"mo",output:"{:",tex:null,ttype:b,invisible:true},{input:":}",tag:"mo",output:":}",tex:null,ttype:l,invisible:true},{input:"int",tag:"mo",output:"\u222B",tex:null,ttype:d},{input:"dx",tag:"mi",output:"{:d x:}",tex:null,ttype:Z},{input:"dy",tag:"mi",output:"{:d y:}",tex:null,ttype:Z},{input:"dz",tag:"mi",output:"{:d z:}",tex:null,ttype:Z},{input:"dt",tag:"mi",output:"{:d t:}",tex:null,ttype:Z},{input:"oint",tag:"mo",output:"\u222E",tex:null,ttype:d},{input:"del",tag:"mo",output:"\u2202",tex:"partial",ttype:d},{input:"grad",tag:"mo",output:"\u2207",tex:"nabla",ttype:d},{input:"+-",tag:"mo",output:"\u00B1",tex:"pm",ttype:d},{input:"O/",tag:"mo",output:"\u2205",tex:"emptyset",ttype:d},{input:"oo",tag:"mo",output:"\u221E",tex:"infty",ttype:d},{input:"aleph",tag:"mo",output:"\u2135",tex:null,ttype:d},{input:"...",tag:"mo",output:"...",tex:"ldots",ttype:d},{input:":.",tag:"mo",output:"\u2234",tex:"therefore",ttype:d},{input:"/_",tag:"mo",output:"\u2220",tex:"angle",ttype:d},{input:"\\ ",tag:"mo",output:"\u00A0",tex:null,ttype:d},{input:"quad",tag:"mo",output:"\u00A0\u00A0",tex:null,ttype:d},{input:"qquad",tag:"mo",output:"\u00A0\u00A0\u00A0\u00A0",tex:null,ttype:d},{input:"cdots",tag:"mo",output:"\u22EF",tex:null,ttype:d},{input:"vdots",tag:"mo",output:"\u22EE",tex:null,ttype:d},{input:"ddots",tag:"mo",output:"\u22F1",tex:null,ttype:d},{input:"diamond",tag:"mo",output:"\u22C4",tex:null,ttype:d},{input:"square",tag:"mo",output:"\u25A1",tex:null,ttype:d},{input:"|__",tag:"mo",output:"\u230A",tex:"lfloor",ttype:d},{input:"__|",tag:"mo",output:"\u230B",tex:"rfloor",ttype:d},{input:"|~",tag:"mo",output:"\u2308",tex:"lceiling",ttype:d},{input:"~|",tag:"mo",output:"\u2309",tex:"rceiling",ttype:d},{input:"CC",tag:"mo",output:"\u2102",tex:null,ttype:d},{input:"NN",tag:"mo",output:"\u2115",tex:null,ttype:d},{input:"QQ",tag:"mo",output:"\u211A",tex:null,ttype:d},{input:"RR",tag:"mo",output:"\u211D",tex:null,ttype:d},{input:"ZZ",tag:"mo",output:"\u2124",tex:null,ttype:d},{input:"f",tag:"mi",output:"f",tex:null,ttype:H,func:true},{input:"g",tag:"mi",output:"g",tex:null,ttype:H,func:true},{input:"lim",tag:"mo",output:"lim",tex:null,ttype:P},{input:"Lim",tag:"mo",output:"Lim",tex:null,ttype:P},{input:"sin",tag:"mo",output:"sin",tex:null,ttype:H,func:true},{input:"cos",tag:"mo",output:"cos",tex:null,ttype:H,func:true},{input:"tan",tag:"mo",output:"tan",tex:null,ttype:H,func:true},{input:"sinh",tag:"mo",output:"sinh",tex:null,ttype:H,func:true},{input:"cosh",tag:"mo",output:"cosh",tex:null,ttype:H,func:true},{input:"tanh",tag:"mo",output:"tanh",tex:null,ttype:H,func:true},{input:"cot",tag:"mo",output:"cot",tex:null,ttype:H,func:true},{input:"sec",tag:"mo",output:"sec",tex:null,ttype:H,func:true},{input:"csc",tag:"mo",output:"csc",tex:null,ttype:H,func:true},{input:"log",tag:"mo",output:"log",tex:null,ttype:H,func:true},{input:"ln",tag:"mo",output:"ln",tex:null,ttype:H,func:true},{input:"det",tag:"mo",output:"det",tex:null,ttype:H,func:true},{input:"dim",tag:"mo",output:"dim",tex:null,ttype:d},{input:"mod",tag:"mo",output:"mod",tex:null,ttype:d},{input:"gcd",tag:"mo",output:"gcd",tex:null,ttype:H,func:true},{input:"lcm",tag:"mo",output:"lcm",tex:null,ttype:H,func:true},{input:"lub",tag:"mo",output:"lub",tex:null,ttype:d},{input:"glb",tag:"mo",output:"glb",tex:null,ttype:d},{input:"min",tag:"mo",output:"min",tex:null,ttype:P},{input:"max",tag:"mo",output:"max",tex:null,ttype:P},{input:"uarr",tag:"mo",output:"\u2191",tex:"uparrow",ttype:d},{input:"darr",tag:"mo",output:"\u2193",tex:"downarrow",ttype:d},{input:"rarr",tag:"mo",output:"\u2192",tex:"rightarrow",ttype:d},{input:"->",tag:"mo",output:"\u2192",tex:"to",ttype:d},{input:"|->",tag:"mo",output:"\u21A6",tex:"mapsto",ttype:d},{input:"larr",tag:"mo",output:"\u2190",tex:"leftarrow",ttype:d},{input:"harr",tag:"mo",output:"\u2194",tex:"leftrightarrow",ttype:d},{input:"rArr",tag:"mo",output:"\u21D2",tex:"Rightarrow",ttype:d},{input:"lArr",tag:"mo",output:"\u21D0",tex:"Leftarrow",ttype:d},{input:"hArr",tag:"mo",output:"\u21D4",tex:"Leftrightarrow",ttype:d},j,af,A,Q,o,s,h,{input:"hat",tag:"mover",output:"\u005E",tex:null,ttype:H,acc:true},{input:"bar",tag:"mover",output:"\u00AF",tex:"overline",ttype:H,acc:true},{input:"vec",tag:"mover",output:"\u2192",tex:null,ttype:H,acc:true},{input:"dot",tag:"mover",output:".",tex:null,ttype:H,acc:true},{input:"ddot",tag:"mover",output:"..",tex:null,ttype:H,acc:true},{input:"ul",tag:"munder",output:"\u0332",tex:"underline",ttype:H,acc:true},ah,x,p,{input:"bb",tag:"mstyle",atname:"fontweight",atval:"bold",output:"bb",tex:null,ttype:H},{input:"mathbf",tag:"mstyle",atname:"fontweight",atval:"bold",output:"mathbf",tex:null,ttype:H},{input:"sf",tag:"mstyle",atname:"fontfamily",atval:"sans-serif",output:"sf",tex:null,ttype:H},{input:"mathsf",tag:"mstyle",atname:"fontfamily",atval:"sans-serif",output:"mathsf",tex:null,ttype:H},{input:"bbb",tag:"mstyle",atname:"mathvariant",atval:"double-struck",output:"bbb",tex:null,ttype:H,codes:D},{input:"mathbb",tag:"mstyle",atname:"mathvariant",atval:"double-struck",output:"mathbb",tex:null,ttype:H,codes:D},{input:"cc",tag:"mstyle",atname:"mathvariant",atval:"script",output:"cc",tex:null,ttype:H,codes:J},{input:"mathcal",tag:"mstyle",atname:"mathvariant",atval:"script",output:"mathcal",tex:null,ttype:H,codes:J},{input:"tt",tag:"mstyle",atname:"fontfamily",atval:"monospace",output:"tt",tex:null,ttype:H},{input:"mathtt",tag:"mstyle",atname:"fontfamily",atval:"monospace",output:"mathtt",tex:null,ttype:H},{input:"fr",tag:"mstyle",atname:"mathvariant",atval:"fraktur",output:"fr",tex:null,ttype:H,codes:N},{input:"mathfrak",tag:"mstyle",atname:"mathvariant",atval:"fraktur",output:"mathfrak",tex:null,ttype:H,codes:N}];function W(ai,i){if(ai.input>i.input){return 1}else{return -1}}var U=[];function v(){var aj=[],ai;for(ai=0;ai>1;if(aj[ai]=U[ai]}y=F;if(am!=""){F=G[al].ttype;return G[al]}F=d;ai=1;ar=ao.slice(0,1);var ap=true;while("0"<=ar&&ar<="9"&&ai<=ao.length){ar=ao.slice(ai,ai+1);ai++}if(ar==f){ar=ao.slice(ai,ai+1);if("0"<=ar&&ar<="9"){ap=false;ai++;while("0"<=ar&&ar<="9"&&ai<=ao.length){ar=ao.slice(ai,ai+1);ai++}}}if((ap&&ai>1)||ai>2){ar=ao.slice(0,ai-1);aq="mn"}else{ai=2;ar=ao.slice(0,1);aq=(("A">ar||ar>"Z")&&("a">ar||ar>"z")?"mo":"mi")}if(ar=="-"&&y==m){F=m;return{input:ar,tag:aq,output:ar,ttype:H,func:true}}return{input:ar,tag:aq,output:ar,ttype:d}}function T(ai){var i;if(ai.nodeName=="mrow"){i=ai.firstChild.firstChild.nodeValue;if(i=="("||i=="["||i=="{"){ai.removeChild(ai.firstChild)}}if(ai.nodeName=="mrow"){i=ai.lastChild.firstChild.nodeValue;if(i==")"||i=="]"||i=="}"){ai.removeChild(ai.lastChild)}}}var K,y,F;function L(ao){var ak,aj,ar,am,aq,an=g.createDocumentFragment();ao=u(ao,0);ak=n(ao);if(ak==null||ak.ttype==l&&K>0){return[null,ao]}if(ak.ttype==Z){ao=ak.output+u(ao,ak.input.length);ak=n(ao)}switch(ak.ttype){case P:case d:ao=u(ao,ak.input.length);return[M(ak.tag,g.createTextNode(ak.output)),ao];case b:K++;ao=u(ao,ak.input.length);ar=w(ao,true);K--;if(typeof ak.invisible=="boolean"&&ak.invisible){aj=M("mrow",ar[0])}else{aj=M("mo",g.createTextNode(ak.output));aj=M("mrow",aj);aj.appendChild(ar[0])}return[aj,ar[1]];case ab:if(ak!=p){ao=u(ao,ak.input.length)}if(ao.charAt(0)=="{"){am=ao.indexOf("}")}else{if(ao.charAt(0)=="("){am=ao.indexOf(")")}else{if(ao.charAt(0)=="["){am=ao.indexOf("]")}else{if(ak==p){am=ao.slice(1).indexOf('"')+1}else{am=0}}}}if(am==-1){am=ao.length}aq=ao.slice(1,am);if(aq.charAt(0)==" "){aj=R("mspace");aj.setAttribute("width","1ex");an.appendChild(aj)}an.appendChild(M(ak.tag,g.createTextNode(aq)));if(aq.charAt(aq.length-1)==" "){aj=R("mspace");aj.setAttribute("width","1ex");an.appendChild(aj)}ao=u(ao,am+1);return[M("mrow",an),ao];case H:ao=u(ao,ak.input.length);ar=L(ao);if(ar[0]==null){return[M(ak.tag,g.createTextNode(ak.output)),ao]}if(typeof ak.func=="boolean"&&ak.func){aq=ao.charAt(0);if(aq=="^"||aq=="_"||aq=="/"||aq=="|"||aq==","){return[M(ak.tag,g.createTextNode(ak.output)),ao]}else{aj=M("mrow",M(ak.tag,g.createTextNode(ak.output)));aj.appendChild(ar[0]);return[aj,ar[1]]}}T(ar[0]);if(ak.input=="sqrt"){return[M(ak.tag,ar[0]),ar[1]]}else{if(typeof ak.acc=="boolean"&&ak.acc){aj=M(ak.tag,ar[0]);aj.appendChild(M("mo",g.createTextNode(ak.output)));return[aj,ar[1]]}else{if(!q&&typeof ak.codes!="undefined"){for(am=0;am64&&aq.charCodeAt(al)<91){ap=ap+String.fromCharCode(ak.codes[aq.charCodeAt(al)-65])}else{ap=ap+aq.charAt(al)}}if(ar[0].nodeName=="mi"){ar[0]=R("mo").appendChild(g.createTextNode(ap))}else{ar[0].replaceChild(R("mo").appendChild(g.createTextNode(ap)),ar[0].childNodes[am])}}}}aj=M(ak.tag,ar[0]);aj.setAttribute(ak.atname,ak.atval);return[aj,ar[1]]}}case X:ao=u(ao,ak.input.length);ar=L(ao);if(ar[0]==null){return[M("mo",g.createTextNode(ak.input)),ao]}T(ar[0]);var ai=L(ar[1]);if(ai[0]==null){return[M("mo",g.createTextNode(ak.input)),ao]}T(ai[0]);if(ak.input=="root"||ak.input=="stackrel"){an.appendChild(ai[0])}an.appendChild(ar[0]);if(ak.input=="frac"){an.appendChild(ai[0])}return[M(ak.tag,an),ai[1]];case m:ao=u(ao,ak.input.length);return[M("mo",g.createTextNode(ak.output)),ao];case a:ao=u(ao,ak.input.length);aj=R("mspace");aj.setAttribute("width","1ex");an.appendChild(aj);an.appendChild(M(ak.tag,g.createTextNode(ak.output)));aj=R("mspace");aj.setAttribute("width","1ex");an.appendChild(aj);return[M("mrow",an),ao];case r:K++;ao=u(ao,ak.input.length);ar=w(ao,false);K--;aq="";if(ar[0].lastChild!=null){aq=ar[0].lastChild.firstChild.nodeValue}if(aq=="|"){aj=M("mo",g.createTextNode(ak.output));aj=M("mrow",aj);aj.appendChild(ar[0]);return[aj,ar[1]]}else{aj=M("mo",g.createTextNode(ak.output));aj=M("mrow",aj);return[aj,ao]}default:ao=u(ao,ak.input.length);return[M(ak.tag,g.createTextNode(ak.output)),ao]}}function z(an){var al,ao,am,ak,i,aj;an=u(an,0);ao=n(an);i=L(an);ak=i[0];an=i[1];al=n(an);if(al.ttype==m&&al.input!="/"){an=u(an,al.input.length);i=L(an);if(i[0]==null){i[0]=M("mo",g.createTextNode("\u25A1"))}else{T(i[0])}an=i[1];if(al.input=="_"){am=n(an);aj=(ao.ttype==P);if(am.input=="^"){an=u(an,am.input.length);var ai=L(an);T(ai[0]);an=ai[1];ak=M((aj?"munderover":"msubsup"),ak);ak.appendChild(i[0]);ak.appendChild(ai[0]);ak=M("mrow",ak)}else{ak=M((aj?"munder":"msub"),ak);ak.appendChild(i[0])}}else{ak=M(al.tag,ak);ak.appendChild(i[0])}}return[ak,an]}function w(aq,ap){var av,ar,am,ay,an=g.createDocumentFragment();do{aq=u(aq,0);am=z(aq);ar=am[0];aq=am[1];av=n(aq);if(av.ttype==m&&av.input=="/"){aq=u(aq,av.input.length);am=z(aq);if(am[0]==null){am[0]=M("mo",g.createTextNode("\u25A1"))}else{T(am[0])}aq=am[1];T(ar);ar=M(av.tag,ar);ar.appendChild(am[0]);an.appendChild(ar);av=n(aq)}else{if(ar!=undefined){an.appendChild(ar)}}}while((av.ttype!=l&&(av.ttype!=r||ap)||K==0)&&av!=null&&av.output!="");if(av.ttype==l||av.ttype==r){var az=an.childNodes.length;if(az>0&&an.childNodes[az-1].nodeName=="mrow"&&az>1&&an.childNodes[az-2].nodeName=="mo"&&an.childNodes[az-2].firstChild.nodeValue==","){var aB=an.childNodes[az-1].lastChild.firstChild.nodeValue;if(aB==")"||aB=="]"){var aj=an.childNodes[az-1].firstChild.firstChild.nodeValue;if(aj=="("&&aB==")"&&av.output!="}"||aj=="["&&aB=="]"){var ak=[];var aw=true;var at=an.childNodes.length;for(ay=0;aw&&ay1){aw=ak[ay].length==ak[ay-2].length}}if(aw){var al,ai,ao,au,aA=g.createDocumentFragment();for(ay=0;ay2){an.removeChild(an.firstChild);an.removeChild(an.firstChild)}aA.appendChild(M("mtr",al))}ar=M("mtable",aA);if(typeof av.invisible=="boolean"&&av.invisible){ar.setAttribute("columnalign","left")}an.replaceChild(ar,an.firstChild)}}}}aq=u(aq,av.input.length);if(typeof av.invisible!="boolean"||!av.invisible){ar=M("mo",g.createTextNode(av.output));an.appendChild(ar)}}return[an,aq]}function e(aj){var ai=R("mstyle");if(I!=""){ai.setAttribute("mathcolor",I)}if(t){ai.setAttribute("displaystyle","true")}if(ad!=""){ai.setAttribute("fontfamily",ad)}K=0;ai.appendChild(w(aj.replace(/^\s+/g,""),false)[0]);ai=M("math",ai);if(C){ai.setAttribute("title",aj.replace(/\s+/g," "))}if(ad!=""&&(q||ad!="serif")){var i=V("font");i.setAttribute("face",ad);i.appendChild(ai);return i}return ai}C=false;ad="";I="";(function(){for(var aj=0,ai=G.length;aj",tex:null,ttype:d},{input:"gt=",tag:"mo",output:"\u2265",tex:"geq",ttype:d},{input:"-<=",tag:"mo",output:"\u2AAF",tex:"preceq",ttype:d},{input:">-=",tag:"mo",output:"\u2AB0",tex:"succeq",ttype:d},{input:"'",tag:"mo",output:"\u2032",tex:"prime",ttype:d},{input:"arcsin",tag:"mi",output:"arcsin",tex:null,ttype:H,func:true},{input:"arccos",tag:"mi",output:"arccos",tex:null,ttype:H,func:true},{input:"arctan",tag:"mi",output:"arctan",tex:null,ttype:H,func:true},{input:"coth",tag:"mi",output:"coth",tex:null,ttype:H,func:true},{input:"sech",tag:"mi",output:"sech",tex:null,ttype:H,func:true},{input:"csch",tag:"mi",output:"csch",tex:null,ttype:H,func:true},{input:"abs",tag:"mi",output:"abs",tex:null,ttype:H,func:true},{input:"exp",tag:"mi",output:"exp",tex:null,ttype:H,func:true},{input:"tilde",tag:"mover",output:"~",tex:null,ttype:H,acc:true});ag.Augment({AM:{Init:function(){t=ag.config.displaystyle;f=(ag.config.decimal||ag.config.decimalsign);if(ag.config.fixphi){for(var aj=0,ai=G.length;aj element, not %1","<"+h.firstChild.nodeName+">"])}this.mml=this.MakeMML(h.firstChild)},MakeMML:function(h){var i=String(h.getAttribute("class")||"");var f,g=h.nodeName.toLowerCase().replace(/^[a-z]+:/,"");var e=(i.match(/(^| )MJX-TeXAtom-([^ ]*)/));if(e){f=this.TeXAtom(e[2])}else{if(!(a[g]&&a[g].isa&&a[g].isa(a.mbase))){MathJax.Hub.signal.Post(["MathML Jax - unknown node type",g]);return a.Error(b("UnknownNodeType","Unknown node type: %1",g))}else{f=a[g]()}}this.AddAttributes(f,h);this.CheckClass(f,f["class"]);this.AddChildren(f,h);if(c.config.useMathMLspacing){f.useMMLspacing=8}return f},TeXAtom:function(f){var e=a.TeXAtom().With({texClass:a.TEXCLASS[f]});if(e.texClass===a.TEXCLASS.OP){e.movesupsub=e.movablelimits=true}return e},CheckClass:function(f,h){h=(h||"").split(/ /);var j=[];for(var g=0,e=h.length;g=2){var l=e.data[0],n=e.data[e.data.length-1];if(l.type==="mo"&&l.Get("fence")&&n.type==="mo"&&n.Get("fence")){if(l.data[0]){e.open=l.data.join("")}if(n.data[0]){e.close=n.data.join("")}}}},preProcessMath:function(f){if(f.match(/^<[a-z]+:/i)&&!f.match(/^<[^<>]* xmlns:/)){f=f.replace(/^<([a-z]+)(:math)/i,'<$1$2 xmlns:$1="http://www.w3.org/1998/Math/MathML"')}var e=f.match(/^(])+)>)/i);if(e&&e[2].match(/ (?!xmlns=)[a-z]+=\"http:/i)){f=e[1].replace(/ (?!xmlns=)([a-z]+=(['"])http:.*?\2)/ig," xmlns:$1 $1")+f.substr(e[0].length)}if(f.match(/^]* xmlns=/)){f=f.replace(/^<(math)/i,'\s*$/,"$2");return f.replace(/&([a-z][a-z0-9]*);/ig,this.replaceEntity)},trimSpace:function(e){return e.replace(/[\t\n\r]/g," ").replace(/^ +/,"").replace(/ +$/,"").replace(/ +/g," ")},replaceEntity:function(g,f){if(f.match(/^(lt|amp|quot)$/)){return g}if(c.Parse.Entity[f]){return c.Parse.Entity[f]}var h=f.charAt(0).toLowerCase();var e=f.match(/^[a-zA-Z](fr|scr|opf)$/);if(e){h=e[1]}if(!c.Parse.loaded[h]){c.Parse.loaded[h]=true;MathJax.Hub.RestartAfter(MathJax.Ajax.Require(c.entityDir+"/"+h+".js"))}return g}},{loaded:[]});c.Augment({sourceMenuTitle:["OriginalMathML","Original MathML"],prefilterHooks:MathJax.Callback.Hooks(true),postfilterHooks:MathJax.Callback.Hooks(true),Translate:function(e){if(!this.ParseXML){this.ParseXML=this.createParser()}var f,h,i={script:e};if(e.firstChild&&e.firstChild.nodeName.toLowerCase().replace(/^[a-z]+:/,"")==="math"){i.math=e.firstChild;this.prefilterHooks.Execute(i);h=i.math}else{h=MathJax.HTML.getScript(e);if(d.isMSIE){h=h.replace(/( )+$/,"")}i.math=h;this.prefilterHooks.Execute(i);h=i.math}try{f=c.Parse(h).mml}catch(g){if(!g.mathmlError){throw g}f=this.formatError(g,h,e)}i.math=a(f);this.postfilterHooks.Execute(i);return i.math},prefilterMath:function(f,e){return f},prefilterMathML:function(f,e){return f},formatError:function(h,g,e){var f=h.message.replace(/\n.*/,"");MathJax.Hub.signal.Post(["MathML Jax - parse error",f,g,e]);return a.Error(f)},Error:function(e){if(e instanceof Array){e=b.apply(b,e)}throw MathJax.Hub.Insert(Error(e),{mathmlError:true})},parseDOM:function(e){return this.parser.parseFromString(e,"text/xml")},parseMS:function(e){return(this.parser.loadXML(e)?this.parser:null)},parseDIV:function(e){this.div.innerHTML=e.replace(/<([a-z]+)([^>]*)\/>/g,"<$1$2>");return this.div},parseError:function(e){return null},createMSParser:function(){var j=null;var f=["MSXML2.DOMDocument.6.0","MSXML2.DOMDocument.5.0","MSXML2.DOMDocument.4.0","MSXML2.DOMDocument.3.0","MSXML2.DOMDocument.2.0","Microsoft.XMLDOM"];for(var g=0,e=f.length;g&]/g,"")},formatURL:function(a){return"#"+escape(a)},useLabelIds:true}}});MathJax.InputJax.TeX.Register("math/tex");MathJax.InputJax.TeX.loadComplete("config.js"); diff --git a/backend/epub/MathJax/jax/input/TeX/jax.js b/backend/epub/MathJax/jax/input/TeX/jax.js new file mode 100644 index 00000000..eb98c161 --- /dev/null +++ b/backend/epub/MathJax/jax/input/TeX/jax.js @@ -0,0 +1,19 @@ +/* + * /MathJax/jax/input/TeX/jax.js + * + * Copyright (c) 2009-2014 The MathJax Consortium + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +(function(d,c,i){var h,g="\u00A0";var j=function(l){return MathJax.Localization._.apply(MathJax.Localization,[["TeX",l]].concat([].slice.call(arguments,1)))};var e=MathJax.Object.Subclass({Init:function(m,l){this.global={isInner:l};this.data=[b.start(this.global)];if(m){this.data[0].env=m}this.env=this.data[0].env},Push:function(){var n,l,o,p;for(n=0,l=arguments.length;n":"27E9","\\lt":"27E8","\\gt":"27E9","/":"/","|":["|",{texClass:h.TEXCLASS.ORD}],".":"","\\\\":"\\","\\lmoustache":"23B0","\\rmoustache":"23B1","\\lgroup":"27EE","\\rgroup":"27EF","\\arrowvert":"23D0","\\Arrowvert":"2016","\\bracevert":"23AA","\\Vert":["2225",{texClass:h.TEXCLASS.ORD}],"\\|":["2225",{texClass:h.TEXCLASS.ORD}],"\\vert":["|",{texClass:h.TEXCLASS.ORD}],"\\uparrow":"2191","\\downarrow":"2193","\\updownarrow":"2195","\\Uparrow":"21D1","\\Downarrow":"21D3","\\Updownarrow":"21D5","\\backslash":"\\","\\rangle":"27E9","\\langle":"27E8","\\rbrace":"}","\\lbrace":"{","\\}":"}","\\{":"{","\\rceil":"2309","\\lceil":"2308","\\rfloor":"230B","\\lfloor":"230A","\\lbrack":"[","\\rbrack":"]"},macros:{displaystyle:["SetStyle","D",true,0],textstyle:["SetStyle","T",false,0],scriptstyle:["SetStyle","S",false,1],scriptscriptstyle:["SetStyle","SS",false,2],rm:["SetFont",h.VARIANT.NORMAL],mit:["SetFont",h.VARIANT.ITALIC],oldstyle:["SetFont",h.VARIANT.OLDSTYLE],cal:["SetFont",h.VARIANT.CALIGRAPHIC],it:["SetFont","-tex-mathit"],bf:["SetFont",h.VARIANT.BOLD],bbFont:["SetFont",h.VARIANT.DOUBLESTRUCK],scr:["SetFont",h.VARIANT.SCRIPT],frak:["SetFont",h.VARIANT.FRAKTUR],sf:["SetFont",h.VARIANT.SANSSERIF],tt:["SetFont",h.VARIANT.MONOSPACE],tiny:["SetSize",0.5],Tiny:["SetSize",0.6],scriptsize:["SetSize",0.7],small:["SetSize",0.85],normalsize:["SetSize",1],large:["SetSize",1.2],Large:["SetSize",1.44],LARGE:["SetSize",1.73],huge:["SetSize",2.07],Huge:["SetSize",2.49],arcsin:["NamedFn"],arccos:["NamedFn"],arctan:["NamedFn"],arg:["NamedFn"],cos:["NamedFn"],cosh:["NamedFn"],cot:["NamedFn"],coth:["NamedFn"],csc:["NamedFn"],deg:["NamedFn"],det:"NamedOp",dim:["NamedFn"],exp:["NamedFn"],gcd:"NamedOp",hom:["NamedFn"],inf:"NamedOp",ker:["NamedFn"],lg:["NamedFn"],lim:"NamedOp",liminf:["NamedOp","lim inf"],limsup:["NamedOp","lim sup"],ln:["NamedFn"],log:["NamedFn"],max:"NamedOp",min:"NamedOp",Pr:"NamedOp",sec:["NamedFn"],sin:["NamedFn"],sinh:["NamedFn"],sup:"NamedOp",tan:["NamedFn"],tanh:["NamedFn"],limits:["Limits",1],nolimits:["Limits",0],overline:["UnderOver","00AF"],underline:["UnderOver","005F"],overbrace:["UnderOver","23DE",1],underbrace:["UnderOver","23DF",1],overrightarrow:["UnderOver","2192"],underrightarrow:["UnderOver","2192"],overleftarrow:["UnderOver","2190"],underleftarrow:["UnderOver","2190"],overleftrightarrow:["UnderOver","2194"],underleftrightarrow:["UnderOver","2194"],overset:"Overset",underset:"Underset",stackrel:["Macro","\\mathrel{\\mathop{#2}\\limits^{#1}}",2],over:"Over",overwithdelims:"Over",atop:"Over",atopwithdelims:"Over",above:"Over",abovewithdelims:"Over",brace:["Over","{","}"],brack:["Over","[","]"],choose:["Over","(",")"],frac:"Frac",sqrt:"Sqrt",root:"Root",uproot:["MoveRoot","upRoot"],leftroot:["MoveRoot","leftRoot"],left:"LeftRight",right:"LeftRight",middle:"Middle",llap:"Lap",rlap:"Lap",raise:"RaiseLower",lower:"RaiseLower",moveleft:"MoveLeftRight",moveright:"MoveLeftRight",",":["Spacer",h.LENGTH.THINMATHSPACE],":":["Spacer",h.LENGTH.MEDIUMMATHSPACE],">":["Spacer",h.LENGTH.MEDIUMMATHSPACE],";":["Spacer",h.LENGTH.THICKMATHSPACE],"!":["Spacer",h.LENGTH.NEGATIVETHINMATHSPACE],enspace:["Spacer",".5em"],quad:["Spacer","1em"],qquad:["Spacer","2em"],thinspace:["Spacer",h.LENGTH.THINMATHSPACE],negthinspace:["Spacer",h.LENGTH.NEGATIVETHINMATHSPACE],hskip:"Hskip",hspace:"Hskip",kern:"Hskip",mskip:"Hskip",mspace:"Hskip",mkern:"Hskip",Rule:["Rule"],Space:["Rule","blank"],big:["MakeBig",h.TEXCLASS.ORD,0.85],Big:["MakeBig",h.TEXCLASS.ORD,1.15],bigg:["MakeBig",h.TEXCLASS.ORD,1.45],Bigg:["MakeBig",h.TEXCLASS.ORD,1.75],bigl:["MakeBig",h.TEXCLASS.OPEN,0.85],Bigl:["MakeBig",h.TEXCLASS.OPEN,1.15],biggl:["MakeBig",h.TEXCLASS.OPEN,1.45],Biggl:["MakeBig",h.TEXCLASS.OPEN,1.75],bigr:["MakeBig",h.TEXCLASS.CLOSE,0.85],Bigr:["MakeBig",h.TEXCLASS.CLOSE,1.15],biggr:["MakeBig",h.TEXCLASS.CLOSE,1.45],Biggr:["MakeBig",h.TEXCLASS.CLOSE,1.75],bigm:["MakeBig",h.TEXCLASS.REL,0.85],Bigm:["MakeBig",h.TEXCLASS.REL,1.15],biggm:["MakeBig",h.TEXCLASS.REL,1.45],Biggm:["MakeBig",h.TEXCLASS.REL,1.75],mathord:["TeXAtom",h.TEXCLASS.ORD],mathop:["TeXAtom",h.TEXCLASS.OP],mathopen:["TeXAtom",h.TEXCLASS.OPEN],mathclose:["TeXAtom",h.TEXCLASS.CLOSE],mathbin:["TeXAtom",h.TEXCLASS.BIN],mathrel:["TeXAtom",h.TEXCLASS.REL],mathpunct:["TeXAtom",h.TEXCLASS.PUNCT],mathinner:["TeXAtom",h.TEXCLASS.INNER],vcenter:["TeXAtom",h.TEXCLASS.VCENTER],mathchoice:["Extension","mathchoice"],buildrel:"BuildRel",hbox:["HBox",0],text:"HBox",mbox:["HBox",0],fbox:"FBox",strut:"Strut",mathstrut:["Macro","\\vphantom{(}"],phantom:"Phantom",vphantom:["Phantom",1,0],hphantom:["Phantom",0,1],smash:"Smash",acute:["Accent","00B4"],grave:["Accent","0060"],ddot:["Accent","00A8"],tilde:["Accent","007E"],bar:["Accent","00AF"],breve:["Accent","02D8"],check:["Accent","02C7"],hat:["Accent","005E"],vec:["Accent","2192"],dot:["Accent","02D9"],widetilde:["Accent","007E",1],widehat:["Accent","005E",1],matrix:"Matrix",array:"Matrix",pmatrix:["Matrix","(",")"],cases:["Matrix","{","","left left",null,".1em",null,true],eqalign:["Matrix",null,null,"right left",h.LENGTH.THICKMATHSPACE,".5em","D"],displaylines:["Matrix",null,null,"center",null,".5em","D"],cr:"Cr","\\":"CrLaTeX",newline:"Cr",hline:["HLine","solid"],hdashline:["HLine","dashed"],eqalignno:["Matrix",null,null,"right left right",h.LENGTH.THICKMATHSPACE+" 3em",".5em","D"],leqalignno:["Matrix",null,null,"right left right",h.LENGTH.THICKMATHSPACE+" 3em",".5em","D"],bmod:["Macro",'\\mmlToken{mo}[lspace="thickmathspace" rspace="thickmathspace"]{mod}'],pmod:["Macro","\\pod{\\mmlToken{mi}{mod}\\kern 6mu #1}",1],mod:["Macro","\\mathchoice{\\kern18mu}{\\kern12mu}{\\kern12mu}{\\kern12mu}\\mmlToken{mi}{mod}\\,\\,#1",1],pod:["Macro","\\mathchoice{\\kern18mu}{\\kern8mu}{\\kern8mu}{\\kern8mu}(#1)",1],iff:["Macro","\\;\\Longleftrightarrow\\;"],skew:["Macro","{{#2{#3\\mkern#1mu}\\mkern-#1mu}{}}",3],mathcal:["Macro","{\\cal #1}",1],mathscr:["Macro","{\\scr #1}",1],mathrm:["Macro","{\\rm #1}",1],mathbf:["Macro","{\\bf #1}",1],mathbb:["Macro","{\\bbFont #1}",1],Bbb:["Macro","{\\bbFont #1}",1],mathit:["Macro","{\\it #1}",1],mathfrak:["Macro","{\\frak #1}",1],mathsf:["Macro","{\\sf #1}",1],mathtt:["Macro","{\\tt #1}",1],textrm:["Macro","\\mathord{\\rm\\text{#1}}",1],textit:["Macro","\\mathord{\\it\\text{#1}}",1],textbf:["Macro","\\mathord{\\bf\\text{#1}}",1],textsf:["Macro","\\mathord{\\sf\\text{#1}}",1],texttt:["Macro","\\mathord{\\tt\\text{#1}}",1],pmb:["Macro","\\rlap{#1}\\kern1px{#1}",1],TeX:["Macro","T\\kern-.14em\\lower.5ex{E}\\kern-.115em X"],LaTeX:["Macro","L\\kern-.325em\\raise.21em{\\scriptstyle{A}}\\kern-.17em\\TeX"]," ":["Macro","\\text{ }"],not:"Not",dots:"Dots",space:"Tilde","\u00A0":"Tilde",begin:"BeginEnd",end:"BeginEnd",newcommand:["Extension","newcommand"],renewcommand:["Extension","newcommand"],newenvironment:["Extension","newcommand"],renewenvironment:["Extension","newcommand"],def:["Extension","newcommand"],let:["Extension","newcommand"],verb:["Extension","verb"],boldsymbol:["Extension","boldsymbol"],tag:["Extension","AMSmath"],notag:["Extension","AMSmath"],label:["Extension","AMSmath"],ref:["Extension","AMSmath"],eqref:["Extension","AMSmath"],nonumber:["Macro","\\notag"],unicode:["Extension","unicode"],color:"Color",href:["Extension","HTML"],"class":["Extension","HTML"],style:["Extension","HTML"],cssId:["Extension","HTML"],bbox:["Extension","bbox"],mmlToken:"MmlToken",require:"Require"},environment:{array:["AlignedArray"],matrix:["Array",null,null,null,"c"],pmatrix:["Array",null,"(",")","c"],bmatrix:["Array",null,"[","]","c"],Bmatrix:["Array",null,"\\{","\\}","c"],vmatrix:["Array",null,"\\vert","\\vert","c"],Vmatrix:["Array",null,"\\Vert","\\Vert","c"],cases:["Array",null,"\\{",".","ll",null,".2em","T"],equation:[null,"Equation"],"equation*":[null,"Equation"],eqnarray:["ExtensionEnv",null,"AMSmath"],"eqnarray*":["ExtensionEnv",null,"AMSmath"],align:["ExtensionEnv",null,"AMSmath"],"align*":["ExtensionEnv",null,"AMSmath"],aligned:["ExtensionEnv",null,"AMSmath"],multline:["ExtensionEnv",null,"AMSmath"],"multline*":["ExtensionEnv",null,"AMSmath"],split:["ExtensionEnv",null,"AMSmath"],gather:["ExtensionEnv",null,"AMSmath"],"gather*":["ExtensionEnv",null,"AMSmath"],gathered:["ExtensionEnv",null,"AMSmath"],alignat:["ExtensionEnv",null,"AMSmath"],"alignat*":["ExtensionEnv",null,"AMSmath"],alignedat:["ExtensionEnv",null,"AMSmath"]},p_height:1.2/0.85});if(this.config.Macros){var l=this.config.Macros;for(var m in l){if(l.hasOwnProperty(m)){if(typeof(l[m])==="string"){f.macros[m]=["Macro",l[m]]}else{f.macros[m]=["Macro"].concat(l[m])}f.macros[m].isUser=true}}}};var a=MathJax.Object.Subclass({Init:function(m,n){this.string=m;this.i=0;this.macroCount=0;var l;if(n){l={};for(var o in n){if(n.hasOwnProperty(o)){l[o]=n[o]}}}this.stack=d.Stack(l,!!n);this.Parse();this.Push(b.stop())},Parse:function(){var m,l;while(this.i=55296&&l<56320){m+=this.string.charAt(this.i++)}if(f.special[m]){this[f.special[m]](m)}else{if(f.letter.test(m)){this.Variable(m)}else{if(f.digit.test(m)){this.Number(m)}else{this.Other(m)}}}}},Push:function(){this.stack.Push.apply(this.stack,arguments)},mml:function(){if(this.stack.Top().type!=="mml"){return null}return this.stack.Top().data[0]},mmlToken:function(l){return l},ControlSequence:function(o){var l=this.GetCS(),n=this.csFindMacro(l);if(n){if(!(n instanceof Array)){n=[n]}var m=n[0];if(!(m instanceof Function)){m=this[m]}m.apply(this,[o+l].concat(n.slice(1)))}else{if(f.mathchar0mi[l]){this.csMathchar0mi(l,f.mathchar0mi[l])}else{if(f.mathchar0mo[l]){this.csMathchar0mo(l,f.mathchar0mo[l])}else{if(f.mathchar7[l]){this.csMathchar7(l,f.mathchar7[l])}else{if(f.delimiter["\\"+l]!=null){this.csDelimiter(l,f.delimiter["\\"+l])}else{this.csUndefined(o+l)}}}}}},csFindMacro:function(l){return f.macros[l]},csMathchar0mi:function(l,n){var m={mathvariant:h.VARIANT.ITALIC};if(n instanceof Array){m=n[1];n=n[0]}this.Push(this.mmlToken(h.mi(h.entity("#x"+n)).With(m)))},csMathchar0mo:function(l,n){var m={stretchy:false};if(n instanceof Array){m=n[1];m.stretchy=false;n=n[0]}this.Push(this.mmlToken(h.mo(h.entity("#x"+n)).With(m)))},csMathchar7:function(l,n){var m={mathvariant:h.VARIANT.NORMAL};if(n instanceof Array){m=n[1];n=n[0]}if(this.stack.env.font){m.mathvariant=this.stack.env.font}this.Push(this.mmlToken(h.mi(h.entity("#x"+n)).With(m)))},csDelimiter:function(l,n){var m={};if(n instanceof Array){m=n[1];n=n[0]}if(n.length===4){n=h.entity("#x"+n)}else{n=h.chars(n)}this.Push(this.mmlToken(h.mo(n).With({fence:false,stretchy:false}).With(m)))},csUndefined:function(l){d.Error(["UndefinedControlSequence","Undefined control sequence %1",l])},Variable:function(m){var l={};if(this.stack.env.font){l.mathvariant=this.stack.env.font}this.Push(this.mmlToken(h.mi(h.chars(m)).With(l)))},Number:function(o){var l,m=this.string.slice(this.i-1).match(f.number);if(m){l=h.mn(m[0].replace(/[{}]/g,""));this.i+=m[0].length-1}else{l=h.mo(h.chars(o))}if(this.stack.env.font){l.mathvariant=this.stack.env.font}this.Push(this.mmlToken(l))},Open:function(l){this.Push(b.open())},Close:function(l){this.Push(b.close())},Tilde:function(l){this.Push(h.mtext(h.chars(g)))},Space:function(l){},Superscript:function(p){if(this.GetNext().match(/\d/)){this.string=this.string.substr(0,this.i+1)+" "+this.string.substr(this.i+1)}var l,o,m,n=this.stack.Top();if(n.type==="prime"){m=n.data[0];o=n.data[1];this.stack.Pop()}else{m=this.stack.Prev();if(!m){m=h.mi("")}}if(m.isEmbellishedWrapper){m=m.data[0].data[0]}if(m.type==="msubsup"){if(m.data[m.sup]){d.Error(["DoubleExponent","Double exponent: use braces to clarify"])}l=m.sup}else{if(m.movesupsub){if(m.type!=="munderover"||m.data[m.over]){if(m.movablelimits&&m.isa(h.mi)){m=this.mi2mo(m)}m=h.munderover(m,null,null).With({movesupsub:true})}l=m.over}else{m=h.msubsup(m,null,null);l=m.sup}}this.Push(b.subsup(m).With({position:l,primes:o}))},Subscript:function(p){if(this.GetNext().match(/\d/)){this.string=this.string.substr(0,this.i+1)+" "+this.string.substr(this.i+1)}var l,o,m,n=this.stack.Top();if(n.type==="prime"){m=n.data[0];o=n.data[1];this.stack.Pop()}else{m=this.stack.Prev();if(!m){m=h.mi("")}}if(m.isEmbellishedWrapper){m=m.data[0].data[0]}if(m.type==="msubsup"){if(m.data[m.sub]){d.Error(["DoubleSubscripts","Double subscripts: use braces to clarify"])}l=m.sub}else{if(m.movesupsub){if(m.type!=="munderover"||m.data[m.under]){if(m.movablelimits&&m.isa(h.mi)){m=this.mi2mo(m)}m=h.munderover(m,null,null).With({movesupsub:true})}l=m.under}else{m=h.msubsup(m,null,null);l=m.sub}}this.Push(b.subsup(m).With({position:l,primes:o}))},PRIME:"\u2032",SMARTQUOTE:"\u2019",Prime:function(n){var m=this.stack.Prev();if(!m){m=h.mi()}if(m.type==="msubsup"&&m.data[m.sup]){d.Error(["DoubleExponentPrime","Prime causes double exponent: use braces to clarify"])}var l="";this.i--;do{l+=this.PRIME;this.i++,n=this.GetNext()}while(n==="'"||n===this.SMARTQUOTE);l=["","\u2032","\u2033","\u2034","\u2057"][l.length]||l;this.Push(b.prime(m,this.mmlToken(h.mo(l))))},mi2mo:function(l){var m=h.mo();m.Append.apply(m,l.data);var n;for(n in m.defaults){if(m.defaults.hasOwnProperty(n)&&l[n]!=null){m[n]=l[n]}}for(n in h.copyAttributes){if(h.copyAttributes.hasOwnProperty(n)&&l[n]!=null){m[n]=l[n]}}return m},Comment:function(l){while(this.id.config.MAXMACROS){d.Error(["MaxMacroSub1","MathJax maximum macro substitution count exceeded; is there a recursive macro call?"])}},Matrix:function(m,o,t,q,s,n,l,u){var r=this.GetNext();if(r===""){d.Error(["MissingArgFor","Missing argument for %1",m])}if(r==="{"){this.i++}else{this.string=r+"}"+this.string.slice(this.i+1);this.i=0}var p=b.array().With({requireClose:true,arraydef:{rowspacing:(n||"4pt"),columnspacing:(s||"1em")}});if(u){p.isCases=true}if(o||t){p.open=o;p.close=t}if(l==="D"){p.arraydef.displaystyle=true}if(q!=null){p.arraydef.columnalign=q}this.Push(p)},Entry:function(o){this.Push(b.cell().With({isEntry:true,name:o}));if(this.stack.Top().isCases){var n=this.string;var r=0,p=this.i,l=n.length;while(pd.config.MAXMACROS){d.Error(["MaxMacroSub2","MathJax maximum substitution count exceeded; is there a recursive latex environment?"])}if(p[0]&&this[p[0]]){m=this[p[0]].apply(this,[m].concat(p.slice(2)))}}this.Push(m)},envFindName:function(l){return f.environment[l]},Equation:function(l,m){return m},ExtensionEnv:function(m,l){this.Extension(m.name,l,"environment")},Array:function(m,o,t,r,s,n,l,p){if(!r){r=this.GetArgument("\\begin{"+m.name+"}")}var u=("c"+r).replace(/[^clr|:]/g,"").replace(/[^|:]([|:])+/g,"$1");r=r.replace(/[^clr]/g,"").split("").join(" ");r=r.replace(/l/g,"left").replace(/r/g,"right").replace(/c/g,"center");var q=b.array().With({arraydef:{columnalign:r,columnspacing:(s||"1em"),rowspacing:(n||"4pt")}});if(u.match(/[|:]/)){if(u.charAt(0).match(/[|:]/)){q.frame.push("left");q.frame.dashed=u.charAt(0)===":"}if(u.charAt(u.length-1).match(/[|:]/)){q.frame.push("right")}u=u.substr(1,u.length-2);q.arraydef.columnlines=u.split("").join(" ").replace(/[^|: ]/g,"none").replace(/\|/g,"solid").replace(/:/g,"dashed")}if(o){q.open=this.convertDelimiter(o)}if(t){q.close=this.convertDelimiter(t)}if(l==="D"){q.arraydef.displaystyle=true}else{if(l){q.arraydef.displaystyle=false}}if(l==="S"){q.arraydef.scriptlevel=1}if(p){q.arraydef.useHeight=false}this.Push(m);return q},AlignedArray:function(l){var m=this.GetBrackets("\\begin{"+l.name+"}");return this.setArrayAlign(this.Array.apply(this,arguments),m)},setArrayAlign:function(m,l){l=this.trimSpaces(l||"");if(l==="t"){m.arraydef.align="baseline 1"}else{if(l==="b"){m.arraydef.align="baseline -1"}else{if(l==="c"){m.arraydef.align="center"}else{if(l){m.arraydef.align=l}}}}return m},convertDelimiter:function(l){if(l){l=f.delimiter[l]}if(l==null){return null}if(l instanceof Array){l=l[0]}if(l.length===4){l=String.fromCharCode(parseInt(l,16))}return l},trimSpaces:function(l){if(typeof(l)!="string"){return l}return l.replace(/^\s+|\s+$/g,"")},nextIsSpace:function(){return this.string.charAt(this.i).match(/\s/)},GetNext:function(){while(this.nextIsSpace()){this.i++}return this.string.charAt(this.i)},GetCS:function(){var l=this.string.slice(this.i).match(/^([a-z]+|.) ?/i);if(l){this.i+=l[1].length;return l[1]}else{this.i++;return" "}},GetArgument:function(m,n){switch(this.GetNext()){case"":if(!n){d.Error(["MissingArgFor","Missing argument for %1",m])}return null;case"}":if(!n){d.Error(["ExtraCloseMissingOpen","Extra close brace or missing open brace"])}return null;case"\\":this.i++;return"\\"+this.GetCS();case"{":var l=++this.i,o=1;while(this.im.length){d.Error(["IllegalMacroParam","Illegal macro parameter reference"])}o=this.AddArgs(this.AddArgs(o,p),m[q-1]);p=""}}else{p+=q}}}return this.AddArgs(o,p)},AddArgs:function(m,l){if(l.match(/^[a-z]/i)&&m.match(/(^|[^\\])(\\\\)*\\[a-z]+$/i)){m+=" "}if(m.length+l.length>d.config.MAXBUFFER){d.Error(["MaxBufferSize","MathJax internal buffer size exceeded; is there a recursive macro call?"])}return m+l}});d.Augment({Stack:e,Parse:a,Definitions:f,Startup:k,config:{MAXMACROS:10000,MAXBUFFER:5*1024},sourceMenuTitle:["TeXCommands","TeX Commands"],annotationEncoding:"application/x-tex",prefilterHooks:MathJax.Callback.Hooks(true),postfilterHooks:MathJax.Callback.Hooks(true),Config:function(){this.SUPER(arguments).Config.apply(this,arguments);if(this.config.equationNumbers.autoNumber!=="none"){if(!this.config.extensions){this.config.extensions=[]}this.config.extensions.push("AMSmath.js")}},Translate:function(l){var m,n=false,p=MathJax.HTML.getScript(l);var r=(l.type.replace(/\n/g," ").match(/(;|\s|\n)mode\s*=\s*display(;|\s|\n|$)/)!=null);var q={math:p,display:r,script:l};this.prefilterHooks.Execute(q);p=q.math;try{m=d.Parse(p).mml()}catch(o){if(!o.texError){throw o}m=this.formatError(o,p,r,l);n=true}if(m.inferred){m=h.apply(MathJax.ElementJax,m.data)}else{m=h(m)}if(r){m.root.display="block"}if(n){m.texError=true}q.math=m;this.postfilterHooks.Execute(q);return q.math},prefilterMath:function(m,n,l){return m},postfilterMath:function(m,n,l){this.combineRelations(m.root);return m},formatError:function(o,n,p,l){var m=o.message.replace(/\n.*/,"");c.signal.Post(["TeX Jax - parse error",m,n,p,l]);return h.Error(m)},Error:function(l){if(l instanceof Array){l=j.apply(j,l)}throw c.Insert(Error(l),{texError:true})},Macro:function(l,m,n){f.macros[l]=["Macro"].concat([].slice.call(arguments,1));f.macros[l].isUser=true},fenced:function(n,m,o){var l=h.mrow().With({open:n,close:o,texClass:h.TEXCLASS.INNER});if(n){l.Append(h.mo(n).With({fence:true,stretchy:true,texClass:h.TEXCLASS.OPEN}))}if(m.type==="mrow"){l.Append.apply(l,m.data)}else{l.Append(m)}if(o){l.Append(h.mo(o).With({fence:true,stretchy:true,texClass:h.TEXCLASS.CLOSE}))}return l},combineRelations:function(p){var q,l,o,n;for(q=0,l=p.data.length;q