diff --git a/html/antena_distance.html b/html/antena_distance.html new file mode 100644 index 0000000..405329f --- /dev/null +++ b/html/antena_distance.html @@ -0,0 +1,120 @@ + + +
+ + + + + + + + ++ 无线理论最大传输距离 +
+ +{"use strict";var n=r(4376),i=r(3517),a=r(34),o=r(8227)("species"),u=Array;e.exports=function(e){var t;return n(e)&&(t=e.constructor,(i(t)&&(t===u||n(t.prototype))||a(t)&&null===(t=t[o]))&&(t=void 0)),void 0===t?u:t}},1469:(e,t,r)=>{"use strict";var n=r(7433);e.exports=function(e,t){return new(n(e))(0===t?0:t)}},6319:(e,t,r)=>{"use strict";var n=r(8551),i=r(9539);e.exports=function(e,t,r,a){try{return a?t(n(r)[0],r[1]):t(r)}catch(t){i(e,"throw",t)}}},4428:(e,t,r)=>{"use strict";var n=r(8227)("iterator"),i=!1;try{var a=0,o={next:function(){return{done:!!a++}},return:function(){i=!0}};o[n]=function(){return this},Array.from(o,(function(){throw 2}))}catch(e){}e.exports=function(e,t){try{if(!t&&!i)return!1}catch(e){return!1}var r=!1;try{var a={};a[n]=function(){return{next:function(){return{done:r=!0}}}},e(a)}catch(e){}return r}},4576:(e,t,r)=>{"use strict";var n=r(9504),i=n({}.toString),a=n("".slice);e.exports=function(e){return a(i(e),8,-1)}},6955:(e,t,r)=>{"use strict";var n=r(2140),i=r(4901),a=r(4576),o=r(8227)("toStringTag"),u=Object,s="Arguments"===a(function(){return arguments}());e.exports=n?a:function(e){var t,r,n;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=function(e,t){try{return e[t]}catch(e){}}(t=u(e),o))?r:s?a(t):"Object"===(n=a(t))&&i(t.callee)?"Arguments":n}},6938:(e,t,r)=>{"use strict";var n=r(2360),i=r(2106),a=r(6279),o=r(6080),u=r(679),s=r(4117),c=r(2652),f=r(1088),l=r(2529),p=r(7633),m=r(3724),h=r(3451).fastKey,d=r(1181),v=d.set,y=d.getterFor;e.exports={getConstructor:function(e,t,r,f){var l=e((function(e,i){u(e,p),v(e,{type:t,index:n(null),first:void 0,last:void 0,size:0}),m||(e.size=0),s(i)||c(i,e[f],{that:e,AS_ENTRIES:r})})),p=l.prototype,d=y(t),g=function(e,t,r){var n,i,a=d(e),o=x(e,t);return o?o.value=r:(a.last=o={index:i=h(t,!0),key:t,value:r,previous:n=a.last,next:void 0,removed:!1},a.first||(a.first=o),n&&(n.next=o),m?a.size++:e.size++,"F"!==i&&(a.index[i]=o)),e},x=function(e,t){var r,n=d(e),i=h(t);if("F"!==i)return n.index[i];for(r=n.first;r;r=r.next)if(r.key===t)return r};return a(p,{clear:function(){for(var e=d(this),t=e.first;t;)t.removed=!0,t.previous&&(t.previous=t.previous.next=void 0),t=t.next;e.first=e.last=void 0,e.index=n(null),m?e.size=0:this.size=0},delete:function(e){var t=this,r=d(t),n=x(t,e);if(n){var i=n.next,a=n.previous;delete r.index[n.index],n.removed=!0,a&&(a.next=i),i&&(i.previous=a),r.first===n&&(r.first=i),r.last===n&&(r.last=a),m?r.size--:t.size--}return!!n},forEach:function(e){for(var t,r=d(this),n=o(e,arguments.length>1?arguments[1]:void 0);t=t?t.next:r.first;)for(n(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!x(this,e)}}),a(p,r?{get:function(e){var t=x(this,e);return t&&t.value},set:function(e,t){return g(this,0===e?0:e,t)}}:{add:function(e){return g(this,e=0===e?0:e,e)}}),m&&i(p,"size",{configurable:!0,get:function(){return d(this).size}}),l},setStrong:function(e,t,r){var n=t+" Iterator",i=y(t),a=y(n);f(e,t,(function(e,t){v(this,{type:n,target:e,state:i(e),kind:t,last:void 0})}),(function(){for(var e=a(this),t=e.kind,r=e.last;r&&r.removed;)r=r.previous;return e.target&&(e.last=r=r?r.next:e.state.first)?l("keys"===t?r.key:"values"===t?r.value:[r.key,r.value],!1):(e.target=void 0,l(void 0,!0))}),r?"entries":"values",!r,!0),p(t)}}},6468:(e,t,r)=>{"use strict";var n=r(6518),i=r(4475),a=r(9504),o=r(2796),u=r(6840),s=r(3451),c=r(2652),f=r(679),l=r(4901),p=r(4117),m=r(34),h=r(9039),d=r(4428),v=r(687),y=r(3167);e.exports=function(e,t,r){var g=-1!==e.indexOf("Map"),x=-1!==e.indexOf("Weak"),b=g?"set":"add",w=i[e],D=w&&w.prototype,N=w,E={},A=function(e){var t=a(D[e]);u(D,e,"add"===e?function(e){return t(this,0===e?0:e),this}:"delete"===e?function(e){return!(x&&!m(e))&&t(this,0===e?0:e)}:"get"===e?function(e){return x&&!m(e)?void 0:t(this,0===e?0:e)}:"has"===e?function(e){return!(x&&!m(e))&&t(this,0===e?0:e)}:function(e,r){return t(this,0===e?0:e,r),this})};if(o(e,!l(w)||!(x||D.forEach&&!h((function(){(new w).entries().next()})))))N=r.getConstructor(t,e,g,b),s.enable();else if(o(e,!0)){var S=new N,C=S[b](x?{}:-0,1)!==S,M=h((function(){S.has(1)})),F=d((function(e){new w(e)})),O=!x&&h((function(){for(var e=new w,t=5;t--;)e[b](t,t);return!e.has(-0)}));F||((N=t((function(e,t){f(e,D);var r=y(new w,e,N);return p(t)||c(t,r[b],{that:r,AS_ENTRIES:g}),r}))).prototype=D,D.constructor=N),(M||O)&&(A("delete"),A("has"),g&&A("get")),(O||C)&&A(b),x&&D.clear&&delete D.clear}return E[e]=N,n({global:!0,constructor:!0,forced:N!==w},E),v(N,e),x||r.setStrong(N,e,g),N}},7740:(e,t,r)=>{"use strict";var n=r(9297),i=r(5031),a=r(7347),o=r(4913);e.exports=function(e,t,r){for(var u=i(t),s=o.f,c=a.f,f=0;f (o=(a=Math.ceil(u/At))>o?a+1:o+1)&&(i=o,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for((o=c.length)-(i=f.length)<0&&(i=o,r=f,f=c,c=r),t=0;i;)t=(c[--i]=c[i]+f[i]+t)/Et|0,c[i]%=Et;for(t&&(c.unshift(t),++n),o=c.length;0==c[--o];)c.pop();return e.d=c,e.e=zt(c,n),pt?kt(e,u,s):e},Mt.precision=Mt.sd=function(e){var t,r=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(ht+e);return r.d?(t=jt(r.d),e&&r.e+1>t&&(t=r.e+1)):t=NaN,t},Mt.round=function(){var e=this,t=e.constructor;return kt(new t(e),e.e+1,t.rounding)},Mt.sine=Mt.sin=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+At,n.rounding=1,r=function(e,t){var r,n=t.d.length;if(n<3)return t.isZero()?t:Yt(e,2,t,t);r=(r=1.4*Math.sqrt(n))>16?16:0|r,t=Yt(e,2,t=t.times(1/Jt(5,r)),t);for(var i,a=new e(5),o=new e(16),u=new e(20);r--;)i=t.times(t),t=t.times(a.plus(i.times(o.times(i).minus(u))));return t}(n,Xt(n,r)),n.precision=e,n.rounding=t,kt(it>2?r.neg():r,e,t,!0)):new n(NaN)},Mt.squareRoot=Mt.sqrt=function(){var e,t,r,n,i,a,o=this,u=o.d,s=o.e,c=o.s,f=o.constructor;if(1!==c||!u||!u[0])return new f(!c||c<0&&(!u||u[0])?NaN:u?o:1/0);for(pt=!1,0==(c=Math.sqrt(+o))||c==1/0?(((t=Ft(u)).length+s)%2==0&&(t+="0"),c=Math.sqrt(t),s=gt((s+1)/2)-(s<0||s%2),n=new f(t=c==1/0?"5e"+s:(t=c.toExponential()).slice(0,t.indexOf("e")+1)+s)):n=new f(c.toString()),r=(s=f.precision)+3;;)if(n=(a=n).plus(Bt(o,a,r+2,1)).times(.5),Ft(a.d).slice(0,r)===(t=Ft(n.d)).slice(0,r)){if("9999"!=(t=t.slice(r-3,r+1))&&(i||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(kt(n,s+1,1),e=!n.times(n).eq(o));break}if(!i&&(kt(a,s+1,0),a.times(a).eq(o))){n=a;break}r+=4,i=1}return pt=!0,kt(n,s,f.rounding,e)},Mt.tangent=Mt.tan=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+10,n.rounding=1,(r=r.sin()).s=1,r=Bt(r,new n(1).minus(r.times(r)).sqrt(),e+10,0),n.precision=e,n.rounding=t,kt(2==it||4==it?r.neg():r,e,t,!0)):new n(NaN)},Mt.times=Mt.mul=function(e){var t,r,n,i,a,o,u,s,c,f=this,l=f.constructor,p=f.d,m=(e=new l(e)).d;if(e.s*=f.s,!(p&&p[0]&&m&&m[0]))return new l(!e.s||p&&!p[0]&&!m||m&&!m[0]&&!p?NaN:p&&m?0*e.s:e.s/0);for(r=gt(f.e/At)+gt(e.e/At),(s=p.length)<(c=m.length)&&(a=p,p=m,m=a,o=s,s=c,c=o),a=[],n=o=s+c;n--;)a.push(0);for(n=c;--n>=0;){for(t=0,i=s+n;i>n;)u=a[i]+m[n]*p[i-n-1]+t,a[i--]=u%Et|0,t=u/Et|0;a[i]=(a[i]+t)%Et|0}for(;!a[--o];)a.pop();return t?++r:a.shift(),e.d=a,e.e=zt(a,r),pt?kt(e,l.precision,l.rounding):e},Mt.toBinary=function(e,t){return Qt(this,2,e,t)},Mt.toDecimalPlaces=Mt.toDP=function(e,t){var r=this,n=r.constructor;return r=new n(r),void 0===e?r:(Ot(e,0,ut),void 0===t?t=n.rounding:Ot(t,0,8),kt(r,e+r.e+1,t))},Mt.toExponential=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=It(n,!0):(Ot(e,0,ut),void 0===t?t=i.rounding:Ot(t,0,8),r=It(n=kt(new i(n),e+1,t),!0,e+1)),n.isNeg()&&!n.isZero()?"-"+r:r},Mt.toFixed=function(e,t){var r,n,i=this,a=i.constructor;return void 0===e?r=It(i):(Ot(e,0,ut),void 0===t?t=a.rounding:Ot(t,0,8),r=It(n=kt(new a(i),e+i.e+1,t),!1,e+n.e+1)),i.isNeg()&&!i.isZero()?"-"+r:r},Mt.toFraction=function(e){var t,r,n,i,a,o,u,s,c,f,l,p,m=this,h=m.d,d=m.constructor;if(!h)return new d(m);if(c=r=new d(1),n=s=new d(0),o=(a=(t=new d(n)).e=jt(h)-m.e-1)%At,t.d[0]=xt(10,o<0?At+o:o),null==e)e=a>0?t:c;else{if(!(u=new d(e)).isInt()||u.lt(c))throw Error(ht+u);e=u.gt(t)?a>0?t:c:u}for(pt=!1,u=new d(Ft(h)),f=d.precision,d.precision=a=h.length*At*2;l=Bt(u,t,0,1,1),1!=(i=r.plus(l.times(n))).cmp(e);)r=n,n=i,i=c,c=s.plus(l.times(i)),s=i,i=t,t=u.minus(l.times(i)),u=i;return i=Bt(e.minus(r),n,0,1,1),s=s.plus(i.times(c)),r=r.plus(i.times(n)),s.s=c.s=m.s,p=Bt(c,n,a,1).minus(m).abs().cmp(Bt(s,r,a,1).minus(m).abs())<1?[c,n]:[s,r],d.precision=f,pt=!0,p},Mt.toHexadecimal=Mt.toHex=function(e,t){return Qt(this,16,e,t)},Mt.toNearest=function(e,t){var r=this,n=r.constructor;if(r=new n(r),null==e){if(!r.d)return r;e=new n(1),t=n.rounding}else{if(e=new n(e),void 0===t?t=n.rounding:Ot(t,0,8),!r.d)return e.s?r:e;if(!e.d)return e.s&&(e.s=r.s),e}return e.d[0]?(pt=!1,r=Bt(r,e,0,t,1).times(e),pt=!0,kt(r)):(e.s=r.s,r=e),r},Mt.toNumber=function(){return+this},Mt.toOctal=function(e,t){return Qt(this,8,e,t)},Mt.toPower=Mt.pow=function(e){var t,r,n,i,a,o,u=this,s=u.constructor,c=+(e=new s(e));if(!(u.d&&e.d&&u.d[0]&&e.d[0]))return new s(xt(+u,c));if((u=new s(u)).eq(1))return u;if(n=s.precision,a=s.rounding,e.eq(1))return kt(u,n,a);if((t=gt(e.e/At))>=e.d.length-1&&(r=c<0?-c:c)<=9007199254740991)return i=Lt(s,u,r,n),e.s<0?new s(1).div(i):kt(i,n,a);if((o=u.s)<0){if(t =0;v--)d[v]=a(d[v],c[v][l]);r.push(d)}}else{if(0===m)return[];r.splice(m,1),m-=1,p-=1}else{h[l]=n(h[l],c[l][l]);for(var y=l-1;y>=0;y--)h[y]=a(h[y],i(h[l],c[y][l]))}}return r.map((function(e){return new u({data:e.map((function(e){return[e]})),size:[f,1]})}))}})),Ac=Ce("matAlgo08xS0Sid",["typed","equalScalar"],(function(e){var t=e.typed,r=e.equalScalar;return function(e,n,i){var a=e._values,o=e._index,u=e._ptr,s=e._size,c=e._datatype||void 0===e._data?e._datatype:e.getDataType(),f=n._values,l=n._index,p=n._ptr,m=n._size,h=n._datatype||void 0===n._data?n._datatype:n.getDataType();if(s.length!==m.length)throw new sn(s.length,m.length);if(s[0]!==m[0]||s[1]!==m[1])throw new RangeError("Dimension mismatch. Matrix A ("+s+") must match Matrix B ("+m+")");if(!a||!f)throw new Error("Cannot perform operation on Pattern Sparse Matrices");var d,v=s[0],y=s[1],g=r,x=0,b=i;"string"==typeof c&&c===h&&"mixed"!==c&&(d=c,g=t.find(r,[d,d]),x=t.convert(0,d),b=t.find(i,[d,d]));for(var w,D,N,E,A=[],S=[],C=[],M=[],F=[],O=0;O1)if(16==t||8==t){for(o=16==t?4:3,--s;s%o;s++)f+="0";for(s=(l=_t(f,i,t)).length;!l[s-1];--s);for(o=1,f="1.";os)for(a-=s;a--;)f+="0";else at)return e.length=t,!0}function er(e){return new this(e).abs()}function tr(e){return new this(e).acos()}function rr(e){return new this(e).acosh()}function nr(e,t){return new this(e).plus(t)}function ir(e){return new this(e).asin()}function ar(e){return new this(e).asinh()}function or(e){return new this(e).atan()}function ur(e){return new this(e).atanh()}function sr(e,t){e=new this(e),t=new this(t);var r,n=this.precision,i=this.rounding,a=n+4;return e.s&&t.s?e.d||t.d?!t.d||e.isZero()?(r=t.s<0?qt(this,n,i):new this(0)).s=e.s:!e.d||t.isZero()?(r=qt(this,a,1).times(.5)).s=e.s:t.s<0?(this.precision=a,this.rounding=1,r=this.atan(Bt(e,t,a,1)),t=qt(this,a,1),this.precision=n,this.rounding=i,r=e.s<0?r.minus(t):r.plus(t)):r=this.atan(Bt(e,t,a,1)):(r=qt(this,a,1).times(t.s>0?.25:.75)).s=e.s:r=new this(NaN),r}function cr(e){return new this(e).cbrt()}function fr(e){return kt(e=new this(e),e.e+1,2)}function lr(e,t,r){return new this(e).clamp(t,r)}function pr(e){if(!e||"object"!=typeof e)throw Error(mt+"Object expected");var t,r,n,i=!0===e.defaults,a=["precision",1,ut,"rounding",0,8,"toExpNeg",-ot,0,"toExpPos",0,ot,"maxE",0,ot,"minE",-ot,0,"modulo",0,9];for(t=0;t");var p=t.max().map((function(e){return e+1}));s(e,p,n);var m=a.length;o(e._data,t,r,m,0)}return e}(this,e,t,i);default:throw new SyntaxError("Wrong number of arguments")}},r.prototype.get=function(e){if(!f(e))throw new TypeError("Array expected");if(e.length!==this._size.length)throw new sn(e.length,this._size.length);for(var t=0;t0?n:0,c=n<0?-n:0,p=e[0],m=e[1],h=Math.min(p-c,m-s);if(f(t)){if(t.length!==h)throw new Error("Invalid value array length");u=function(e){return t[e]}}else if(l(t)){var d=t.size();if(1!==d.length||d[0]!==h)throw new Error("Invalid matrix length");u=function(e){return t.get([e])}}else u=function(){return t};o||(o=a(u(0))?u(0).mul(0):0);var v=[];if(e.length>0){v=vn(v,e,o);for(var y=0;y=2&&s.push("index: ".concat(H(r))),o.length>=3&&s.push("array: ".concat(H(n))),new TypeError("Function ".concat(i," cannot apply callback arguments ")+"".concat(e.name,"(").concat(s.join(", "),") at index ").concat(JSON.stringify(r)))}throw new TypeError("Function ".concat(i," cannot apply callback arguments ")+"to function ".concat(e.name,": ").concat(a.message))}}}var Tu=Ce("filter",["typed"],(function(e){return(0,e.typed)("filter",{"Array, function":_u,"Matrix, function":function(e,t){return e.create(_u(e.toArray(),t))},"Array, RegExp":Fn,"Matrix, RegExp":function(e,t){return e.create(Fn(e.toArray(),t))}})}));function _u(e,t){return Mn(e,(function(e,r,n){return Ou(t,e,[r],n,"filter")}))}var Bu="flatten",ku=Ce(Bu,["typed","matrix"],(function(e){var t=e.typed,r=e.matrix;return t(Bu,{Array:function(e){return An(e)},Matrix:function(e){var t=An(e.toArray());return r(t)}})})),Iu="forEach",zu=Ce(Iu,["typed"],(function(e){return(0,e.typed)(Iu,{"Array, function":Ru,"Matrix, function":function(e,t){e.forEach(t)}})}));function Ru(e,t){!function r(n,i){if(!Array.isArray(n))return Ou(t,n,i,e,"forEach");Cn(n,(function(e,t){r(e,i.concat(t))}))}(e,[])}var qu="getMatrixDataType",ju=Ce(qu,["typed"],(function(e){return(0,e.typed)(qu,{Array:function(e){return Bn(e,H)},Matrix:function(e){return e.getDataType()}})})),Pu="identity",Lu=Ce(Pu,["typed","config","matrix","BigNumber","DenseMatrix","SparseMatrix"],(function(e){var t=e.typed,r=e.config,n=e.matrix,i=e.BigNumber,o=e.DenseMatrix,u=e.SparseMatrix;return t(Pu,{"":function(){return"Matrix"===r.matrix?n([]):[]},string:function(e){return n(e)},"number | BigNumber":function(e){return c(e,e,"Matrix"===r.matrix?"dense":void 0)},"number | BigNumber, string":function(e,t){return c(e,e,t)},"number | BigNumber, number | BigNumber":function(e,t){return c(e,t,"Matrix"===r.matrix?"dense":void 0)},"number | BigNumber, number | BigNumber, string":function(e,t,r){return c(e,t,r)},Array:function(e){return s(e)},"Array, string":function(e,t){return s(e,t)},Matrix:function(e){return s(e.valueOf(),e.storage())},"Matrix, string":function(e,t){return s(e.valueOf(),t)}});function s(e,t){switch(e.length){case 0:return t?n(t):[];case 1:return c(e[0],e[0],t);case 2:return c(e[0],e[1],t);default:throw new Error("Vector containing two values expected")}}function c(e,t,r){var n=a(e)||a(t)?i:null;if(a(e)&&(e=e.toNumber()),a(t)&&(t=t.toNumber()),!V(e)||e<1)throw new Error("Parameters in function identity must be positive integers");if(!V(t)||t<1)throw new Error("Parameters in function identity must be positive integers");var s=n?new i(1):1,c=n?new n(0):0,f=[e,t];if(r){if("sparse"===r)return u.diagonal(f,s,0,c);if("dense"===r)return o.diagonal(f,s,0,c);throw new TypeError('Unknown matrix type "'.concat(r,'"'))}for(var l=vn([],f,c),p=e=0;d--){var v=r[d][0]||0;if(o(v,0))h[d]=[0];else{for(var y=0,g=[],x=[],b=m[d],w=m[d+1]-1;w>=b;w--){var D=p[w];D===d?y=l[w]:D
')}},{key:"_toTex",value:function(e){return this.blocks.map((function(t){return t.node.toTex(e)+(t.visible?"":";")})).join("\\;\\;\n")}}],[{key:"fromJSON",value:function(e){return new r(e.blocks)}}]),r}(e.Node);return Za(r,"name",Gp),r}),{isClass:!0,isNode:!0});function Zp(e,t,r){return t=bp(t),xp(e,Wp()?Reflect.construct(t,r||[],bp(e).constructor):t.apply(e,r))}function Wp(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(Wp=function(){return!!e})()}var Yp="ConditionalNode",Jp=Ce(Yp,["Node"],(function(e){var t=function(e){function t(e,r,n){var i;if(Be(this,t),i=Zp(this,t),!z(e))throw new TypeError("Parameter condition must be a Node");if(!z(r))throw new TypeError("Parameter trueExpr must be a Node");if(!z(n))throw new TypeError("Parameter falseExpr must be a Node");return i.condition=e,i.trueExpr=r,i.falseExpr=n,i}return Dp(t,e),ze(t,[{key:"type",get:function(){return Yp}},{key:"isConditionalNode",get:function(){return!0}},{key:"_compile",value:function(e,t){var r=this.condition._compile(e,t),n=this.trueExpr._compile(e,t),i=this.falseExpr._compile(e,t);return function(e,t,u){return function(e){if("number"==typeof e||"boolean"==typeof e||"string"==typeof e)return!!e;if(e){if(a(e))return!e.isZero();if(o(e))return!(!e.re&&!e.im);if(s(e))return!!e.value}if(null==e)return!1;throw new TypeError('Unsupported type of condition "'+H(e)+'"')}(r(e,t,u))?n(e,t,u):i(e,t,u)}}},{key:"forEach",value:function(e){e(this.condition,"condition",this),e(this.trueExpr,"trueExpr",this),e(this.falseExpr,"falseExpr",this)}},{key:"map",value:function(e){return new t(this._ifNode(e(this.condition,"condition",this)),this._ifNode(e(this.trueExpr,"trueExpr",this)),this._ifNode(e(this.falseExpr,"falseExpr",this)))}},{key:"clone",value:function(){return new t(this.condition,this.trueExpr,this.falseExpr)}},{key:"_toString",value:function(e){var t=e&&e.parenthesis?e.parenthesis:"keep",r=zp(this,t,e&&e.implicit),n=this.condition.toString(e),i=zp(this.condition,t,e&&e.implicit);("all"===t||"OperatorNode"===this.condition.type||null!==i&&i<=r)&&(n="("+n+")");var a=this.trueExpr.toString(e),o=zp(this.trueExpr,t,e&&e.implicit);("all"===t||"OperatorNode"===this.trueExpr.type||null!==o&&o<=r)&&(a="("+a+")");var u=this.falseExpr.toString(e),s=zp(this.falseExpr,t,e&&e.implicit);return("all"===t||"OperatorNode"===this.falseExpr.type||null!==s&&s<=r)&&(u="("+u+")"),n+" ? "+a+" : "+u}},{key:"toJSON",value:function(){return{mathjs:Yp,condition:this.condition,trueExpr:this.trueExpr,falseExpr:this.falseExpr}}},{key:"_toHTML",value:function(e){var t=e&&e.parenthesis?e.parenthesis:"keep",r=zp(this,t,e&&e.implicit),n=this.condition.toHTML(e),i=zp(this.condition,t,e&&e.implicit);("all"===t||"OperatorNode"===this.condition.type||null!==i&&i<=r)&&(n='('+n+')');var a=this.trueExpr.toHTML(e),o=zp(this.trueExpr,t,e&&e.implicit);("all"===t||"OperatorNode"===this.trueExpr.type||null!==o&&o<=r)&&(a='('+a+')');var u=this.falseExpr.toHTML(e),s=zp(this.falseExpr,t,e&&e.implicit);return("all"===t||"OperatorNode"===this.falseExpr.type||null!==s&&s<=r)&&(u='('+u+')'),n+'?'+a+':'+u}},{key:"_toTex",value:function(e){return"\\begin{cases} {"+this.trueExpr.toTex(e)+"}, &\\quad{\\text{if }\\;"+this.condition.toTex(e)+"}\\\\{"+this.falseExpr.toTex(e)+"}, &\\quad{\\text{otherwise}}\\end{cases}"}}],[{key:"fromJSON",value:function(e){return new t(e.condition,e.trueExpr,e.falseExpr)}}]),t}(e.Node);return Za(t,"name",Yp),t}),{isClass:!0,isNode:!0}),Xp=r(3144),Qp={Alpha:"A",alpha:"\\alpha",Beta:"B",beta:"\\beta",Gamma:"\\Gamma",gamma:"\\gamma",Delta:"\\Delta",delta:"\\delta",Epsilon:"E",epsilon:"\\epsilon",varepsilon:"\\varepsilon",Zeta:"Z",zeta:"\\zeta",Eta:"H",eta:"\\eta",Theta:"\\Theta",theta:"\\theta",vartheta:"\\vartheta",Iota:"I",iota:"\\iota",Kappa:"K",kappa:"\\kappa",varkappa:"\\varkappa",Lambda:"\\Lambda",lambda:"\\lambda",Mu:"M",mu:"\\mu",Nu:"N",nu:"\\nu",Xi:"\\Xi",xi:"\\xi",Omicron:"O",omicron:"o",Pi:"\\Pi",pi:"\\pi",varpi:"\\varpi",Rho:"P",rho:"\\rho",varrho:"\\varrho",Sigma:"\\Sigma",sigma:"\\sigma",varsigma:"\\varsigma",Tau:"T",tau:"\\tau",Upsilon:"\\Upsilon",upsilon:"\\upsilon",Phi:"\\Phi",phi:"\\phi",varphi:"\\varphi",Chi:"X",chi:"\\chi",Psi:"\\Psi",psi:"\\psi",Omega:"\\Omega",omega:"\\omega",true:"\\mathrm{True}",false:"\\mathrm{False}",i:"i",inf:"\\infty",Inf:"\\infty",infinity:"\\infty",Infinity:"\\infty",oo:"\\infty",lim:"\\lim",undefined:"\\mathbf{?}"},Kp={transpose:"^\\top",ctranspose:"^H",factorial:"!",pow:"^",dotPow:".^\\wedge",unaryPlus:"+",unaryMinus:"-",bitNot:"\\~",not:"\\neg",multiply:"\\cdot",divide:"\\frac",dotMultiply:".\\cdot",dotDivide:".:",mod:"\\mod",add:"+",subtract:"-",to:"\\rightarrow",leftShift:"<<",rightArithShift:">>",rightLogShift:">>>",equal:"=",unequal:"\\neq",smaller:"<",larger:">",smallerEq:"\\leq",largerEq:"\\geq",bitAnd:"\\&",bitXor:"\\underline{|}",bitOr:"|",and:"\\wedge",xor:"\\veebar",or:"\\vee"},em={abs:{1:"\\left|${args[0]}\\right|"},add:{2:"\\left(${args[0]}".concat(Kp.add,"${args[1]}\\right)")},cbrt:{1:"\\sqrt[3]{${args[0]}}"},ceil:{1:"\\left\\lceil${args[0]}\\right\\rceil"},cube:{1:"\\left(${args[0]}\\right)^3"},divide:{2:"\\frac{${args[0]}}{${args[1]}}"},dotDivide:{2:"\\left(${args[0]}".concat(Kp.dotDivide,"${args[1]}\\right)")},dotMultiply:{2:"\\left(${args[0]}".concat(Kp.dotMultiply,"${args[1]}\\right)")},dotPow:{2:"\\left(${args[0]}".concat(Kp.dotPow,"${args[1]}\\right)")},exp:{1:"\\exp\\left(${args[0]}\\right)"},expm1:"\\left(e".concat(Kp.pow,"{${args[0]}}-1\\right)"),fix:{1:"\\mathrm{${name}}\\left(${args[0]}\\right)"},floor:{1:"\\left\\lfloor${args[0]}\\right\\rfloor"},gcd:"\\gcd\\left(${args}\\right)",hypot:"\\hypot\\left(${args}\\right)",log:{1:"\\ln\\left(${args[0]}\\right)",2:"\\log_{${args[1]}}\\left(${args[0]}\\right)"},log10:{1:"\\log_{10}\\left(${args[0]}\\right)"},log1p:{1:"\\ln\\left(${args[0]}+1\\right)",2:"\\log_{${args[1]}}\\left(${args[0]}+1\\right)"},log2:"\\log_{2}\\left(${args[0]}\\right)",mod:{2:"\\left(${args[0]}".concat(Kp.mod,"${args[1]}\\right)")},multiply:{2:"\\left(${args[0]}".concat(Kp.multiply,"${args[1]}\\right)")},norm:{1:"\\left\\|${args[0]}\\right\\|",2:void 0},nthRoot:{2:"\\sqrt[${args[1]}]{${args[0]}}"},nthRoots:{2:"\\{y : $y^{args[1]} = {${args[0]}}\\}"},pow:{2:"\\left(${args[0]}\\right)".concat(Kp.pow,"{${args[1]}}")},round:{1:"\\left\\lfloor${args[0]}\\right\\rceil",2:void 0},sign:{1:"\\mathrm{${name}}\\left(${args[0]}\\right)"},sqrt:{1:"\\sqrt{${args[0]}}"},square:{1:"\\left(${args[0]}\\right)^2"},subtract:{2:"\\left(${args[0]}".concat(Kp.subtract,"${args[1]}\\right)")},unaryMinus:{1:"".concat(Kp.unaryMinus,"\\left(${args[0]}\\right)")},unaryPlus:{1:"".concat(Kp.unaryPlus,"\\left(${args[0]}\\right)")},bitAnd:{2:"\\left(${args[0]}".concat(Kp.bitAnd,"${args[1]}\\right)")},bitNot:{1:Kp.bitNot+"\\left(${args[0]}\\right)"},bitOr:{2:"\\left(${args[0]}".concat(Kp.bitOr,"${args[1]}\\right)")},bitXor:{2:"\\left(${args[0]}".concat(Kp.bitXor,"${args[1]}\\right)")},leftShift:{2:"\\left(${args[0]}".concat(Kp.leftShift,"${args[1]}\\right)")},rightArithShift:{2:"\\left(${args[0]}".concat(Kp.rightArithShift,"${args[1]}\\right)")},rightLogShift:{2:"\\left(${args[0]}".concat(Kp.rightLogShift,"${args[1]}\\right)")},bellNumbers:{1:"\\mathrm{B}_{${args[0]}}"},catalan:{1:"\\mathrm{C}_{${args[0]}}"},stirlingS2:{2:"\\mathrm{S}\\left(${args}\\right)"},arg:{1:"\\arg\\left(${args[0]}\\right)"},conj:{1:"\\left(${args[0]}\\right)^*"},im:{1:"\\Im\\left\\lbrace${args[0]}\\right\\rbrace"},re:{1:"\\Re\\left\\lbrace${args[0]}\\right\\rbrace"},and:{2:"\\left(${args[0]}".concat(Kp.and,"${args[1]}\\right)")},not:{1:Kp.not+"\\left(${args[0]}\\right)"},or:{2:"\\left(${args[0]}".concat(Kp.or,"${args[1]}\\right)")},xor:{2:"\\left(${args[0]}".concat(Kp.xor,"${args[1]}\\right)")},cross:{2:"\\left(${args[0]}\\right)\\times\\left(${args[1]}\\right)"},ctranspose:{1:"\\left(${args[0]}\\right)".concat(Kp.ctranspose)},det:{1:"\\det\\left(${args[0]}\\right)"},dot:{2:"\\left(${args[0]}\\cdot${args[1]}\\right)"},expm:{1:"\\exp\\left(${args[0]}\\right)"},inv:{1:"\\left(${args[0]}\\right)^{-1}"},pinv:{1:"\\left(${args[0]}\\right)^{+}"},sqrtm:{1:"{${args[0]}}".concat(Kp.pow,"{\\frac{1}{2}}")},trace:{1:"\\mathrm{tr}\\left(${args[0]}\\right)"},transpose:{1:"\\left(${args[0]}\\right)".concat(Kp.transpose)},combinations:{2:"\\binom{${args[0]}}{${args[1]}}"},combinationsWithRep:{2:"\\left(\\!\\!{\\binom{${args[0]}}{${args[1]}}}\\!\\!\\right)"},factorial:{1:"\\left(${args[0]}\\right)".concat(Kp.factorial)},gamma:{1:"\\Gamma\\left(${args[0]}\\right)"},lgamma:{1:"\\ln\\Gamma\\left(${args[0]}\\right)"},equal:{2:"\\left(${args[0]}".concat(Kp.equal,"${args[1]}\\right)")},larger:{2:"\\left(${args[0]}".concat(Kp.larger,"${args[1]}\\right)")},largerEq:{2:"\\left(${args[0]}".concat(Kp.largerEq,"${args[1]}\\right)")},smaller:{2:"\\left(${args[0]}".concat(Kp.smaller,"${args[1]}\\right)")},smallerEq:{2:"\\left(${args[0]}".concat(Kp.smallerEq,"${args[1]}\\right)")},unequal:{2:"\\left(${args[0]}".concat(Kp.unequal,"${args[1]}\\right)")},erf:{1:"erf\\left(${args[0]}\\right)"},max:"\\max\\left(${args}\\right)",min:"\\min\\left(${args}\\right)",variance:"\\mathrm{Var}\\left(${args}\\right)",acos:{1:"\\cos^{-1}\\left(${args[0]}\\right)"},acosh:{1:"\\cosh^{-1}\\left(${args[0]}\\right)"},acot:{1:"\\cot^{-1}\\left(${args[0]}\\right)"},acoth:{1:"\\coth^{-1}\\left(${args[0]}\\right)"},acsc:{1:"\\csc^{-1}\\left(${args[0]}\\right)"},acsch:{1:"\\mathrm{csch}^{-1}\\left(${args[0]}\\right)"},asec:{1:"\\sec^{-1}\\left(${args[0]}\\right)"},asech:{1:"\\mathrm{sech}^{-1}\\left(${args[0]}\\right)"},asin:{1:"\\sin^{-1}\\left(${args[0]}\\right)"},asinh:{1:"\\sinh^{-1}\\left(${args[0]}\\right)"},atan:{1:"\\tan^{-1}\\left(${args[0]}\\right)"},atan2:{2:"\\mathrm{atan2}\\left(${args}\\right)"},atanh:{1:"\\tanh^{-1}\\left(${args[0]}\\right)"},cos:{1:"\\cos\\left(${args[0]}\\right)"},cosh:{1:"\\cosh\\left(${args[0]}\\right)"},cot:{1:"\\cot\\left(${args[0]}\\right)"},coth:{1:"\\coth\\left(${args[0]}\\right)"},csc:{1:"\\csc\\left(${args[0]}\\right)"},csch:{1:"\\mathrm{csch}\\left(${args[0]}\\right)"},sec:{1:"\\sec\\left(${args[0]}\\right)"},sech:{1:"\\mathrm{sech}\\left(${args[0]}\\right)"},sin:{1:"\\sin\\left(${args[0]}\\right)"},sinh:{1:"\\sinh\\left(${args[0]}\\right)"},tan:{1:"\\tan\\left(${args[0]}\\right)"},tanh:{1:"\\tanh\\left(${args[0]}\\right)"},to:{2:"\\left(${args[0]}".concat(Kp.to,"${args[1]}\\right)")},numeric:function(e,t){return e.args[0].toTex()},number:{0:"0",1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)${args[1]}\\right)"},string:{0:'\\mathtt{""}',1:"\\mathrm{string}\\left(${args[0]}\\right)"},bignumber:{0:"0",1:"\\left(${args[0]}\\right)"},complex:{0:"0",1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)+".concat(Qp.i,"\\cdot\\left(${args[1]}\\right)\\right)")},matrix:{0:"\\begin{bmatrix}\\end{bmatrix}",1:"\\left(${args[0]}\\right)",2:"\\left(${args[0]}\\right)"},sparse:{0:"\\begin{bsparse}\\end{bsparse}",1:"\\left(${args[0]}\\right)"},unit:{1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)${args[1]}\\right)"}},tm={deg:"^\\circ"};function rm(e){return Xp(e,{preserveFormatting:!0})}function nm(e,t){return(t=void 0!==t&&t)?Ae(tm,e)?tm[e]:"\\mathrm{"+rm(e)+"}":Ae(Qp,e)?Qp[e]:rm(e)}function im(e,t,r){return t=bp(t),xp(e,am()?Reflect.construct(t,r||[],bp(e).constructor):t.apply(e,r))}function am(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){})))}catch(e){}return(am=function(){return!!e})()}var om="ConstantNode",um=Ce(om,["Node"],(function(e){var t=function(e){function t(e){var r;return Be(this,t),(r=im(this,t)).value=e,r}return Dp(t,e),ze(t,[{key:"type",get:function(){return om}},{key:"isConstantNode",get:function(){return!0}},{key:"_compile",value:function(e,t){var r=this.value;return function(){return r}}},{key:"forEach",value:function(e){}},{key:"map",value:function(e){return this.clone()}},{key:"clone",value:function(){return new t(this.value)}},{key:"_toString",value:function(e){return tn(this.value,e)}},{key:"_toHTML",value:function(e){var t=this._toString(e);switch(H(this.value)){case"number":case"BigNumber":case"Fraction":return''+t+"";case"string":return''+t+"";case"boolean":return''+t+"";case"null":return''+t+"";case"undefined":return''+t+"";default:return''+t+""}}},{key:"toJSON",value:function(){return{mathjs:om,value:this.value}}},{key:"_toTex",value:function(e){var t=this._toString(e);switch(H(this.value)){case"string":return"\\mathtt{"+rm(t)+"}";case"number":case"BigNumber":if(!isFinite(this.value))return this.value.valueOf()<0?"-\\infty":"\\infty";var r=t.toLowerCase().indexOf("e");return-1!==r?t.substring(0,r)+"\\cdot10^{"+t.substring(r+1)+"}":t;case"Fraction":return this.value.toLatex();default:return t}}}],[{key:"fromJSON",value:function(e){return new t(e.value)}}]),t}(e.Node);return Za(t,"name",om),t}),{isClass:!0,isNode:!0});function sm(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r