/*
* /MathJax/jax/output/HTML-CSS/autoload/mtable.js
*
* Copyright (c) 2009-2013 The MathJax Consortium
*
* Part of the MathJax library.
* See http://www.mathjax.org for details.
*
* Licensed under the Apache License, Version 2.0;
* you may not use this file except in compliance with the License.
*
* http://www.apache.org/licenses/LICENSE-2.0
*/MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function(){var L=MathJax.ElementJax.mml,c=MathJax.OutputJax["HTML-CSS"];L.mtable.Augment({toHTML:function(x){x=this.HTMLcreateSpan(x);if(0===this.data.length)return x;var g=this.getValues("columnalign","rowalign","columnspacing","rowspacing","columnwidth","equalcolumns","equalrows","columnlines","rowlines","frame","framespacing","align","useHeight","width","side","minlabelspacing"),G=g.width.match(/%$/),t=c.createStack(x),E=this.HTMLgetScale(),H=this.HTMLgetMu(x),h=[],m=[],k=[],d=[],n=[],a,b,u=-1,f,I,p,r,w,A,l=[],M=c.FONTDATA.baselineskip*E*g.useHeight,q,J=c.FONTDATA.lineH*E,N=c.FONTDATA.lineD*E;a=0;for(f=this.data.length;au&&(u=b),n[b]=c.createStack(c.createBox(t)),k[b]=-c.BIGDIMEN),d[a][b]=c.createBox(n[b]),l.push(r.data[b-p].toHTML(d[a][b]));c.MeasureSpans(l);a=0;for(f=this.data.length;ah[a]&&(h[a]=l*B.h/q),l*B.d/q>m[a]&&(m[a]=l*B.d/q)}else A.HTMLcanStretch("Horizontal")&&(l=c.length2em(l,H,B.w),l>k[b]&&(k[b]=l))}d[a][b].bbox.h>h[a]&&(h[a]=d[a][b].bbox.h);d[a][b].bbox.d>m[a]&&(m[a]=d[a][b].bbox.d);d[a][b].bbox.w>k[b]&&(k[b]=d[a][b].bbox.w)}h[0]+m[0]&&(h[0]=Math.max(h[0],J));h[d.length-1]+m[d.length-1]&&(m[d.length-1]=Math.max(m[d.length-1],N));var C=MathJax.Hub.SplitList,l=C(g.columnspacing),J=C(g.rowspacing);I=C(g.columnalign);var e=C(g.rowalign),B=C(g.columnlines),N=C(g.rowlines),y=C(g.columnwidth),F=[];a=0;for(f=l.length;ab&&(b=d.length+1+b),1>b?b=1:b>d.length&&(b=d.length),C=0,E=-(q+a)+h[0],a=0,f=b-1;az)for(v=(v-z)/q,a=0,f=p.length;a