scribble-mathjax/MathJax.js
2010-11-15 21:08:50 -05:00

44 lines
32 KiB
JavaScript

/*************************************************************
*
* MathJax.js
*
* The main code for the MathJax math-typesetting library. See
* http://www.mathjax.org/ for details.
*
* ---------------------------------------------------------------------
*
* Copyright (c) 2009-2010 Design Science, Inc.
*
* 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.
*/
if (!window.MathJax) {window.MathJax = {}}
MathJax.Unpack = function (data) {
var k, d, n, m, i;
for (k = 0, m = data.length; k < m; k++) {
d = data[k];
for (i = 0, n = d.length; i < n; i++)
{if (typeof(d[i]) == 'number') {d[i] = d[d[i]]}}
data[k] = d.join('');
}
eval(data.join(''));
};
MathJax.isPacked = true;
MathJax.Unpack([
['if(','document.','getElementById','&&',1,'childNodes&&',1,'createElement','){','if(!','window.MathJax','){',10,'={}}',9,'MathJax.','Hub){',15,'version="1.0.8";(','function(','d){','var b=','window[d];if(!','b){b','=window[d]={}}var ','f','=[];','var c=',19,'g','){var h=','g.','constructor',';if(!','h){h=','new Function','("")}','for(var ','i in g){if(i!=="',32,'"&&g','.hasOwnProperty','(i)){h[i]=g[i]}}','return ','h};var a=','function(){',43,35,'("',43,'arguments','.callee','.Init','.call(this,',50,')")};var e=a();e','.prototype','={bug_test:1};',9,'e',56,'.bug_test){a=',45,43,45,43,50,51,'.Init',53,50,')}}}b.','Object','=c({',32,':a(),Subclass:',19,'g,i',30,'a();h.SUPER=this;h.Init=this.Init;h','.Subclass','=this',80,';h.Augment=this.Augment;h.','protoFunction','=this.',84,';h.can=this.can;h.has=this.has;h.isa=this.isa;h',56,'=new this(f);h',56,'.',32,'=h;h.Augment(g,i);',43,'h},Init:',19,'g',30,'this;if(g','.length===','1&&g[0]===f','){return ','h}if(!(h ','instanceof ','g',51,')){h=new g',51,'(f)}',43,'h.Init.apply(h,g)||h},Augment:',19,'g,h){var i;if(g','!=null){for(i in ','g){if(g',41,'(i)){this','.',84,'(i,g[i','])}}if(g.toString!==this.prototype.toString&&g.toString!=={}.toString){this.protoFunction("toString",g.toString)}}','if(h',114,'h){if(','h',41,117,'[i]=h[i]}}}',43,'this},',84,':',19,'h,g){this',56,'[h]=g;','if(typeof',' g','==="function"){','g.SUPER=this.SUPER',56,'}},prototype:{Init',':function(){},','SUPER:',19,'g',102,'g',51,'.SUPER},can:',19,'g',102,'typeof(this[g','])==="function"},has:',19,'g',102,154,'])!=="undefined','"},isa:',19,'g){return(g ',104,72,')&&(this ',104,'g)}},can:',19,'g',102,'this',56,'.can',53,'g)},has:',19,'g',102,'this',56,'.has',53,'g)},isa:',19,'h){var g=this;while(',115,'===h',102,'true}else{g=g.SUPER}}',43,'false},SimpleSUPER:c({',32,':',19,'g',102,'this.SimpleSUPER.define(g)},define:',19,'g){var i={};if(g','!=null){',37,'h in ',115,41,'(h)){this.',84,'(h,g[h',121,43,'i},wrap:',19,'i,h){',137,'(h',')==="function"&&','h','.toString','().match(/\\.\\s*SUPER\\s*\\(/)){var g=',35,'(this.wrapper);g.label=i;g','.original','=h;h=g;g',218,'=this.stringify}',43,'h},wrapper:',45,'var h=',50,51,';this.SUPER=h.SUPER[h.label];try{var g=h',222,'.apply(this',',',50,')}catch(i){','delete this.','SUPER;','throw i}',238,239,43,'g}.','toString().replace','(/^\\s*function \\(\\)\\s*\\{\\s*/i,"").replace(/\\s*\\}\\s*$/i,""),toString:',45,43,'this',222,218,234,222,',',50,')}})})})("MathJax");(',19,'BASENAME){var ','BASE=window[BASENAME','];',9,'BASE){',259,']={}}var ','CALLBACK','=',19,'data){var cb=',35,'("',43,50,51,'.execute','.apply(',50,51,',',50,')");',37,'id in ','CALLBACK.prototype','){if(',283,41,'(id)){',137,'(data[id',160,'"){cb[id]=data[id]}else{cb[id]=',283,'[id]}}}cb',218,'=',283,218,';',43,'cb};',283,'={isCallback:true,hook',143,'data:[],object:window,execute:',45,9,'this.called||this.autoReset){this.called=!this.autoReset;',43,'this.hook',234,'.object,this','.data.concat([].slice.call(',50,',0)))}},reset:',45,238,'called},toString:',45,43,309,218,234,'.hook,',50,')}};var ISCALLBACK=',19,'f){return(typeof(f',216,'f.isCallback)};var EVAL=',19,'code',102,'eval.call(window,code)};EVAL("var __TeSt_VaR__ = 1','");if(','window.__TeSt_VaR__','){try{delete ',335,'}catch(error){',335,'=null}}else{if(','window.execScript','){EVAL=',19,'code){BASE.__code=code;code="try {"+BASENAME+".__result = eval("+BASENAME+".__code)} catch(err) {"+BASENAME+".__result = err}";',341,'(code',');var result=BASE.__result;delete BASE.__result;delete BASE.__code;if(result instanceof Error){throw result}return result','}}else{EVAL=',19,344,'var head=(',1,'getElementsByTagName("head"))[0];if(!','head){head=',1,'body}var script=',1,7,'("script");','script','.appendChild(',1,'createTextNode','(code));head',361,'script);','head.removeChild(','script',347,'}}}var USING=',19,'args,i','){if(',50,'.length','>1){if(',50,100,'2&&!(typeof ',50,'[0]==="function")&&',50,'[0] ',104,'Object&&typeof ',50,'[1]==="number"){','args=[].slice.call(',372,')}else{',388,50,',0)}}if(args ',104,'Array&&args',100,'1){args=args[0]}',137,' args',139,'if(args',274,'===',283,274,102,'args}',43,265,'({hook:args})}else{if(args ',104,'Array){',137,'(args[0])==="string"&&args[1] ',104,385,'args[1][args[0]]==="','function"){return CALLBACK({hook:args[','1][args[0]],object:args[1','],data:args.slice(','2)})}else{',137,' args[0]==="',418,'0',420,'1)})}else{',137,' args[1]==="',418,'1],object:args[0',420,'2)})}}}}else{',137,'(args)==="','string"){',43,265,'({hook:EVAL,data:[args]})}else{if(args ',104,72,102,265,'(args',390,137,'(args',')==="undefined"){',43,265,'({})}}}}}','throw Error("Can\'t ','make ','callback',' from given data")};var DELAY=',19,'time,',454,'){callback=USING(callback);',454,'.timeout=','setTimeout(',454,',time);','return callback','};var WAITFOR=',19,454,',signal',459,9,454,'.called){','WAITSIGNAL(',454,469,');signal.pending++}};var WAITEXECUTE=',45,'var signals=this','.signal',';',238,'signal;this',274,'=this.','oldExecute;',238,486,'var result=','this',274,234,',',50,');','if(ISCALLBACK(result)&&!result.called){',474,'result,signals',390,'for(var i=0,m=','signals','.length;i<m;i++){','signals[i].pending','--;if(',503,'<=0){signals[i].call()}}}};var WAITSIGNAL=',19,454,',signals){if(!(signals ',104,'Array)){','signals=[signals]}',9,454,480,'){',454,'.oldExecute=',454,274,';',454,274,'=WAITEXECUTE;',454,480,'=signals}else{if(signals',100,'1){',454,480,'.push(signals[0','])}else{',454,480,'=',454,480,'.concat(signals)}}};var AFTER=',19,454,459,454,'.pending=0;',37,'i=1,m=',50,502,'if(',50,'[i]){WAITFOR(',50,'[i],',454,')}}if(',454,'.pending===0){',489,454,'();','if(ISCALLBACK(result',')){',454,'=result}}',465,'};var HOOKS=',19,'hooks,data,reset){',9,'hooks',102,'null}if(!(hooks ',104,511,'hooks=[hooks]}if(!(data ',104,511,'data=(data==null?[]:[data])}var ','callbacks','=[{}];',500,'hooks',502,'if(reset){hooks[i].reset()}',489,'hooks[i].apply(window,data);',496,579,'.push(result)}}if(',579,100,'1',102,'null}if(',579,100,'2',102,579,'[1]}',43,'AFTER.apply({},',579,')};var QUEUE=BASE.',72,80,'({Init:',45,'this.pending','=0;','this.running','=0;','this.queue',26,'this.Push',234,',',50,')},Push:',45,'var ',454,';',500,50,502,454,'=USING(',50,'[i]);if(',454,'===',50,'[i]&&!',454,473,454,'=USING(["wait",this,',454,'])}',613,'.push(',454,')}',9,611,'&&!',609,'){','this.Process','()}',465,'},Process:',19,'queue){while(!',611,'&&!',609,'&&',613,375,'){var ',454,'=',613,'[0];queue=',613,'.slice(1);',613,26,'this.Suspend();',489,454,'();','this.Resume();','if(queue',375,'){',613,'=queue.concat(',613,')}',496,'WAITFOR(result,this',')}}},Suspend:',45,611,'++},Resume:',45,'if(',611,'){',611,'--}},call:',45,650,234,',',50,')},wait:',19,454,'){',465,'}});var SIGNAL=QUEUE',80,'({Init:',19,'name){','QUEUE',56,'.Init','.call(this',');this.name=name;','this.posted',26,'this.listeners','=[]},Post:',19,'message,',454,',forget',459,'if(this.posting||this.pending){',615,'(["Post",this,message,',454,722,533,'this.',454,'=',454,';',454,'.reset();',9,'forget){',715,'.push(message)}',671,'this.posting=1;',500,717,502,717,'[i].reset();var result=(',717,'[i])(','message);',496,684,')}}',675,238,'posting',33,609,'){this.call()}}',465,'},Clear:',19,454,459,724,454,'=',615,'(["Clear",this,',454,533,715,26,454,'()}',465,'},call:',45,'this.',454,'(this);',650,'()},Interest:',19,454,',ignorePast',459,717,'[',717,375,']=',454,33,'ignorePast){',500,715,502,454,736,489,454,'(',715,'[i]);',561,')&&i===',715,375,'-1){',684,')}}}',465,'},NoInterest:',19,454,'){',500,717,502,'if(',717,'[i]===',454,'){',717,'.splice(i,1);return}}},MessageHook:',19,'msg,',454,459,9,'this.hooks','){',833,'={};this.Interest(["','ExecuteHooks','",this])}',9,'this.hooks[msg',']){',840,']=[]}',840,'].push(',454,');',500,715,502,'if(',715,'[i]==msg){',454,736,454,'(',715,'[i])}}',465,'},',837,':',19,'msg,more){var type=((msg ',104,'Array)?msg[0]:msg);',43,'HOOKS(',833,'[type],[msg],true)}},{signals:{},find:',19,709,9,'SIGNAL.signals[name',']){',875,']=new SIGNAL(name)}',43,875,']}});BASE.Callback=BASE.CallBack=USING',';BASE.Callback.','Delay=DELAY',882,'After=AFTER',882,'Queue=QUEUE',882,'Signal=SIGNAL.find',882,837,'=HOOKS})("MathJax");(',19,'d','){var a=',22,'a){a',24,'c=(','navigator.vendor==="Apple Computer, Inc."&&typeof navigator.vendorSub==="undefined','");var f=0;var g=',19,124,1,'styleSheets','&&',1,905,375,'>f){f=',1,905,375,'}',9,'h){h=(',1,353,34,1,'body}}',43,'h};var e',26,21,45,37,'j=0,h=e',375,';j<h;j++){','a.Ajax.',367,'e[j])}e=[]};a.Ajax={loaded:{},loading:{},loadHooks:{},timeout:15*1000,styleDelay:1,config:{root:""},STATUS:{OK:1,ERROR:-1},rootPattern:new RegExp("^\\\\["+d+"\\\\]"),fileURL:',19,'h',102,'h.replace(this.rootPattern,this.config.root)},Require:',19,'j,m){m','=a.Callback(','m',');var k;if(j instanceof Object){for(var h in j){}k=h.toUpperCase();j=j[h]}else{k=j.split(/\\./).pop().toUpperCase()}j=this.fileURL(j);if(this.','loaded[j]){m(','this.loaded[','j',533,'var l={};l[k]=j;this.Load(l,m)}',43,'m},Load:',19,'j,l){l',940,'l',942,'loading[j]){',9,'this.loadHooks[','j]){',957,'j]=[]}',957,'j].push(l',390,'this.head=g(this.head);','if(this.loader[k]){this.loader[k].call(this,j,l',390,452,'load files of type "+k)}}',43,'l},LoadHook:',19,'j,k){k',940,'k);if(j ',104,72,'){',37,203,'j){j=j[h]}}j=','this.fileURL(','j);if(',944,'j]){k(',944,'j',533,9,957,'j]){',957,'j]=[]}',957,'j].push(k)}',43,'k},loader:{JS:',19,'i,k',30,1,7,359,'var j=','a.Callback','(["','loadTimeout','",this,i]);','this.loading','[i]={',454,':k',',message:a.Message.File(','i),timeout:',462,'j,this.timeout),status:','this.STATUS.OK',',script:h};h.onerror=j;h.type="text/javascript";h.src=i;','this.head',361,'h)},CSS:',19,'h,j){var i=',1,7,'("link");i.rel="stylesheet";','i.type="text/css";','i.href=h;',1008,'[h]={',454,':j',1012,'h),status:',1016,'};',1018,361,'i);','this.timer','.create',713,',[',1039,'.file,h],i)}},timer:{create:',19,213,'i',940,'i);if(','h.nodeName==="STYLE','"&&h','.styleSheet&&typeof(','h','.styleSheet.cssText)!=="undefined"){i','(',1016,390,'if(window.chrome&&typeof(window.sessionStorage)!=="undefined"&&',1050,'"){i(',1016,390,'if(c){','this.timer.start(this,[this.timer.','checkSafari2',',f++,','i],this.styleDelay',390,1064,'checkLength,h,',1067,')}}}',43,'i},start:',19,'i,h,j,k){h',940,'h);h',274,'=this',274,';h.time=this.time;h.STATUS=i.STATUS;h',461,'k||i.timeout;h.delay=h.total=0;',462,'h,j)},time:',19,'h){this.total+=this.delay;this.delay=Math.floor(this.delay*1.05+5);if(this.total>=this.timeout){h(','this.STATUS.ERROR',');',43,'1}',43,'0},file:',19,'i,',124,'h<0){',931,1006,'(i',390,931,'loadComplete','(i)}},execute:',45,309,713,311,',this.data[0],this.data[1])},',1065,':',19,'h,i,j){if(h.time(j)){return}if(',1,905,375,'>i&&',1,905,'[i].cssRules','&&',1,905,1121,375,'){j(h.STATUS.OK',390,462,'h,h.delay',')}},checkLength:',19,'h,k,m){if(h.time(m)){return}var l=0;var i=(k.sheet||k.styleSheet);try{if((i.cssRules||i.rules||[]).length>0){l=1}}catch(j){','if(j.message.match(/','protected variable|restricted URI/)){l=1}else{',1134,'Security error/)){l=1}}}if(l){',462,1004,'([m,h.STATUS.OK]),0',390,462,1130,')}}},',1104,':',19,34,981,'h);var i=',1008,'[h];if(i){a.Message.Clear(i.',750,'clearTimeout(','i.timeout);if(i.script){if(e',100,'0){',462,'b,0)}e.push(i.script)}',944,'h]=i.status;',238,'loading[h];',9,957,'h]){',957,'h]=[]}',957,'h].push(i.',454,390,944,'h]=',1016,';i={status:',1016,'}}',1004,'.',837,'(',957,'h],i.status)},',1006,':',19,124,1008,'[h].timeout','){',1154,1008,1190,')}',1008,'[h].status=',1089,';this.loadError(h);this.',1104,'(h)},loadError:',19,'h){a.Message.Set("File failed to load: "+h,null,2000)},Styles:',19,'j,k',30,'this.StyleString(',982,'h===""){k',940,'k);k()}else{var i=',1,7,'("style");',1026,964,1018,361,1049,'i',1052,'i',1054,'.styleSheet.cssText=h}else{i',361,1,363,'(h))}k=',1039,'.create',53,'k,i)}',43,'k},StyleString:',19,'m){',137,'(m)==="',436,43,'m}var j="",n,l;for(n in m){if(m',41,'(n)){',137,' m[n]==="',436,'j+=n+" {"+','m[n]+"}\\n"}else{if(m[n] ',104,412,37,'k=0;k<m[n].length;k++){l={};l[n]=m[n][k];j+=',1207,'l)}}else{if(n.substr(0,6)==="@media"){',1247,1207,'m[n])+"}\\n"}else{if(m[n]!=null){l',26,37,203,'m[n]){if(m[n][h]!=null){l[l',375,']=h+": "+m[n][h]}}',1247,'l.join("; ")+"}\\n"}}}}}}',43,'j}}})("MathJax");',15,'HTML={Element:',19,'c,e,d){var f=',1,7,'(c);if(e){if(e.style){',21,'e.style;e.style={};',37,'g in b){if(b',41,'(g)){e.style[g.replace(/-([a-z])/g,this.ucMatch)]=b[g]}}}',15,'Hub.Insert(f,e)}if(d){',37,'a=0;a<d',375,';a++){if(d[a] ',104,412,'f',361,'this.Element(','d[a][0],d[a][1],d[a][2]))}else{f',361,1,363,'(d[a]))}}}',43,'f},ucMatch:',19,'a,b',102,'b.toUpperCase()},addElement:',19,'b,a,d,c',102,'b',361,1291,'a,d,c))},TextNode:',19,'a',102,1,363,'(a)},addText:',19,'a,b',102,'a',361,'this.TextNode(b))},Cookie:{prefix:"mjx",expires:365,Set:',19,'a,d){var c',26,'if(d){',37,'f in d){if(d',41,'(f)){c.push(f+":"+d[f].',245,'(/&/g,"&&"))}}}',21,'this.prefix+"."+a+"="+escape(c.join("&;"));if(this.expires){var e=new Date();e.setDate(e.getDate()+this.expires);b+="; expires="+e.toGMTString()}',1,'cookie=b+"; path=/"},Get:',19,'c,h){',9,'h){h={}}var g=new RegExp("(?:^|;\\\\s*)"+this.prefix+"\\\\."+c+"=([^;]*)(?:;|$)");',21,'g.exec(',1,'cookie);if(b&&b[1]!==""){var e=unescape(b[1]).split("&;");',37,'d=0,a=e',375,';d<a;d++){b=e[d].match(/([^:]+):(.*)/);var f=b[2].replace(/&&/g,"&");if(f==="true"){f=true}else{if(f==="false"){f=false}else{if(f.match(/^-?(\\d+(\\.\\d+)?|\\.\\d+)$/)){f=parseFloat(f)}}}h[b[1]]=f}}',43,'h}}};',15,'Message={log:[{}],current:null,textNodeBug:(',900,'")||(window',41,'&&window',41,'("konqueror")),styles:{"#','MathJax_Message','":{position:"','fixed",left:"1px",bottom:"2px","background-color":"#E6E6E6",border:"1px solid #959595','",margin:"0px",padding:"','2px 8px","z-index":"102",color:"black","font-size":"80%",width:"auto","white-space":"nowrap"},"#','MathJax_MSIE_Frame',1359,'absolute",top:0,left:0,width:"0px","z-index":101,border:"0px',1361,'0px"}},browsers:{MSIE:',19,'a){','MathJax.Hub.config.styles["#MathJax_Message"].','position="absolute";',15,'Message.quirks','=(',1,'compatMode==="BackCompat")},Chrome:',19,'a){',1370,'bottom="1.5em";',1370,'left="1em"}},Init:',45,9,1,'body',102,'false}if(','this.div','&&',1389,'.parentNode==null){',1389,'=',1,2,'("',1358,334,1389,'){this.text=',1389,'.firstChild','}}',9,1389,895,1,'body;if(',15,'Hub.Browser.isMSIE){a=this.frame','=this.addDiv(',1,'body);a.style.',1371,'a.style.border=a.style.margin=a.style.padding="0px";a.style.zIndex="101";a.style.height="0px";a',1412,'a);a.id="',1363,'";','window.attachEvent("','onscroll",','this.MoveFrame',');',1421,'onresize",',1423,');',1423,'()}',1389,1412,'a);','this.div.style.display','="none";this.text=',1389,361,1,363,'(""))}',43,'true},addDiv:',19,'a){',21,1,7,'("div");b.id="',1358,'";if(a',1403,'){a.insertBefore(b,a',1403,390,'a',361,'b)}',43,'b},MoveFrame:',45,'var a=(',15,1373,'?',1,'body:',1,'documentElement);',21,15,'Message.frame;b.style.left=a.scrollLeft+"px";b.style.top=a.scrollTop+"px";b.style.width=a.clientWidth+"px";b=b',1403,';b.style.height=a.clientHeight+"px"},filterText:',19,'a,b){if(',15,'Hub.config.messageStyle','==="simple"){if(a.match(/^Loading /)){',9,1008,'){',1008,'="Loading "}a=',1008,';',1008,'+="."}else{if(a.match(/^Processing /)){',9,'this.processing','){',1489,'="Processing "}a=',1489,';',1489,'+="."}}}',43,'a},Set:',19,'b,c,a){if(',1039,'){',1154,1039,');',238,'timeout}if(c==null){c=this.log',375,';','this.log[','c]={}}',1510,'c].text=b;b=this.filterText(b,c);',137,'(','this.log[c].next',448,1516,'=','this.current',';if(',1520,201,1510,1520,'].prev=c}',1520,'=c}if(',1520,'===c&&',15,1477,'!=="none"){if(this.Init()){if(this.textNodeBug){',1389,'.innerHTML=b}else{this.text.nodeValue=b}',1434,'="";if(this.status){window.status="";',238,'status}}else{window.status=b;this.status=true}}if(a){',462,15,'Callback',769,'c]),a)}',43,'c},C'],
['lear',':function','(b,a','){if(','this.log[b].','prev','!=null','){this.','log[',4,5,'].next=',4,'next}if(',4,'next',6,7,8,4,'next].',5,'=',4,5,'}','if(this.','current','===b',7,27,'=',4,'next;',26,'text){',26,'div','.parentNode','==null',7,'Init()}',26,27,39,'){',26,'timer){clearTimeout','(this.','timer)}this.timer=setTimeout(','MathJax.Callback','(["Remove','",this',']),(a||600))}else{',26,'textNodeBug',7,'div','.innerHTML','=','this.log[this.current].text','}else{','this.text','.nodeValue','=',60,'}}',26,'status){window.status','="";','delete ','this.status}}else{',26,68,'=(this.',27,39,'?"":',60,')}}}',70,4,33,70,4,5,'},','Remove',1,'(){this.','text',63,'="";this.div','.style.display="none','"},File',1,'(b){var a=','MathJax.','Ajax','.config.','root;if(b','.substr(0,','a.length)===a){b="[','MathJax',']"+b.substr(a.length)}','return ','this.Set("Loading "+b)},Log',1,'(){var ','b=[];','for(var ','c=1,a=this.log','.length;c<a;c++){','b[c]=this.',8,'c].text}',105,'b.join("\\n")}};',97,'Hub={config:{root:"",config:[],styleSheets:[],styles:{},jax:[],','extensions',':[],','preJax',':null,','postJax',123,'displayAlign:"center",displayIndent:"0",','preRemoveClass',':"MathJax_Preview",showProcessingMessages:true,messageStyle:"normal",','delayStartupUntil',':"none",','skipStartupTypeset',':false,','preProcessors',':[],','inputJax',':{},','outputJax',':{},menuSettings:{zoom:"None",CTRL:false,ALT:false,CMD:false,Shift:false,zscale:"200%",renderer:"",font:"Auto",context:"',103,'"},','errorSettings',':{message:["[Math Processing Error]"],style:{color:"#CC0000","font-style":"italic"}}},','processUpdateTime',':250,signal:',50,'.Signal("','Hub"),','Config',1,'(a){','this','.Insert(','this.config',',a);if(','this.config.','Augment',7,156,'(',155,156,')}},','Register',':{PreProcessor',1,150,'MathJax.Hub.config','.',133,'.push(',50,'(a))},','MessageHook',1,'(){return ',97,'Hub','.signal.',173,'.apply(',97,'Hub','.signal,arguments)},','StartupHook',1,175,'MathJax.Hub.Startup',178,173,180,187,183,'LoadHook',1,175,97,'Ajax.',193,180,97,'Ajax,','arguments',162,'getAllJax',1,'(','e){var c=[],b=this.elementScripts(e);for(var d=0,a=b.length;d<a;d++){if(b[d].MathJax&&b[d].MathJax.elementJax','){c.push(b[d].','MathJax.elementJax',')}}return c},','getJaxByType',1,'(f,',207,'&&b[d].',209,'.mimeType','===f){c.push(b[d].',209,210,'getJaxByInputType',1,'(f,',207,215,'type',215,'type.replace(/ *;(.|\\','s)*/,"")===f){c.push(b[d].',209,210,'getJaxFor',1,150,'if(typeof(a)==="string"){a=document.getElementById(a',')}','if(a.MathJax','){return ','a.',209,'}',105,'null},isJax',1,150,235,')}','if(a.tagName!=null&&a.tagName.toLowerCase()==="script"){',237,'){return(a','.MathJax.state','===',103,'.ElementJax.','STATE','.PROCESSED','?1:-1)}if(a.type&&',155,135,'[a.',228,'s)*/,"")]){return -1}}',105,'0},Queue',1,175,'this.queue.Push',180,'this.queue,',202,')},Typeset',1,'(b,c){if(!',97,'isReady',238,'null}var ','a','=this.elementCallback(','b,c);',105,50,'.Queue(["','PreProcess','",this,a.element','],["','Process',285,']).','Push(a.callback)},',284,1,'(b,c){var a',279,'b,c);',105,50,283,'Post",this.signal,"','Begin ',284,'"],["ExecuteHooks",',50,',(','arguments.callee.disabled','?[]:',155,133,'),a.element,true],["',299,'End ',284,'"]).',290,287,1,'(a,b){return this.takeAction("',287,'",a,b)},','Update',1,317,320,319,'Reprocess',1,317,325,319,'takeAction',1,'(d,c,e){var b',279,'c,e);var a=[];',105,50,283,'Clear',52,'.signal','],["Post",this.signal,["','Begin "+d,b.element]],["','prepareScripts',52,',d,b.element,a],["','processScripts',52,',a',341,'End "+d,b.element]]).Push(b.callback)},','scriptAction',':{',287,1,'(a){},',320,1,96,'b.',209,';if(a&&a.','originalText','===(b.text==""?b',58,':b.text)){b',251,'=a.STATE',256,61,'a.',137,'.Remove(','a);b',251,'=a.STATE.UPDATE','}},',325,1,96,'b.',209,';if',150,'a.',137,372,'a);b',251,375,'}}},',343,1,'(h,e,f',3,305,'){return}var b=this.','elementScripts','(e);var g=',103,254,'STATE;',110,'d=0,a=b.length;d<a;d++){var c=b[d];if(c.type&&',155,135,'[c.',228,'n)*/,"")]){if(c.',103,'&&c',251,'!==g.PENDING',7,351,'[h](c)}if(!c.',103,'){c.',103,'={state:g.PENDING}}if(c',251,'!==g',256,'){f.push(c)}}}},','checkScriptSiblings',1,150,237,'&&a.',97,'checked',396,'config;var g=a','.previousSibling',';if(g&&g.nodeName=="#text"){var d,f;var c=a.nextSibling;if(c&&c.nodeName!="#text"){c=null}if','(b.preJax',3,'typeof',435,')==="string"){b.',122,'=new RegExp',435,'+"$")}d=g',63,'.match',435,')}if(b.',124,'&&c',3,'typeof(b.',124,439,124,441,'("^"+b.',124,')}f=c',63,'.match(b.',124,')}if(d&&(!b.',124,'||f)){g',63,'=g',63,'.replace',435,',(d.length>1?d[1]:""));g=null}if(f&&(!b.',122,'||d)){c',63,'=c',63,468,'(b.',124,',(f.length>1?f[1]:""))}if(g&&!g',63,'.match(/\\S/)){','g=g',433,'}}if(b.',127,'&&g&&g.className==b.',127,'){try{g',58,'=""}catch(e){}g',93,'"}',237,'){a.',97,430,'=1}},',346,1,'(h,b,d',3,305,238,277,'q,o=',103,254,401,'var p=',155,135,',c=',155,137,';try{if(!b){b=','new Date().getTime','()}var j=0,l,f;while(j<h.length){l=h[j];if(!l){continue}f=l',433,';if(f&&f.className==="','MathJax_Error','"){f',38,'.removeChild(f)}var k=l.',228,'s)*/,"");if(!l.',103,'||l',251,'===o',256,'){continue}if(!l.',209,'||l',251,'===o.UPDATE',7,424,'(l);q=p[k].','Translate(l);if(typeof q==="function"){','if(q.called){continue}this.RestartAfter(q)}','q.Attach(l,p[k])}var a=l.',209,';if(!c[a',217,']){l',251,'=o.UPDATE;','throw Error','("No output jax registered for "+a',217,')}a.',137,'=c[a',217,'][0];q=a.',137,'.',539,'l',251,547,540,'l',251,'=o',256,';this',178,'Post(["New Math",a.inputID]);j++;if(',516,'()-b>this.',143,'&&j<h.length){b=0;this.','RestartAfter','(',50,'.Delay(1))}}}catch(g){if(!g.restart){if(!',155,141,'.message){throw g}this.formatError(l,g);j++}if(!d){d=0}var e=Math.floor((d+j)/(d+h.length)*100);d+=j;if(',155,'showProcessingMessages){MathJax.Message.Set("Processing ','math: "+e+"%",0)}',105,50,'.After(["',346,52,',h.slice(j),b,d],g.restart)}if((d||h.length)&&',155,582,'Math: 100%",0);',97,'Message.','Clear(0)}',105,'null},formatError',1,'(a,c){var b=',97,'HTML.Element("span",{className:"',520,'"},',155,141,'.message);a',38,'.insertBefore',2,');this.lastError=c},',574,1,150,'throw this',152,'Error("restart"),{restart:',50,'(a)})},elementCallback',1,'(a,b',3,'b',39,'&&(a ','instanceof Array','||typeof a==="','function','")){b=a;a=','document.','body',61,'if(a==null){a=document.body}','else{',235,')}}}if(!a){',548,'("No such element")}if(!b){b={}}return{element:a,callback:b}},',397,1,150,235,')}',632,248,'return[a]}',105,'a.','getElementsByTagName("','script")},Insert',1,'(c,a){',110,'b in a',3,'a','.hasOwnProperty','(b)){if(typeof a[b]==="object"&&!(a[b] ',625,')&&(','typeof c[b]==="','object"||',660,627,'")){this',152,'c[b],a[b])}else{c[b]=a[b]}}}',105,'c}};',97,'Hub',152,167,'.styles',',',97,594,'styles);',97,'Hub',152,167,673,',{".',520,'":',167,'.',141,'.style});',97,'Extension={};',187,'={script:"",queue:',50,'.Queue(),','signal:',50,146,'Startup','"),',148,1,'(){','this.queue.Push(["',299,300,148,'"]);var b=',97,'HTML.Cookie','.Get("user");if(b.URL||b.',148,3,'confirm("',103,' has found a user-configuration cookie that includes code to be run. Do you want to run it?\\n\\n(You should press Cancel unless you set up the cookie yourself.)")){if(b.URL){',704,'Require",MathJax.Ajax,','b.URL])}if(b.',148,'){',97,'userConfig=new Function(b.',148,')}}else{',97,710,'.Set("user",{})}}',26,'script',481,267,48,'script+";\\n1;")}else{',26,'params&&this.params.config){var d=this.params',99,'split(/,/);',110,'c=0,a=d',112,'if(!d[c].match(/\\.js$/)){d[c]+=".js"}',704,718,'this.URL("config','",d[c])])}}else{',704,718,745,'","',97,'js")])}}',105,267,'([',627,'(e,f',3,'e.',129,'.isCallback',238,'e.',129,'}if(e.',129,'==="onload"){',105,'f}',105,627,'(){}},',167,',this.onload','],[function(','e',238,'e.','loadArray','(',167,'.config,"config",null,true)},this],["',299,'End ',148,'"])},Cookie',1,175,704,299,300,'Cookie"],["Get",',97,710,',"menu",',167,'.menuSettings',775,'f,c',3,'f.renderer){var d="output/"+f.renderer;',110,'e=0,b=c.length,a','=0;e<b;e++){if(','c[e]===d){c.splice(e,1);a=0;break}if(c','[e].substr(0,7)==="output/"){','a=(a?0:e+1)}}c.unshift(d);if',150,'c.splice(a,1)}}},',167,797,',',167,'.jax],["',299,'End Cookie"])},Styles',1,175,704,299,300,'Styles','"],["loadArray",this,',167,'.styleSheets,"config"],["Styles",',97,201,167,673,'],["',299,'End Styles"])},Jax',1,108,'d=',167,';d.',137,'.order={};',110,'e=0,b=d.jax.length,c',804,'d.jax',806,'d.',137,'.order[d.jax[e].substr(7)]=c;c++}}var a=',50,'.Queue();',105,'a','.Push(["',299,300,'Jax',823,'d.jax,"jax","config.js"],["',299,'End Jax"])},','Extensions',1,108,'a=',50,849,105,'a',852,299,300,860,823,167,'.',120,',"',120,'"],["',299,'End ',860,'"])},onLoad',1,150,'var b=this.onload=',50,'(','function(){',187,178,'Post("onLoad")});if(','window.addEventListener','){',892,'("load",b,false)}else{if(','window.attachEvent','){',896,'("onload",b)}else{window.onload=b}}',105,'b},Typeset',1,'(a,b',3,167,'.',131,238,627,'(){}}',105,704,299,300,'Typeset"],["Typeset",',97,'Hub,a,b],["',299,'End Typeset"])},URL',1,2,'){if(!a.match(/^([a-z]+:\\/\\/|\\[|\\/)/)){a="[',103,']/"+b+"/"+a}',105,'a},',779,1,'(b,f,c,a',3,'b){if(!(b ',625,')){b=[b]}if(b.length){var h=',50,695,'j={},e;',110,'g=0,d=b.length;g<d;g++){e=this.URL(f,b[g]);if(c){e+="/"+c}if',150,'h',852,718,'e,j])}else{h.Push(',97,'Ajax.Require(e,j))}}',105,'h.Push({})}}',105,'null}};(',627,'(d){var b=window[d],e="["+d+"]";var c=b.Hub,a=b.',201,'f=b.Callback;var g=',97,'Object.Subclass({','require',123,'config:{},Init',1,'(i,h',3,202,'.length===0',238,'this}return(','this.constructor.Subclass(i,h','))()},',156,1,'(k,j){var i=this.constructor,h={};if(k',6,'){',110,'l in k',3,'k',656,'(l)){if(typeof k[l]==="',627,'"){','i.protoFunction','(l,k[l])}else{h[l]=k[l]}}}if(k.toString!==i.','prototype.','toString&&k.toString!=={}.toString){',981,'("toString",k.toString)}}c',152,'i.prototype,h);i.',156,'(null,j);',105,'this},','Translate',1,'(h','){this.constructor.prototype.Translate=this.noTranslate;',105,'a.Require','(this.directory+"/jax.js','")},noTranslate',1,'(h){',548,999,' failed to redefine the ',993,'() method")},',163,1,'(h){},',148,1,'(){c',152,153,',(c.config[this.id]||{}));if(',155,156,7,156,'(',155,156,162,699,1,'(){},','loadComplete',1,'(n',3,'n==="jax.js"){var j=f',849,'j.Push(["Post",c.Startup.signal,this.id+" Jax ',148,'"]);j',852,148,52,']);',1034,'Require"]);',26,956,'){','var k=this.',956,';if(!(k instanceof Array)){k=[k]}for(var ','l=0,h=k.length;l<h;l++){','j.Push(a.Require(','k[l]))}j',852,779,'",',187,',',155,956,',"config"])}',1034,699,'"]);j',852,699,52,']);',1034,'Ready"]);',105,'j',852,1028,'",a,this.','directory+"/"+','n])}else{',105,'a.',1028,48,1074,'n)}}},{id:"unknown",','version:"1.0.1",directory:','e+"/jax",extensionDir:e+"/',120,'"});b.InputJax','=g.Subclass','({','elementJax',':"mml",',993,1,'(o',996,'var j=f',849,1046,1088,1048,'n=0,h=k','.length;n<h;n++){var ','l=b',254,1074,'k[n]+"/jax.js";','if(!this.require){this.require=[]}else{if(!(this.require instanceof Array)){this.require=[this.require]}}this.require.push(','l);',1050,'l))}j.Push(a.Require',999,'"));k=c',99,137,'["jax/"+k[0]];if(k){',1050,'k[0].directory+"/jax.js"))}',105,'j.Push({})},',163,1,'(h){if(!b.Hub',99,135,'){c',99,135,'={}}c',99,135,'[h]=this}},{',1082,'g.directory+"/','input','",extensionDir:g.extensionDir','});b.OutputJax',1086,'({',163,1,'(i){var h=c',99,137,';if(!h[i]){h[i]=[];if(!','c.config.menuSettings.renderer','){',1143,'=this.id}}if(h[i].length&&(h.order[this.id]||0)<(h.order[h[i][0].id]||0)){h[i].unshift(this)}else{h[i].push(this)}',1105,'b',254,'directory+"/"+(i.split(/\\//)[1])+"/jax.js")},',87,1,'(h){}},{',1082,1131,'output',1133,',fontDir:e+(b.isPacked?"":"/..")+"/fonts"});b.ElementJax',1086,'({Init',1,960,238,966,')},',135,123,137,123,'inputID',123,362,':"",mimeType:"",Text',1,'(j,k){','var h=this.SourceElement();','if(','h.firstChild',3,1178,'.nodeName!=="#text"){h.text=j',61,1178,63,'=j}}else{try{h',58,'=j','}catch(i){h.','text=j}}h',251,'=this.STATE.UPDATE;return c.',320,'(h,k)},',325,1,'(i){',1176,'h',251,1191,325,'(h,i)},',87,1,89,137,372,'this);c',178,'Post',51,' Math",','this.inputID',']);this.Detach()},SourceElement',1,175,629,'getElementById(',1213,')},Attach',1,'(i,j){var h=i.',209,';if(i',251,'===this.STATE.UPDATE){h.Clone(this)}else{h=i.',209,'=this;if(i.id',7,'inputID=i.id',61,'i.id=',1213,'=b',254,'GetID();this.newID=1}}h.',362,'=(i.text==""?i',58,':i.text);h.',135,'=j},Detach',1,'(){',1176,'if(!h){return}try{',70,'h.',103,1188,103,'=null}',26,'newID){h.id=""}},Clone',1,'(h){var i;for(i in this){if(!this',656,'(i)){continue}if(typeof(','h','[i])==="undefined','"&&i!=="newID"){',70,'this[i]}}for(i in h){if(!this',656,1258,'this',1260,'"||(this[i]!==h[i]&&i!=="inputID")){this[i]=h[i]}}}},{version:"1.0",directory:',1131,'element',1133,',ID:0,STATE:{PENDING:1,PROCESSED:2,UPDATE:3},GetID',1,89,'ID++;return"',103,'-Element-"+this.ID},Subclass',1,108,'h',1086,180,'this,',202,');h.',1028,'=this.',983,1028,';',105,'h}});b',254,983,'STATE=b',254,'STATE})("',103,'");(',627,'(l){var f=window[l];if(!f){f=window[l]={}}var c=f.Hub;var q=c.',699,';var u=c.config;var e=',629,648,'head")[0];if(!e){e=',629,'childNodes[0]}var b=(',629,'documentElement||document).',648,'script");var d',441,'("(^|/)"+l+"\\\\.js(\\\\?.*)?$");',110,'o=b.length-1;o>=0;o--){if(b[o].src.match(d)){q.script=b[o].innerHTML;if(RegExp.$2){q.params={};var r=RegExp.$2.substr(1).split(/\\&/);',110,'n=0,h=r',1100,'k=r[n].match(/(.*)=(.*)/);if(k){q.params[unescape(k[1])]=unescape(k[2])}}}u.root=b[o].src',468,'(/(^|\\/)[^\\/]*$/,"");break}}f.Ajax.config=u;var a={isMac',':(navigator.platform.substr(0,3)==="','Mac"),isPC',1323,'Win"),isMSIE:(window.ActiveXObject','!=null&&window.','clipboardData',6,'),isFirefox:(window.netscape',6,'&&',629,'ATTRIBUTE_NODE',1327,'opera',39,'),isSafari:(','navigator.userAgent.','match(/ (Apple)?WebKit\\//)!=null&&','window.chrome',39,'),isChrome:(',1341,1327,'chrome.loadTimes',6,'),isOpera:(window.opera',1327,'opera.version',6,'),isKonqueror:(window',656,'&&window',656,'("konqueror")&&navigator.vendor=="KDE"),versionAtLeast',1,'(x){var w=(this','.version).split','(".");x=(','new String','(x)).split(".");',110,'y=0,j=x.length;y<j;y++){if(w[y]!=x[y]){',105,'parseInt(w[y]||"0")>=parseInt(x[y])}}',105,'true},Select',1,'(j){var i=','j[c.Browser];if(i',238,'i(c.Browser)}',105,'null}};var g=',1339,'replace(/^Mozilla\\/(\\d+\\.)+\\d+ /,"").replace(/[a-z][-a-z0-9._: ]+\\/\\d+[^ ]*-[^ ]*\\.([a-z][a-z])?\\d+ /i,"").replace(/Gentoo |Ubuntu\\/(\\d+\\.)*\\d+ (\\([^)]*\\) )?/,"");c.Browser=c',152,'c',152,1361,'("Unknown"),{version:"0.0"}),a);',110,'t in a',3,'a',656,'(t)){if(a[t]&&t',101,'2)==="is"){t=t.slice(2);if(t==="Mac"||t==="PC"){continue}c.Browser=c',152,1361,'(t),a);var p',441,'(".*(Version',')/((?:\\\\d+\\\\.)+\\\\d','+)|.*("+t+")"+(t=="MSIE"?" ":"/")+"((?:\\\\d+\\\\.)*\\\\d+)|(?:^|\\\\(| )([a-z][-a-z0-9._: ]+|WebKit',1396,'+)");var s=p.exec(g)||["","","","unknown","0.0"];c.Browser.name=(s[1]=="Version"?t:(s[3]||s[5]));c.Browser.version=s[2]||s[4]||s[6];break}}}','c.Browser.Select','({Safari',1,1370,'parseInt((String(j',1359,'("."))[0]);if(i>=526){','j.version="','4.0','"}else{if(i','>=525){',1407,'3.1',1409,'>500){',1407,'3.0',1409,'>400){',1407,'2.0',1409,'>85){',1407,'1.0"}}}}}},Firefox',1,'(j',3,'j.version==="0.0"&&navigator.product==="Gecko"&&','navigator.productSub','){var i=',1429,101,'8);if(i>="20090630"){',1407,'3.5',1409,'>="20080617"){',1407,'3.0',1409,'>="20061024"){',1407,'2.0"}}}}},Opera',1,'(i){i.version=',1350,'()}});',1400,'(',97,594,'browsers);c.queue=f.Callback',849,'c.queue',852,'Post",q.signal,"','Begin"],["',148,'",q],["Cookie",q],["Styles",q],',888,'var i=f.Callback.Queue(q.Jax(),q.',860,'());',105,'i.Push({})},q.onLoad(),',888,97,275,'=true},["Typeset",q],["',1456,'End"])})("',103,'")}};']
]);