From b0fd920efbb4f5cd5e5ba7e4628fa1f03a431d62 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Thu, 19 Jan 2012 20:56:10 -0500 Subject: [PATCH] Fix a timing problem with mobile devices when combined configurations are used --- config/Accessible-full.js | 2 +- config/Accessible.js | 2 +- config/MML_HTMLorMML-full.js | 2 +- config/MML_HTMLorMML.js | 2 +- config/TeX-AMS-MML_HTMLorMML-full.js | 2 +- config/TeX-AMS-MML_HTMLorMML.js | 2 +- config/TeX-AMS_HTML-full.js | 2 +- config/TeX-AMS_HTML.js | 2 +- extensions/MathMenu.js | 2 +- unpacked/extensions/MathMenu.js | 28 ++++++++++++++-------------- 10 files changed, 23 insertions(+), 23 deletions(-) diff --git a/config/Accessible-full.js b/config/Accessible-full.js index 79bea3081..d764ba706 100644 --- a/config/Accessible-full.js +++ b/config/Accessible-full.js @@ -69,7 +69,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/Accessible.js b/config/Accessible.js index 0d5e07658..c3549f09e 100644 --- a/config/Accessible.js +++ b/config/Accessible.js @@ -66,7 +66,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/MML_HTMLorMML-full.js b/config/MML_HTMLorMML-full.js index 4968d2be4..72bec0ff9 100644 --- a/config/MML_HTMLorMML-full.js +++ b/config/MML_HTMLorMML-full.js @@ -47,7 +47,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/MML_HTMLorMML.js b/config/MML_HTMLorMML.js index 6586ae419..8ff48adde 100644 --- a/config/MML_HTMLorMML.js +++ b/config/MML_HTMLorMML.js @@ -44,7 +44,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/TeX-AMS-MML_HTMLorMML-full.js b/config/TeX-AMS-MML_HTMLorMML-full.js index a95352092..274ee8cbe 100644 --- a/config/TeX-AMS-MML_HTMLorMML-full.js +++ b/config/TeX-AMS-MML_HTMLorMML-full.js @@ -58,7 +58,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/TeX-AMS-MML_HTMLorMML.js b/config/TeX-AMS-MML_HTMLorMML.js index c50a85e3e..a6eddc58b 100644 --- a/config/TeX-AMS-MML_HTMLorMML.js +++ b/config/TeX-AMS-MML_HTMLorMML.js @@ -55,7 +55,7 @@ MathJax.Extension.mml2jax={version:"1.1.2",config:{preview:"alttext"},MMLnamespa (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/TeX-AMS_HTML-full.js b/config/TeX-AMS_HTML-full.js index c6f60f395..88e1655b4 100644 --- a/config/TeX-AMS_HTML-full.js +++ b/config/TeX-AMS_HTML-full.js @@ -42,7 +42,7 @@ MathJax.Extension.tex2jax={version:"1.1.5",config:{inlineMath:[["\\(","\\)"]],di (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/config/TeX-AMS_HTML.js b/config/TeX-AMS_HTML.js index c81cb1c2d..fd93e052f 100644 --- a/config/TeX-AMS_HTML.js +++ b/config/TeX-AMS_HTML.js @@ -40,7 +40,7 @@ MathJax.Extension.tex2jax={version:"1.1.5",config:{inlineMath:[["\\(","\\)"]],di (function(a,d,f,c,j){var k="1.1.4";var i=a.CombineConfig("MathZoom",{styles:{"#MathJax_Zoom":{position:"absolute","background-color":"#F0F0F0",overflow:"auto",display:"block","z-index":301,padding:".5em",border:"1px solid black",margin:0,"font-weight":"normal","font-style":"normal","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","box-shadow":"5px 5px 15px #AAAAAA","-webkit-box-shadow":"5px 5px 15px #AAAAAA","-moz-box-shadow":"5px 5px 15px #AAAAAA","-khtml-box-shadow":"5px 5px 15px #AAAAAA",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},"#MathJax_ZoomOverlay":{position:"absolute",left:0,top:0,"z-index":300,display:"inline-block",width:"100%",height:"100%",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"},"#MathJax_ZoomEventTrap":{position:"absolute",left:0,top:0,"z-index":302,display:"inline-block",border:0,padding:0,margin:0,"background-color":"white",opacity:0,filter:"alpha(opacity=0)"}}});var e,b,g;MathJax.Hub.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event;e=MathJax.Extension.MathEvents.Event.False;b=MathJax.Extension.MathEvents.Hover});var h=MathJax.Extension.MathZoom={version:k,settings:a.config.menuSettings,scrollSize:18,HandleEvent:function(n,l,m){if(h.settings.CTRL&&!n.ctrlKey){return true}if(h.settings.ALT&&!n.altKey){return true}if(h.settings.CMD&&!n.metaKey){return true}if(h.settings.Shift&&!n.shiftKey){return true}if(!h[l]){return true}return h[l](n,m)},Click:function(m,l){if(this.settings.zoom==="Click"){return this.Zoom(m,l)}},DblClick:function(m,l){if(this.settings.zoom==="Double-Click"){return this.Zoom(m,l)}},Hover:function(m,l){if(this.settings.zoom==="Hover"){this.Zoom(m,l);return true}return false},Zoom:function(n,s){this.Remove();b.ClearHoverTimer();g.ClearSelection();var q=MathJax.OutputJax[s.jaxID];var o=q.getJaxFromMath(s);if(o.hover){b.UnHover(o)}var l=Math.floor(0.85*document.body.clientWidth),r=Math.floor(0.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));var m=d.Element("span",{style:{position:"relative",display:"inline-block",height:0,width:0},id:"MathJax_ZoomFrame"},[["span",{id:"MathJax_ZoomOverlay",onmousedown:this.Remove}],["span",{id:"MathJax_Zoom",onclick:this.Remove,style:{visibility:"hidden",fontSize:this.settings.zscale,"max-width":l+"px","max-height":r+"px"}},[["span",{style:{display:"inline-block","white-space":"nowrap"}}]]]]);var x=m.lastChild,u=x.firstChild,p=m.firstChild;s.parentNode.insertBefore(m,s);if(u.addEventListener){u.addEventListener("mousedown",this.Remove,true)}if(this.msieTrapEventBug){var w=d.Element("span",{id:"MathJax_ZoomEventTrap",onmousedown:this.Remove});m.insertBefore(w,x)}if(this.msieZIndexBug){var t=d.addElement(document.body,"img",{src:"about:blank",id:"MathJax_ZoomTracker",width:0,height:0,style:{width:0,height:0,position:"relative"}});m.style.position="relative";m.style.zIndex=i.styles["#MathJax_ZoomOverlay"]["z-index"];m=t}var v=q.Zoom(o,u,s,l,r);if(this.msiePositionBug){if(this.msieSizeBug){x.style.height=v.zH+"px";x.style.width=v.zW+"px"}if(x.offsetHeight>r){x.style.height=r+"px";x.style.width=(v.zW+this.scrollSize)+"px"}if(x.offsetWidth>l){x.style.width=l+"px";x.style.height=(v.zH+this.scrollSize)+"px"}}if(this.operaPositionBug){x.style.width=Math.min(l,v.zW)+"px"}if(x.offsetWidth=9);h.msiePositionBug=!m;h.msieSizeBug=l.versionAtLeast("7.0")&&(!document.documentMode||n===7||n===8);h.msieZIndexBug=(n<=7);h.msieInlineBlockAlignBug=(n<=7);h.msieTrapEventBug=!window.addEventListener;if(document.compatMode==="BackCompat"){h.scrollSize=52}if(m){delete i.styles["#MathJax_Zoom"].filter}},Opera:function(l){h.operaPositionBug=true;h.operaRefreshBug=true}});h.topImg=(h.msieInlineBlockAlignBug?d.Element("img",{style:{width:0,height:0,position:"relative"},src:"about:blank"}):d.Element("span",{style:{width:0,height:0,display:"inline-block"}}));if(h.operaPositionBug||h.msieTopBug){h.topImg.style.border="1px solid"}MathJax.Callback.Queue(["StartupHook",MathJax.Hub.Register,"Begin Styles",{}],["Styles",f,i.styles],["Post",a.Startup.signal,"MathZoom Ready"],["loadComplete",f,"[MathJax]/extensions/MathZoom.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.OutputJax["HTML-CSS"],MathJax.OutputJax.NativeMML); -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); MathJax.ElementJax.mml=MathJax.ElementJax({mimeType:"jax/mml"},{id:"mml",version:"1.1.4",directory:MathJax.ElementJax.directory+"/mml",extensionDir:MathJax.ElementJax.extensionDir+"/mml",optableDir:MathJax.ElementJax.directory+"/mml/optable"});MathJax.ElementJax.mml.Augment({Init:function(){if(arguments.length===1&&arguments[0].type==="math"){this.root=arguments[0]}else{this.root=MathJax.ElementJax.mml.math.apply(this,arguments)}if(this.root.mode){if(!this.root.display&&this.root.mode==="display"){this.root.display="block"}delete this.root.mode}}},{INHERIT:"_inherit_",AUTO:"_auto_",SIZE:{INFINITY:"infinity",SMALL:"small",NORMAL:"normal",BIG:"big"},COLOR:{TRANSPARENT:"transparent"},VARIANT:{NORMAL:"normal",BOLD:"bold",ITALIC:"italic",BOLDITALIC:"bold-italic",DOUBLESTRUCK:"double-struck",FRAKTUR:"fraktur",BOLDFRAKTUR:"bold-fraktur",SCRIPT:"script",BOLDSCRIPT:"bold-script",SANSSERIF:"sans-serif",BOLDSANSSERIF:"bold-sans-serif",SANSSERIFITALIC:"sans-serif-italic",SANSSERIFBOLDITALIC:"sans-serif-bold-italic",MONOSPACE:"monospace",INITIAL:"inital",TAILED:"tailed",LOOPED:"looped",STRETCHED:"stretched",CALIGRAPHIC:"-tex-caligraphic",OLDSTYLE:"-tex-oldstyle"},FORM:{PREFIX:"prefix",INFIX:"infix",POSTFIX:"postfix"},LINEBREAK:{AUTO:"auto",NEWLINE:"newline",NOBREAK:"nobreak",GOODBREAK:"goodbreak",BADBREAK:"badbreak"},LINEBREAKSTYLE:{BEFORE:"before",AFTER:"after",DUPLICATE:"duplicate",INFIXLINBREAKSTYLE:"infixlinebreakstyle"},INDENTALIGN:{LEFT:"left",CENTER:"center",RIGHT:"right",AUTO:"auto",ID:"id",INDENTALIGN:"indentalign"},INDENTSHIFT:{INDENTSHIFT:"indentshift"},LINETHICKNESS:{THIN:"thin",MEDIUM:"medium",THICK:"thick"},NOTATION:{LONGDIV:"longdiv",ACTUARIAL:"actuarial",RADICAL:"radical",BOX:"box",ROUNDEDBOX:"roundedbox",CIRCLE:"circle",LEFT:"left",RIGHT:"right",TOP:"top",BOTTOM:"bottom",UPDIAGONALSTRIKE:"updiagonalstrike",DOWNDIAGONALSTRIKE:"downdiagonalstrike",VERTICALSTRIKE:"verticalstrike",HORIZONTALSTRIKE:"horizontalstrike",MADRUWB:"madruwb"},ALIGN:{TOP:"top",BOTTOM:"bottom",CENTER:"center",BASELINE:"baseline",AXIS:"axis",LEFT:"left",RIGHT:"right"},LINES:{NONE:"none",SOLID:"solid",DASHED:"dashed"},SIDE:{LEFT:"left",RIGHT:"right",LEFTOVERLAP:"leftoverlap",RIGHTOVERLAP:"rightoverlap"},WIDTH:{AUTO:"auto",FIT:"fit"},ACTIONTYPE:{TOGGLE:"toggle",STATUSLINE:"statusline",TOOLTIP:"tooltip",INPUT:"input"},LENGTH:{VERYVERYTHINMATHSPACE:"veryverythinmathspace",VERYTHINMATHSPACE:"verythinmathspace",THINMATHSPACE:"thinmathspace",MEDIUMMATHSPACE:"mediummathspace",THICKMATHSPACE:"thickmathspace",VERYTHICKMATHSPACE:"verythickmathspace",VERYVERYTHICKMATHSPACE:"veryverythickmathspace",NEGATIVEVERYVERYTHINMATHSPACE:"negativeveryverythinmathspace",NEGATIVEVERYTHINMATHSPACE:"negativeverythinmathspace",NEGATIVETHINMATHSPACE:"negativethinmathspace",NEGATIVEMEDIUMMATHSPACE:"negativemediummathspace",NEGATIVETHICKMATHSPACE:"negativethickmathspace",NEGATIVEVERYTHICKMATHSPACE:"negativeverythickmathspace",NEGATIVEVERYVERYTHICKMATHSPACE:"negativeveryverythickmathspace"},OVERFLOW:{LINBREAK:"linebreak",SCROLL:"scroll",ELIDE:"elide",TRUNCATE:"truncate",SCALE:"scale"},UNIT:{EM:"em",EX:"ex",PX:"px",IN:"in",CM:"cm",MM:"mm",PT:"pt",PC:"pc"},TEXCLASS:{ORD:0,OP:1,BIN:2,REL:3,OPEN:4,CLOSE:5,PUNCT:6,INNER:7,VCENTER:8,NONE:-1},TEXCLASSNAMES:["ORD","OP","BIN","REL","OPEN","CLOSE","PUNCT","INNER","VCENTER"],copyAttributes:{fontfamily:true,fontsize:true,fontweight:true,fontstyle:true,color:true,background:true,id:true,"class":true,href:true,style:true},skipAttributes:{texClass:true,useHeight:true,texprimestyle:true},copyAttributeNames:["fontfamily","fontsize","fontweight","fontstyle","color","background","id","class","href","style"]});(function(a){a.mbase=MathJax.Object.Subclass({type:"base",isToken:false,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT},noInherit:{},noInheritAttribute:{texClass:true},linebreakContainer:false,Init:function(){this.data=[];if(this.inferRow&&!(arguments.length===1&&arguments[0].inferred)){this.Append(a.mrow().With({inferred:true}))}this.Append.apply(this,arguments)},With:function(d){for(var e in d){if(d.hasOwnProperty(e)){this[e]=d[e]}}return this},Append:function(){if(this.inferRow&&this.data.length){this.data[0].Append.apply(this.data[0],arguments)}else{for(var e=0,d=arguments.length;e0&&this.Get("scriptlevel")>0&&f>=0){return""}return this.TEXSPACELENGTH[Math.abs(f)]},TEXSPACELENGTH:["",a.LENGTH.THINMATHSPACE,a.LENGTH.MEDIUMMATHSPACE,a.LENGTH.THICKMATHSPACE],TEXSPACE:[[0,-1,2,3,0,0,0,1],[-1,-1,0,3,0,0,0,1],[2,2,0,0,2,0,0,2],[3,3,0,0,3,0,0,3],[0,0,0,0,0,0,0,0],[0,-1,2,3,0,0,0,1],[1,1,0,1,1,1,1,1],[1,-1,2,3,1,0,1,1]],autoDefault:function(d){return""},isSpacelike:function(){return false},isEmbellished:function(){return false},Core:function(){return this},CoreMO:function(){return this},hasNewline:function(){if(this.isEmbellished()){return this.CoreMO().hasNewline()}if(this.isToken||this.linebreakContainer){return false}for(var e=0,d=this.data.length;e=55296&&d.charCodeAt(0)<56320)?a.VARIANT.ITALIC:a.VARIANT.NORMAL)}return""}});a.mn=a.mbase.Subclass({type:"mn",isToken:true,texClass:a.TEXCLASS.ORD,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT}});a.mo=a.mbase.Subclass({type:"mo",isToken:true,defaults:{mathvariant:a.INHERIT,mathsize:a.INHERIT,mathbackground:a.INHERIT,mathcolor:a.INHERIT,form:a.AUTO,fence:a.AUTO,separator:a.AUTO,lspace:a.AUTO,rspace:a.AUTO,stretchy:a.AUTO,symmetric:a.AUTO,maxsize:a.AUTO,minsize:a.AUTO,largeop:a.AUTO,movablelimits:a.AUTO,accent:a.AUTO,linebreak:a.LINEBREAK.AUTO,lineleading:a.INHERIT,linebreakstyle:a.AUTO,linebreakmultchar:a.INHERIT,indentalign:a.INHERIT,indentshift:a.INHERIT,indenttarget:a.INHERIT,indentalignfirst:a.INHERIT,indentshiftfirst:a.INHERIT,indentalignlast:a.INHERIT,indentshiftlast:a.INHERIT,texClass:a.AUTO},defaultDef:{form:a.FORM.INFIX,fence:false,separator:false,lspace:a.LENGTH.THICKMATHSPACE,rspace:a.LENGTH.THICKMATHSPACE,stretchy:false,symmetric:true,maxsize:a.SIZE.INFINITY,minsize:"0em",largeop:false,movablelimits:false,accent:false,linebreak:a.LINEBREAK.AUTO,lineleading:"1ex",linebreakstyle:"before",indentalign:a.INDENTALIGN.AUTO,indentshift:"0",indenttarget:"",indentalignfirst:a.INDENTALIGN.INDENTALIGN,indentshiftfirst:a.INDENTSHIFT.INDENTSHIFT,indentalignlast:a.INDENTALIGN.INDENTALIGN,indentshiftlast:a.INDENTSHIFT.INDENTSHIFT,texClass:a.TEXCLASS.REL},SPACE_ATTR:{lspace:1,rspace:2,form:4},useMMLspacing:7,autoDefault:function(f,l){var k=this.def;if(!k){if(f==="form"){this.useMMLspacing&=~this.SPACE_ATTR.form;return this.getForm()}var j=this.data.join("");var e=[this.Get("form"),a.FORM.INFIX,a.FORM.POSTFIX,a.FORM.PREFIX];for(var g=0,d=e.length;g=55296&&j<56320){j=(((j-55296)<<10)+(h.charCodeAt(1)-56320))+65536}for(var f=0,d=this.RANGES.length;f=0;d--){if(this.data[0]&&!this.data[d].isSpacelike()){return this.data[d]}}return null},Core:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core]},CoreMO:function(){if(!(this.isEmbellished())||typeof(this.core)==="undefined"){return this}return this.data[this.core].CoreMO()},toString:function(){if(this.inferred){return"["+this.data.join(",")+"]"}return this.SUPER(arguments).toString.call(this)},setTeXclass:function(f){for(var e=0,d=this.data.length;e0){d++}return d},adjustChild_texprimestyle:function(d){if(d==this.den){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.msqrt=a.mbase.Subclass({type:"msqrt",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD,setTeXclass:a.mbase.setSeparateTeXclasses,adjustChild_texprimestyle:function(d){return true}});a.mroot=a.mbase.Subclass({type:"mroot",linebreakContainer:true,texClass:a.TEXCLASS.ORD,adjustChild_displaystyle:function(d){if(d===1){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e===1){d+=2}return d},adjustChild_texprimestyle:function(d){if(d===0){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setSeparateTeXclasses});a.mstyle=a.mbase.Subclass({type:"mstyle",isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,inferRow:true,defaults:{scriptlevel:a.INHERIT,displaystyle:a.INHERIT,scriptsizemultiplier:Math.sqrt(1/2),scriptminsize:"8pt",mathbackground:a.INHERIT,mathcolor:a.INHERIT,infixlinebreakstyle:a.LINEBREAKSTYLE.BEFORE,decimalseparator:"."},adjustChild_scriptlevel:function(f){var e=this.scriptlevel;if(e==null){e=this.Get("scriptlevel")}else{if(String(e).match(/^ *[-+]/)){delete this.scriptlevel;var d=this.Get("scriptlevel");this.scriptlevel=e;e=d+parseInt(e)}}return e},inheritFromMe:true,noInherit:{mpadded:{width:true,height:true,depth:true,lspace:true,voffset:true},mtable:{width:true,height:true,depth:true,align:true}},setTeXclass:a.mbase.setChildTeXclass});a.merror=a.mbase.Subclass({type:"merror",inferRow:true,linebreakContainer:true,texClass:a.TEXCLASS.ORD});a.mpadded=a.mbase.Subclass({type:"mpadded",inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,width:"",height:"",depth:"",lspace:0,voffset:0},setTeXclass:a.mbase.setChildTeXclass});a.mphantom=a.mbase.Subclass({type:"mphantom",texClass:a.TEXCLASS.ORD,inferRow:true,isSpacelike:a.mbase.childrenSpacelike,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,setTeXclass:a.mbase.setChildTeXclass});a.mfenced=a.mbase.Subclass({type:"mfenced",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,open:"(",close:")",separators:","},texClass:a.TEXCLASS.OPEN,setTeXclass:function(g){this.getPrevClass(g);var e=this.getValues("open","close","separators");e.open=e.open.replace(/[ \t\n\r]/g,"");e.close=e.close.replace(/[ \t\n\r]/g,"");e.separators=e.separators.replace(/[ \t\n\r]/g,"");if(e.open!==""){this.SetData("open",a.mo(e.open).With({stretchy:true,texClass:a.TEXCLASS.OPEN}));g=this.data.open.setTeXclass(g)}if(e.separators!==""){while(e.separators.length0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(e){var d=this.Get("scriptlevel");if(e>0){d++}return d},adjustChild_texprimestyle:function(d){if(d===this.sub){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.msub=a.msubsup.Subclass({type:"msub"});a.msup=a.msubsup.Subclass({type:"msup",sub:2,sup:1});a.mmultiscripts=a.msubsup.Subclass({type:"mmultiscripts",adjustChild_texprimestyle:function(d){if(d%2===1){return true}return this.Get("texprimestyle")}});a.mprescripts=a.mbase.Subclass({type:"mprescripts"});a.none=a.mbase.Subclass({type:"none"});a.munderover=a.mbase.Subclass({type:"munderover",base:0,under:1,over:2,sub:1,sup:2,ACCENTS:["","accentunder","accent"],linebreakContainer:true,isEmbellished:a.mbase.childEmbellished,Core:a.mbase.childCore,CoreMO:a.mbase.childCoreMO,defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,accent:a.AUTO,accentunder:a.AUTO,align:a.ALIGN.CENTER,texClass:a.AUTO,subscriptshift:"",superscriptshift:""},autoDefault:function(d){if(d==="texClass"){return(this.isEmbellished()?this.CoreMO().Get(d):a.TEXCLASS.ORD)}if(d==="accent"&&this.data[this.over]){return this.data[this.over].CoreMO().Get("accent")}if(d==="accentunder"&&this.data[this.under]){return this.data[this.under].CoreMO().Get("accent")}return false},adjustChild_displaystyle:function(d){if(d>0){return false}return this.Get("displaystyle")},adjustChild_scriptlevel:function(f){var e=this.Get("scriptlevel");var d=(this.data[this.base]&&!this.Get("displaystyle")&&this.data[this.base].CoreMO().Get("movablelimits"));if(f==this.under&&(d||!this.Get("accentunder"))){e++}if(f==this.over&&(d||!this.Get("accent"))){e++}return e},adjustChild_texprimestyle:function(d){if(d===this.base&&this.data[this.over]){return true}return this.Get("texprimestyle")},setTeXclass:a.mbase.setBaseTeXclasses});a.munder=a.munderover.Subclass({type:"munder"});a.mover=a.munderover.Subclass({type:"mover",over:1,under:2,sup:1,sub:2,ACCENTS:["","accent","accentunder"]});a.mtable=a.mbase.Subclass({type:"mtable",defaults:{mathbackground:a.INHERIT,mathcolor:a.INHERIT,align:a.ALIGN.AXIS,rowalign:a.ALIGN.BASELINE,columnalign:a.ALIGN.CENTER,groupalign:"{left}",alignmentscope:true,columnwidth:a.WIDTH.AUTO,width:a.WIDTH.AUTO,rowspacing:"1ex",columnspacing:".8em",rowlines:a.LINES.NONE,columnlines:a.LINES.NONE,frame:a.LINES.NONE,framespacing:"0.4em 0.5ex",equalrows:false,equalcolumns:false,displaystyle:false,side:a.SIDE.RIGHT,minlabelspacing:"0.8em",texClass:a.TEXCLASS.ORD,useHeight:1},inheritFromMe:true,noInherit:{mtable:{align:true,rowalign:true,columnalign:true,groupalign:true,alignmentscope:true,columnwidth:true,width:true,rowspacing:true,columnspacing:true,rowlines:true,columnlines:true,frame:true,framespacing:true,equalrows:true,equalcolumns:true,side:true,minlabelspacing:true,texClass:true,useHeight:1}},linebreakContainer:true,Append:function(){for(var e=0,d=arguments.length;e>10)+55296)+String.fromCharCode((d&1023)+56320)}});a.xml=a.mbase.Subclass({type:"xml",Init:function(){this.div=document.createElement("div");return this.SUPER(arguments).Init.apply(this,arguments)},Append:function(){for(var e=0,d=arguments.length;e":c.REL,"?":[1,1,b.CLOSE],"\\":c.ORD,"^":c.ORD11,_:c.ORD11,"|":[2,2,b.ORD,{fence:true,stretchy:true,symmetric:true}],"#":c.ORD,"$":c.ORD,"\u002E":[0,3,b.PUNCT,{separator:true}],"\u02B9":c.ORD,"\u0300":c.ACCENT,"\u0301":c.ACCENT,"\u0303":c.WIDEACCENT,"\u0304":c.ACCENT,"\u0306":c.ACCENT,"\u0307":c.ACCENT,"\u0308":c.ACCENT,"\u030C":c.ACCENT,"\u0332":c.WIDEACCENT,"\u0338":c.REL4,"\u2015":[0,0,b.ORD,{stretchy:true}],"\u2017":[0,0,b.ORD,{stretchy:true}],"\u2020":c.BIN3,"\u2021":c.BIN3,"\u20D7":c.ACCENT,"\u2111":c.ORD,"\u2113":c.ORD,"\u2118":c.ORD,"\u211C":c.ORD,"\u2205":c.ORD,"\u221E":c.ORD,"\u2305":c.BIN3,"\u2306":c.BIN3,"\u2322":c.REL4,"\u2323":c.REL4,"\u2329":c.OPEN,"\u232A":c.CLOSE,"\u23AA":c.ORD,"\u23AF":[0,0,b.ORD,{stretchy:true}],"\u23B0":c.OPEN,"\u23B1":c.CLOSE,"\u2500":c.ORD,"\u25EF":c.BIN3,"\u2660":c.ORD,"\u2661":c.ORD,"\u2662":c.ORD,"\u2663":c.ORD,"\u3008":c.OPEN,"\u3009":c.CLOSE,"\uFE37":c.WIDEACCENT,"\uFE38":c.WIDEACCENT}}},{OPTYPES:c});a.mo.prototype.OPTABLE.infix["^"]=c.WIDEREL;a.mo.prototype.OPTABLE.infix._=c.WIDEREL})(MathJax.ElementJax.mml);MathJax.ElementJax.mml.loadComplete("jax.js"); diff --git a/extensions/MathMenu.js b/extensions/MathMenu.js index a034f207b..ba87502bf 100644 --- a/extensions/MathMenu.js +++ b/extensions/MathMenu.js @@ -12,5 +12,5 @@ * http://www.apache.org/licenses/LICENSE-2.0 */ -(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help))});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); +(function(c,f,j,e,b){var o="1.1.9";var i=MathJax.Callback.Signal("menu");MathJax.Extension.MathMenu={version:o,signal:i};var m=c.Browser.isPC,k=c.Browser.isMSIE;var h=(m?null:"5px");var n=c.CombineConfig("MathMenu",{delay:150,helpURL:"http://www.mathjax.org/help/user/",closeImg:j.fileURL(b.imageDir+"/CloseX-31.png"),showRenderer:true,showFontMenu:false,showContext:false,showDiscoverable:false,windowSettings:{status:"no",toolbar:"no",locationbar:"no",menubar:"no",directories:"no",personalbar:"no",resizable:"yes",scrollbars:"yes",width:100,height:50},styles:{"#MathJax_About":{position:"fixed",left:"50%",width:"auto","text-align":"center",border:"3px outset",padding:"1em 2em","background-color":"#DDDDDD",color:"black",cursor:"default","font-family":"message-box","font-size":"120%","font-style":"normal","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":"15px","-webkit-border-radius":"15px","-moz-border-radius":"15px","-khtml-border-radius":"15px","box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_Menu":{position:"absolute","background-color":"white",color:"black",width:"auto",padding:(m?"2px":"5px 0px"),border:"1px solid #CCCCCC",margin:0,cursor:"default",font:"menu","text-align":"left","text-indent":0,"text-transform":"none","line-height":"normal","letter-spacing":"normal","word-spacing":"normal","word-wrap":"normal","white-space":"nowrap","float":"none","z-index":201,"border-radius":h,"-webkit-border-radius":h,"-moz-border-radius":h,"-khtml-border-radius":h,"box-shadow":"0px 10px 20px #808080","-webkit-box-shadow":"0px 10px 20px #808080","-moz-box-shadow":"0px 10px 20px #808080","-khtml-box-shadow":"0px 10px 20px #808080",filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=2, OffY=2, Color='gray', Positive='true')"},".MathJax_MenuItem":{padding:(m?"2px 2em":"1px 2em"),background:"transparent"},".MathJax_MenuTitle":{"background-color":"#CCCCCC",margin:(m?"-1px -1px 1px -1px":"-5px 0 0 0"),"text-align":"center","font-style":"italic","font-size":"80%",color:"#444444",padding:"2px 0",overflow:"hidden"},".MathJax_MenuArrow":{position:"absolute",right:".5em",color:"#666666","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuActive .MathJax_MenuArrow":{color:"white"},".MathJax_MenuCheck":{position:"absolute",left:".7em","font-family":(k?"'Arial unicode MS'":null)},".MathJax_MenuRadioCheck":{position:"absolute",left:(m?"1em":".7em")},".MathJax_MenuLabel":{padding:(m?"2px 2em 4px 1.33em":"1px 2em 3px 1.33em"),"font-style":"italic"},".MathJax_MenuRule":{"border-top":(m?"1px solid #CCCCCC":"1px solid #DDDDDD"),margin:(m?"4px 1px 0px":"4px 3px")},".MathJax_MenuDisabled":{color:"GrayText"},".MathJax_MenuActive":{"background-color":(m?"Highlight":"#606872"),color:(m?"HighlightText":"white")},".MathJax_Menu_Close":{position:"absolute",width:"31px",height:"31px",top:"-15px",left:"-15px"}}});var g,d;c.Register.StartupHook("MathEvents Ready",function(){g=MathJax.Extension.MathEvents.Event.False;d=MathJax.Extension.MathEvents.Hover});var a=MathJax.Menu=MathJax.Object.Subclass({version:o,items:[],posted:false,title:null,margin:5,Init:function(p){this.items=[].slice.call(arguments,0)},With:function(p){if(p){c.Insert(this,p)}return this},Post:function(q,A){if(!q){q=window.event}var w=(!this.title?null:[["div",{className:"MathJax_MenuTitle"},[this.title]]]);var p=document.getElementById("MathJax_MenuFrame");if(!p){p=a.Background(this);delete l.lastItem;delete l.lastMenu;delete a.skipUp;i.Post(["post",a.jax])}var r=f.addElement(p,"div",{onmouseup:a.Mouseup,ondblclick:g,ondragstart:g,onselectstart:g,oncontextmenu:g,menuItem:this,className:"MathJax_Menu"},w);for(var t=0,s=this.items.length;tdocument.body.offsetWidth-this.margin){z=document.body.offsetWidth-r.offsetWidth-this.margin}if(a.isMobile){z=Math.max(5,z-Math.floor(r.offsetWidth/2));v-=20}a.skipUp=q.isContextMenu}else{var u="left",B=A.offsetWidth;z=(a.isMobile?30:B-2);v=0;while(A&&A!==p){z+=A.offsetLeft;v+=A.offsetTop;A=A.parentNode}if(z+r.offsetWidth>document.body.offsetWidth-this.margin&&!a.isMobile){u="right";z=Math.max(this.margin,z-B-r.offsetWidth+6)}if(!m){r.style["borderRadiusTop"+u]=0;r.style["WebkitBorderRadiusTop"+u]=0;r.style["MozBorderRadiusTop"+u]=0;r.style["KhtmlBorderRadiusTop"+u]=0}}r.style.left=z+"px";r.style.top=v+"px";if(document.selection&&document.selection.empty){document.selection.empty()}return g(q)},Remove:function(p,q){i.Post(["unpost",a.jax]);var r=document.getElementById("MathJax_MenuFrame");if(r){r.parentNode.removeChild(r);if(this.msieFixedPositionBug){detachEvent("onresize",a.Resize)}}if(a.jax.hover){delete a.jax.hover.nofade;d.UnHover(a.jax)}return g(p)},Find:function(q){var s=[].slice.call(arguments,1);for(var r=0,p=this.items.length;r=0&&v.parentNode.menuItem!==u[p].menuItem){u[p].menuItem.posted=false;u[p].parentNode.removeChild(u[p]);p--}if(this.Timer&&!a.isMobile){this.Timer(t,v)}}},Mouseout:function(p,q){if(!this.menu||!this.menu.posted){this.Deactivate(q)}if(this.timer){clearTimeout(this.timer);delete this.timer}},Mouseup:function(p,q){return this.Remove(p,q)},Touchstart:function(p,q){return this.TouchEvent(p,q,"Mousedown")},Touchend:function(p,q){return this.TouchEvent(p,q,"Mouseup")},TouchEvent:function(q,r,p){if(this!==l.lastItem){if(l.lastMenu){a.Event(q,l.lastMenu,"Mouseout")}a.Event(q,r,"Mouseover",true);l.lastItem=this;l.lastMenu=r}if(this.nativeTouch){return null}a.Event(q,r,p);return false},Remove:function(p,q){q=q.parentNode.menuItem;return q.Remove(p,q)},Activate:function(p){this.Deactivate(p);p.className+=" MathJax_MenuActive"},Deactivate:function(p){p.className=p.className.replace(/ MathJax_MenuActive/,"")},With:function(p){if(p){c.Insert(this,p)}return this}});a.ITEM.COMMAND=a.ITEM.Subclass({action:function(){},Init:function(p,r,q){this.name=p;this.action=r;this.With(q)},Label:function(p,q){return[this.name]},Mouseup:function(p,q){if(!this.disabled){this.Remove(p,q);i.Post(["command",this]);this.action.call(this,p)}return g(p)}});a.ITEM.SUBMENU=a.ITEM.Subclass({menu:null,marker:(m&&!c.Browser.isSafari?"\u25B6":"\u25B8"),Init:function(p,r){this.name=p;var q=1;if(!(r instanceof a.ITEM)){this.With(r),q++}this.menu=a.apply(a,[].slice.call(arguments,q))},Label:function(p,q){this.menu.posted=false;return[this.name+" ",["span",{className:"MathJax_MenuArrow"},[this.marker]]]},Timer:function(p,q){if(this.timer){clearTimeout(this.timer)}p={clientX:p.clientX,clientY:p.clientY};this.timer=setTimeout(e(["Mouseup",this,p,q]),n.delay)},Touchend:function(q,s){var r=this.menu.posted;var p=this.SUPER(arguments).Touchend.apply(this,arguments);if(r){this.Deactivate(s);delete l.lastItem;delete l.lastMenu}return p},Mouseup:function(q,s){if(!this.disabled){if(!this.menu.posted){if(this.timer){clearTimeout(this.timer);delete this.timer}this.menu.Post(q,s)}else{var r=document.getElementById("MathJax_MenuFrame").childNodes,p=r.length-1;while(p>=0){var t=r[p];t.menuItem.posted=false;t.parentNode.removeChild(t);if(t.menuItem===this.menu){break}p--}}}return g(q)}});a.ITEM.RADIO=a.ITEM.Subclass({variable:null,marker:(m?"\u25CF":"\u2713"),Init:function(q,p,r){this.name=q;this.variable=p;this.With(r);if(this.value==null){this.value=this.name}},Label:function(q,r){var p={className:"MathJax_MenuRadioCheck"};if(n.settings[this.variable]!==this.value){p={style:{display:"none"}}}return[["span",p,[this.marker]]," "+this.name]},Mouseup:function(s,t){if(!this.disabled){var u=t.parentNode.childNodes;for(var q=0,p=u.length;q/g,">");if(a.isMobile){r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("
");r.document.write("");r.document.close()}else{r.document.open();r.document.write("MathJax Equation Source");r.document.write("
"+v+"
");r.document.write("");r.document.close();var t=r.document.body.firstChild;var s=(r.outerHeight-r.innerHeight)||30,q=(r.outerWidth-r.innerWidth)||30;q=Math.min(Math.floor(0.5*screen.width),t.offsetWidth+q+25);s=Math.min(Math.floor(0.5*screen.height),t.offsetHeight+s+25);r.resizeTo(q,s);if(u&&u.screenX!=null){var p=Math.max(0,Math.min(u.screenX-Math.floor(q/2),screen.width-q-20)),z=Math.max(0,Math.min(u.screenY-Math.floor(s/2),screen.height-s-20));r.moveTo(p,z)}}delete a.ShowSource.w};a.Scale=function(){var q=b["HTML-CSS"],p=b.NativeMML;var s=(q?q.config.scale:p.config.scale);var r=prompt("Scale all mathematics (compared to surrounding text) by",s+"%");if(r){if(r.match(/^\s*\d+\s*%?\s*$/)){r=parseInt(r);if(r){if(r!==s){if(q){q.config.scale=r}if(p){p.config.scale=r}a.cookie.scale=r;a.saveCookie();c.Reprocess()}}else{alert("The scale should not be zero")}}else{alert("The scale should be a perentage (e.g., 120%)")}}};a.Zoom=function(){if(!MathJax.Extension.MathZoom){j.Require("[MathJax]/extensions/MathZoom.js")}};a.Renderer=function(){var p=c.outputJax["jax/mml"];if(p[0]!==n.settings.renderer){c.Queue(["setRenderer",c,n.settings.renderer,"jax/mml"],["Rerender",c])}};a.Font=function(){var p=b["HTML-CSS"];if(!p){return}document.location.reload()};c.Browser.Select({MSIE:function(p){var q=(document.compatMode==="BackCompat");var r=p.versionAtLeast("8.0")&&document.documentMode>7;a.Augment({margin:20,msieBackgroundBug:true,msieFixedPositionBug:(q||!r),msieAboutBug:q});if(document.documentMode>=9){delete n.styles["#MathJax_About"].filter;delete n.styles[".MathJax_Menu"].filter}},Firefox:function(p){a.skipMouseover=p.isMobile&&p.versionAtLeast("6.0");a.skipMousedown=p.isMobile}});a.isMobile=c.Browser.isMobile;a.noContextMenu=c.Browser.noContextMenu;c.Register.StartupHook("End Config",function(){n.settings=c.config.menuSettings;if(typeof(n.settings.showRenderer)!=="undefined"){n.showRenderer=n.settings.showRenderer}if(typeof(n.settings.showFontMenu)!=="undefined"){n.showFontMenu=n.settings.showFontMenu}if(typeof(n.settings.showContext)!=="undefined"){n.showContext=n.settings.showContext}a.getCookie();a.menu=a(l.SUBMENU("Show Math As",l.COMMAND("MathML Code",a.ShowSource,{nativeTouch:true,format:"MathML"}),l.COMMAND("Original Form",a.ShowSource,{nativeTouch:true})),l.RULE(),l.SUBMENU("Math Settings",l.SUBMENU("Zoom Trigger",l.RADIO("Hover","zoom",{action:a.Zoom}),l.RADIO("Click","zoom",{action:a.Zoom}),l.RADIO("Double-Click","zoom",{action:a.Zoom}),l.RADIO("No Zoom","zoom",{value:"None"}),l.RULE(),l.LABEL("Trigger Requires:"),l.CHECKBOX((c.Browser.isMac?"Option":"Alt"),"ALT"),l.CHECKBOX("Command","CMD",{hidden:!c.Browser.isMac}),l.CHECKBOX("Control","CTRL",{hidden:c.Browser.isMac}),l.CHECKBOX("Shift","Shift")),l.SUBMENU("Zoom Factor",l.RADIO("125%","zscale"),l.RADIO("133%","zscale"),l.RADIO("150%","zscale"),l.RADIO("175%","zscale"),l.RADIO("200%","zscale"),l.RADIO("250%","zscale"),l.RADIO("300%","zscale"),l.RADIO("400%","zscale")),l.RULE(),l.SUBMENU("Math Renderer",{hidden:!n.showRenderer},l.RADIO("HTML-CSS","renderer",{action:a.Renderer}),l.RADIO("MathML","renderer",{action:a.Renderer,value:"NativeMML"}),l.RADIO("SVG","renderer",{action:a.Renderer})),l.SUBMENU("Font Preference",{hidden:!n.showFontMenu},l.LABEL("For HTML-CSS:"),l.RADIO("Auto","font",{action:a.Font}),l.RULE(),l.RADIO("TeX (local)","font",{action:a.Font}),l.RADIO("TeX (web)","font",{action:a.Font}),l.RADIO("TeX (image)","font",{action:a.Font}),l.RULE(),l.RADIO("STIX (local)","font",{action:a.Font})),l.SUBMENU("Contextual Menu",{hidden:!n.showContext},l.RADIO("MathJax","context"),l.RADIO("Browser","context")),l.COMMAND("Scale All Math ...",a.Scale),l.RULE().With({hidden:n.showDiscoverable,name:"discover_rule"}),l.CHECKBOX("Highlight on Hover","discoverable",{hidden:n.showDiscoverable})),l.RULE(),l.COMMAND("About MathJax",a.About),l.COMMAND("MathJax Help",a.Help));if(a.isMobile){(function(){var q=n.settings;var p=a.menu.Find("Math Settings","Zoom Trigger").menu;p.items[0].disabled=p.items[1].disabled=true;if(q.zoom==="Hover"||q.zoom=="Click"){q.zoom="None"}p.items=p.items.slice(0,4);if(navigator.appVersion.match(/[ (]Android[) ]/)){a.ITEM.SUBMENU.Augment({marker:"\u00BB"})}})()}});a.showRenderer=function(p){a.cookie.showRenderer=n.showRenderer=p;a.saveCookie();a.menu.Find("Math Settings","Math Renderer").hidden=!p};a.showFontMenu=function(p){a.cookie.showFontMenu=n.showFontMenu=p;a.saveCookie();a.menu.Find("Math Settings","Font Preference").hidden=!p};a.showContext=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Contextual Menu").hidden=!p};a.showDiscoverable=function(p){a.cookie.showContext=n.showContext=p;a.saveCookie();a.menu.Find("Math Settings","Highlight on Hover").hidden=!p;a.menu.Find("Math Settings","discover_rule").hidden=!p};e.Queue(c.Register.StartupHook("End Config",{}),["getImages",a],["Styles",j,n.styles],["Post",c.Startup.signal,"MathMenu Ready"],["loadComplete",j,"[MathJax]/extensions/MathMenu.js"])})(MathJax.Hub,MathJax.HTML,MathJax.Ajax,MathJax.CallBack,MathJax.OutputJax); diff --git a/unpacked/extensions/MathMenu.js b/unpacked/extensions/MathMenu.js index 0cbd791dc..ed66e3b8b 100644 --- a/unpacked/extensions/MathMenu.js +++ b/unpacked/extensions/MathMenu.js @@ -875,6 +875,20 @@ ITEM.COMMAND("MathJax Help",MENU.Help) ); + if (MENU.isMobile) { + (function () { + var settings = CONFIG.settings; + var trigger = MENU.menu.Find("Math Settings","Zoom Trigger").menu; + trigger.items[0].disabled = trigger.items[1].disabled = true; + if (settings.zoom === "Hover" || settings.zoom == "Click") {settings.zoom = "None"} + trigger.items = trigger.items.slice(0,4); + + if (navigator.appVersion.match(/[ (]Android[) ]/)) { + MENU.ITEM.SUBMENU.Augment({marker: "\u00BB"}); + } + })(); + } + }); MENU.showRenderer = function (show) { @@ -895,20 +909,6 @@ MENU.menu.Find("Math Settings","discover_rule").hidden = !show; }; - if (MENU.isMobile) { - (function () { - var settings = CONFIG.settings; - var trigger = MENU.menu.Find("Math Settings","Zoom Trigger").menu; - trigger.items[0].disabled = trigger.items[1].disabled = true; - if (settings.zoom === "Hover" || settings.zoom == "Click") {settings.zoom = "None"} - trigger.items = trigger.items.slice(0,4); - - if (navigator.appVersion.match(/[ (]Android[) ]/)) { - MENU.ITEM.SUBMENU.Augment({marker: "\u00BB"}); - } - })(); - } - /*************************************************************/ CALLBACK.Queue(