plotly.js-dist-min
Version:
Ready-to-use minified plotly.js distributed bundle.
18 lines • 4.65 MB
JavaScript
/**
* plotly.js v3.0.1
* Copyright 2012-2025, Plotly, Inc.
* All rights reserved.
* Licensed under the MIT license
*/
(
function(root, factory) {
if (typeof module === "object" && module.exports) {
module.exports = factory();
} else {
root.moduleName = factory();
}
} (typeof self !== "undefined" ? self : this, () => {
"use strict";var Plotly=(()=>{var VQe=Object.create;var MS=Object.defineProperty,HQe=Object.defineProperties,GQe=Object.getOwnPropertyDescriptor,jQe=Object.getOwnPropertyDescriptors,WQe=Object.getOwnPropertyNames,XQ=Object.getOwnPropertySymbols,ZQe=Object.getPrototypeOf,KQ=Object.prototype.hasOwnProperty,XQe=Object.prototype.propertyIsEnumerable;var YQ=(e,t,r)=>t in e?MS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,JQ=(e,t)=>{for(var r in t||(t={}))KQ.call(t,r)&&YQ(e,r,t[r]);if(XQ)for(var r of XQ(t))XQe.call(t,r)&&YQ(e,r,t[r]);return e},$Q=(e,t)=>HQe(e,jQe(t));var Ll=(e,t)=>()=>(e&&(t=e(e=0)),t);var ye=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),QQ=(e,t)=>{for(var r in t)MS(e,r,{get:t[r],enumerable:!0})},eee=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of WQe(t))!KQ.call(e,i)&&i!==r&&MS(e,i,{get:()=>t[i],enumerable:!(n=GQe(t,i))||n.enumerable});return e};var YQe=(e,t,r)=>(r=e!=null?VQe(ZQe(e)):{},eee(t||!e||!e.__esModule?MS(r,"default",{value:e,enumerable:!0}):r,e)),B1=e=>eee(MS({},"__esModule",{value:!0}),e);var e6=ye(tee=>{"use strict";tee.version="3.0.1"});var iee=ye((ree,t6)=>{(function(t,r,n){r[t]=r[t]||n(),typeof t6!="undefined"&&t6.exports&&(t6.exports=r[t])})("Promise",typeof window!="undefined"?window:ree,function(){"use strict";var t,r,n,i=Object.prototype.toString,a=typeof setImmediate!="undefined"?function(E){return setImmediate(E)}:setTimeout;try{Object.defineProperty({},"x",{}),t=function(E,k,A,L){return Object.defineProperty(E,k,{value:A,writable:!0,configurable:L!==!1})}}catch(p){t=function(k,A,L){return k[A]=L,k}}n=function(){var E,k,A;function L(_,C){this.fn=_,this.self=C,this.next=void 0}return{add:function(C,M){A=new L(C,M),k?k.next=A:E=A,k=A,A=void 0},drain:function(){var C=E;for(E=k=r=void 0;C;)C.fn.call(C.self),C=C.next}}}();function o(p,E){n.add(p,E),r||(r=a(n.drain))}function s(p){var E,k=typeof p;return p!=null&&(k=="object"||k=="function")&&(E=p.then),typeof E=="function"?E:!1}function l(){for(var p=0;p<this.chain.length;p++)u(this,this.state===1?this.chain[p].success:this.chain[p].failure,this.chain[p]);this.chain.length=0}function u(p,E,k){var A,L;try{E===!1?k.reject(p.msg):(E===!0?A=p.msg:A=E.call(void 0,p.msg),A===k.promise?k.reject(TypeError("Promise-chain cycle")):(L=s(A))?L.call(A,k.resolve,k.reject):k.resolve(A))}catch(_){k.reject(_)}}function c(p){var E,k=this;if(!k.triggered){k.triggered=!0,k.def&&(k=k.def);try{(E=s(p))?o(function(){var A=new d(k);try{E.call(p,function(){c.apply(A,arguments)},function(){f.apply(A,arguments)})}catch(L){f.call(A,L)}}):(k.msg=p,k.state=1,k.chain.length>0&&o(l,k))}catch(A){f.call(new d(k),A)}}}function f(p){var E=this;E.triggered||(E.triggered=!0,E.def&&(E=E.def),E.msg=p,E.state=2,E.chain.length>0&&o(l,E))}function h(p,E,k,A){for(var L=0;L<E.length;L++)(function(C){p.resolve(E[C]).then(function(g){k(C,g)},A)})(L)}function d(p){this.def=p,this.triggered=!1}function v(p){this.promise=p,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function x(p){if(typeof p!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var E=new v(this);this.then=function(A,L){var _={success:typeof A=="function"?A:!0,failure:typeof L=="function"?L:!1};return _.promise=new this.constructor(function(M,g){if(typeof M!="function"||typeof g!="function")throw TypeError("Not a function");_.resolve=M,_.reject=g}),E.chain.push(_),E.state!==0&&o(l,E),_.promise},this.catch=function(A){return this.then(void 0,A)};try{p.call(void 0,function(A){c.call(E,A)},function(A){f.call(E,A)})}catch(k){f.call(E,k)}}var b=t({},"constructor",x,!1);return x.prototype=b,t(b,"__NPO__",0,!1),t(x,"resolve",function(E){var k=this;return E&&typeof E=="object"&&E.__NPO__===1?E:new k(function(L,_){if(typeof L!="function"||typeof _!="function")throw TypeError("Not a function");L(E)})}),t(x,"reject",function(E){return new this(function(A,L){if(typeof A!="function"||typeof L!="function")throw TypeError("Not a function");L(E)})}),t(x,"all",function(E){var k=this;return i.call(E)!="[object Array]"?k.reject(TypeError("Not an array")):E.length===0?k.resolve([]):new k(function(L,_){if(typeof L!="function"||typeof _!="function")throw TypeError("Not a function");var C=E.length,M=Array(C),g=0;h(k,E,function(T,F){M[T]=F,++g===C&&L(M)},_)})}),t(x,"race",function(E){var k=this;return i.call(E)!="[object Array]"?k.reject(TypeError("Not an array")):new k(function(L,_){if(typeof L!="function"||typeof _!="function")throw TypeError("Not a function");h(k,E,function(M,g){L(g)},_)})}),x})});var xa=ye((qQt,r6)=>{(function(){var e={version:"3.8.2"},t=[].slice,r=function(Z){return t.call(Z)},n=self.document;function i(Z){return Z&&(Z.ownerDocument||Z.document||Z).documentElement}function a(Z){return Z&&(Z.ownerDocument&&Z.ownerDocument.defaultView||Z.document&&Z||Z.defaultView)}if(n)try{r(n.documentElement.childNodes)[0].nodeType}catch(Z){r=function(oe){for(var we=oe.length,Be=new Array(we);we--;)Be[we]=oe[we];return Be}}if(Date.now||(Date.now=function(){return+new Date}),n)try{n.createElement("DIV").style.setProperty("opacity",0,"")}catch(Z){var o=this.Element.prototype,s=o.setAttribute,l=o.setAttributeNS,u=this.CSSStyleDeclaration.prototype,c=u.setProperty;o.setAttribute=function(oe,we){s.call(this,oe,we+"")},o.setAttributeNS=function(oe,we,Be){l.call(this,oe,we,Be+"")},u.setProperty=function(oe,we,Be){c.call(this,oe,we+"",Be)}}e.ascending=f;function f(Z,oe){return Z<oe?-1:Z>oe?1:Z>=oe?0:NaN}e.descending=function(Z,oe){return oe<Z?-1:oe>Z?1:oe>=Z?0:NaN},e.min=function(Z,oe){var we=-1,Be=Z.length,Ue,We;if(arguments.length===1){for(;++we<Be;)if((We=Z[we])!=null&&We>=We){Ue=We;break}for(;++we<Be;)(We=Z[we])!=null&&Ue>We&&(Ue=We)}else{for(;++we<Be;)if((We=oe.call(Z,Z[we],we))!=null&&We>=We){Ue=We;break}for(;++we<Be;)(We=oe.call(Z,Z[we],we))!=null&&Ue>We&&(Ue=We)}return Ue},e.max=function(Z,oe){var we=-1,Be=Z.length,Ue,We;if(arguments.length===1){for(;++we<Be;)if((We=Z[we])!=null&&We>=We){Ue=We;break}for(;++we<Be;)(We=Z[we])!=null&&We>Ue&&(Ue=We)}else{for(;++we<Be;)if((We=oe.call(Z,Z[we],we))!=null&&We>=We){Ue=We;break}for(;++we<Be;)(We=oe.call(Z,Z[we],we))!=null&&We>Ue&&(Ue=We)}return Ue},e.extent=function(Z,oe){var we=-1,Be=Z.length,Ue,We,wt;if(arguments.length===1){for(;++we<Be;)if((We=Z[we])!=null&&We>=We){Ue=wt=We;break}for(;++we<Be;)(We=Z[we])!=null&&(Ue>We&&(Ue=We),wt<We&&(wt=We))}else{for(;++we<Be;)if((We=oe.call(Z,Z[we],we))!=null&&We>=We){Ue=wt=We;break}for(;++we<Be;)(We=oe.call(Z,Z[we],we))!=null&&(Ue>We&&(Ue=We),wt<We&&(wt=We))}return[Ue,wt]};function h(Z){return Z===null?NaN:+Z}function d(Z){return!isNaN(Z)}e.sum=function(Z,oe){var we=0,Be=Z.length,Ue,We=-1;if(arguments.length===1)for(;++We<Be;)d(Ue=+Z[We])&&(we+=Ue);else for(;++We<Be;)d(Ue=+oe.call(Z,Z[We],We))&&(we+=Ue);return we},e.mean=function(Z,oe){var we=0,Be=Z.length,Ue,We=-1,wt=Be;if(arguments.length===1)for(;++We<Be;)d(Ue=h(Z[We]))?we+=Ue:--wt;else for(;++We<Be;)d(Ue=h(oe.call(Z,Z[We],We)))?we+=Ue:--wt;if(wt)return we/wt},e.quantile=function(Z,oe){var we=(Z.length-1)*oe+1,Be=Math.floor(we),Ue=+Z[Be-1],We=we-Be;return We?Ue+We*(Z[Be]-Ue):Ue},e.median=function(Z,oe){var we=[],Be=Z.length,Ue,We=-1;if(arguments.length===1)for(;++We<Be;)d(Ue=h(Z[We]))&&we.push(Ue);else for(;++We<Be;)d(Ue=h(oe.call(Z,Z[We],We)))&&we.push(Ue);if(we.length)return e.quantile(we.sort(f),.5)},e.variance=function(Z,oe){var we=Z.length,Be=0,Ue,We,wt=0,tt=-1,zt=0;if(arguments.length===1)for(;++tt<we;)d(Ue=h(Z[tt]))&&(We=Ue-Be,Be+=We/++zt,wt+=We*(Ue-Be));else for(;++tt<we;)d(Ue=h(oe.call(Z,Z[tt],tt)))&&(We=Ue-Be,Be+=We/++zt,wt+=We*(Ue-Be));if(zt>1)return wt/(zt-1)},e.deviation=function(){var Z=e.variance.apply(this,arguments);return Z&&Math.sqrt(Z)};function v(Z){return{left:function(oe,we,Be,Ue){for(arguments.length<3&&(Be=0),arguments.length<4&&(Ue=oe.length);Be<Ue;){var We=Be+Ue>>>1;Z(oe[We],we)<0?Be=We+1:Ue=We}return Be},right:function(oe,we,Be,Ue){for(arguments.length<3&&(Be=0),arguments.length<4&&(Ue=oe.length);Be<Ue;){var We=Be+Ue>>>1;Z(oe[We],we)>0?Ue=We:Be=We+1}return Be}}}var x=v(f);e.bisectLeft=x.left,e.bisect=e.bisectRight=x.right,e.bisector=function(Z){return v(Z.length===1?function(oe,we){return f(Z(oe),we)}:Z)},e.shuffle=function(Z,oe,we){(Be=arguments.length)<3&&(we=Z.length,Be<2&&(oe=0));for(var Be=we-oe,Ue,We;Be;)We=Math.random()*Be--|0,Ue=Z[Be+oe],Z[Be+oe]=Z[We+oe],Z[We+oe]=Ue;return Z},e.permute=function(Z,oe){for(var we=oe.length,Be=new Array(we);we--;)Be[we]=Z[oe[we]];return Be},e.pairs=function(Z){for(var oe=0,we=Z.length-1,Be,Ue=Z[0],We=new Array(we<0?0:we);oe<we;)We[oe]=[Be=Ue,Ue=Z[++oe]];return We},e.transpose=function(Z){if(!(We=Z.length))return[];for(var oe=-1,we=e.min(Z,b),Be=new Array(we);++oe<we;)for(var Ue=-1,We,wt=Be[oe]=new Array(We);++Ue<We;)wt[Ue]=Z[Ue][oe];return Be};function b(Z){return Z.length}e.zip=function(){return e.transpose(arguments)},e.keys=function(Z){var oe=[];for(var we in Z)oe.push(we);return oe},e.values=function(Z){var oe=[];for(var we in Z)oe.push(Z[we]);return oe},e.entries=function(Z){var oe=[];for(var we in Z)oe.push({key:we,value:Z[we]});return oe},e.merge=function(Z){for(var oe=Z.length,we,Be=-1,Ue=0,We,wt;++Be<oe;)Ue+=Z[Be].length;for(We=new Array(Ue);--oe>=0;)for(wt=Z[oe],we=wt.length;--we>=0;)We[--Ue]=wt[we];return We};var p=Math.abs;e.range=function(Z,oe,we){if(arguments.length<3&&(we=1,arguments.length<2&&(oe=Z,Z=0)),(oe-Z)/we===1/0)throw new Error("infinite range");var Be=[],Ue=E(p(we)),We=-1,wt;if(Z*=Ue,oe*=Ue,we*=Ue,we<0)for(;(wt=Z+we*++We)>oe;)Be.push(wt/Ue);else for(;(wt=Z+we*++We)<oe;)Be.push(wt/Ue);return Be};function E(Z){for(var oe=1;Z*oe%1;)oe*=10;return oe}function k(Z,oe){for(var we in oe)Object.defineProperty(Z.prototype,we,{value:oe[we],enumerable:!1})}e.map=function(Z,oe){var we=new A;if(Z instanceof A)Z.forEach(function(tt,zt){we.set(tt,zt)});else if(Array.isArray(Z)){var Be=-1,Ue=Z.length,We;if(arguments.length===1)for(;++Be<Ue;)we.set(Be,Z[Be]);else for(;++Be<Ue;)we.set(oe.call(Z,We=Z[Be],Be),We)}else for(var wt in Z)we.set(wt,Z[wt]);return we};function A(){this._=Object.create(null)}var L="__proto__",_="\0";k(A,{has:g,get:function(Z){return this._[C(Z)]},set:function(Z,oe){return this._[C(Z)]=oe},remove:P,keys:T,values:function(){var Z=[];for(var oe in this._)Z.push(this._[oe]);return Z},entries:function(){var Z=[];for(var oe in this._)Z.push({key:M(oe),value:this._[oe]});return Z},size:F,empty:q,forEach:function(Z){for(var oe in this._)Z.call(this,M(oe),this._[oe])}});function C(Z){return(Z+="")===L||Z[0]===_?_+Z:Z}function M(Z){return(Z+="")[0]===_?Z.slice(1):Z}function g(Z){return C(Z)in this._}function P(Z){return(Z=C(Z))in this._&&delete this._[Z]}function T(){var Z=[];for(var oe in this._)Z.push(M(oe));return Z}function F(){var Z=0;for(var oe in this._)++Z;return Z}function q(){for(var Z in this._)return!1;return!0}e.nest=function(){var Z={},oe=[],we=[],Be,Ue;function We(tt,zt,or){if(or>=oe.length)return Ue?Ue.call(Z,zt):Be?zt.sort(Be):zt;for(var lr=-1,Dr=zt.length,Ir=oe[or++],oi,ui,qr,Kr=new A,ii;++lr<Dr;)(ii=Kr.get(oi=Ir(ui=zt[lr])))?ii.push(ui):Kr.set(oi,[ui]);return tt?(ui=tt(),qr=function(vi,ci){ui.set(vi,We(tt,ci,or))}):(ui={},qr=function(vi,ci){ui[vi]=We(tt,ci,or)}),Kr.forEach(qr),ui}function wt(tt,zt){if(zt>=oe.length)return tt;var or=[],lr=we[zt++];return tt.forEach(function(Dr,Ir){or.push({key:Dr,values:wt(Ir,zt)})}),lr?or.sort(function(Dr,Ir){return lr(Dr.key,Ir.key)}):or}return Z.map=function(tt,zt){return We(zt,tt,0)},Z.entries=function(tt){return wt(We(e.map,tt,0),0)},Z.key=function(tt){return oe.push(tt),Z},Z.sortKeys=function(tt){return we[oe.length-1]=tt,Z},Z.sortValues=function(tt){return Be=tt,Z},Z.rollup=function(tt){return Ue=tt,Z},Z},e.set=function(Z){var oe=new V;if(Z)for(var we=0,Be=Z.length;we<Be;++we)oe.add(Z[we]);return oe};function V(){this._=Object.create(null)}k(V,{has:g,add:function(Z){return this._[C(Z+="")]=!0,Z},remove:P,values:T,size:F,empty:q,forEach:function(Z){for(var oe in this._)Z.call(this,M(oe))}}),e.behavior={};function H(Z){return Z}e.rebind=function(Z,oe){for(var we=1,Be=arguments.length,Ue;++we<Be;)Z[Ue=arguments[we]]=X(Z,oe,oe[Ue]);return Z};function X(Z,oe,we){return function(){var Be=we.apply(oe,arguments);return Be===oe?Z:Be}}function G(Z,oe){if(oe in Z)return oe;oe=oe.charAt(0).toUpperCase()+oe.slice(1);for(var we=0,Be=N.length;we<Be;++we){var Ue=N[we]+oe;if(Ue in Z)return Ue}}var N=["webkit","ms","moz","Moz","o","O"];function W(){}e.dispatch=function(){for(var Z=new re,oe=-1,we=arguments.length;++oe<we;)Z[arguments[oe]]=ae(Z);return Z};function re(){}re.prototype.on=function(Z,oe){var we=Z.indexOf("."),Be="";if(we>=0&&(Be=Z.slice(we+1),Z=Z.slice(0,we)),Z)return arguments.length<2?this[Z].on(Be):this[Z].on(Be,oe);if(arguments.length===2){if(oe==null)for(Z in this)this.hasOwnProperty(Z)&&this[Z].on(Be,null);return this}};function ae(Z){var oe=[],we=new A;function Be(){for(var Ue=oe,We=-1,wt=Ue.length,tt;++We<wt;)(tt=Ue[We].on)&&tt.apply(this,arguments);return Z}return Be.on=function(Ue,We){var wt=we.get(Ue),tt;return arguments.length<2?wt&&wt.on:(wt&&(wt.on=null,oe=oe.slice(0,tt=oe.indexOf(wt)).concat(oe.slice(tt+1)),we.remove(Ue)),We&&oe.push(we.set(Ue,{on:We})),Z)},Be}e.event=null;function _e(){e.event.preventDefault()}function Me(){for(var Z=e.event,oe;oe=Z.sourceEvent;)Z=oe;return Z}function ke(Z){for(var oe=new re,we=0,Be=arguments.length;++we<Be;)oe[arguments[we]]=ae(oe);return oe.of=function(Ue,We){return function(wt){try{var tt=wt.sourceEvent=e.event;wt.target=Z,e.event=wt,oe[wt.type].apply(Ue,We)}finally{e.event=tt}}},oe}e.requote=function(Z){return Z.replace(ge,"\\$&")};var ge=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,ie={}.__proto__?function(Z,oe){Z.__proto__=oe}:function(Z,oe){for(var we in oe)Z[we]=oe[we]};function Te(Z){return ie(Z,Ce),Z}var Ee=function(Z,oe){return oe.querySelector(Z)},Ae=function(Z,oe){return oe.querySelectorAll(Z)},ze=function(Z,oe){var we=Z.matches||Z[G(Z,"matchesSelector")];return ze=function(Be,Ue){return we.call(Be,Ue)},ze(Z,oe)};typeof Sizzle=="function"&&(Ee=function(Z,oe){return Sizzle(Z,oe)[0]||null},Ae=Sizzle,ze=Sizzle.matchesSelector),e.selection=function(){return e.select(n.documentElement)};var Ce=e.selection.prototype=[];Ce.select=function(Z){var oe=[],we,Be,Ue,We;Z=me(Z);for(var wt=-1,tt=this.length;++wt<tt;){oe.push(we=[]),we.parentNode=(Ue=this[wt]).parentNode;for(var zt=-1,or=Ue.length;++zt<or;)(We=Ue[zt])?(we.push(Be=Z.call(We,We.__data__,zt,wt)),Be&&"__data__"in We&&(Be.__data__=We.__data__)):we.push(null)}return Te(oe)};function me(Z){return typeof Z=="function"?Z:function(){return Ee(Z,this)}}Ce.selectAll=function(Z){var oe=[],we,Be;Z=Re(Z);for(var Ue=-1,We=this.length;++Ue<We;)for(var wt=this[Ue],tt=-1,zt=wt.length;++tt<zt;)(Be=wt[tt])&&(oe.push(we=r(Z.call(Be,Be.__data__,tt,Ue))),we.parentNode=Be);return Te(oe)};function Re(Z){return typeof Z=="function"?Z:function(){return Ae(Z,this)}}var ce="http://www.w3.org/1999/xhtml",Ge={svg:"http://www.w3.org/2000/svg",xhtml:ce,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};e.ns={prefix:Ge,qualify:function(Z){var oe=Z.indexOf(":"),we=Z;return oe>=0&&(we=Z.slice(0,oe))!=="xmlns"&&(Z=Z.slice(oe+1)),Ge.hasOwnProperty(we)?{space:Ge[we],local:Z}:Z}},Ce.attr=function(Z,oe){if(arguments.length<2){if(typeof Z=="string"){var we=this.node();return Z=e.ns.qualify(Z),Z.local?we.getAttributeNS(Z.space,Z.local):we.getAttribute(Z)}for(oe in Z)this.each(nt(oe,Z[oe]));return this}return this.each(nt(Z,oe))};function nt(Z,oe){Z=e.ns.qualify(Z);function we(){this.removeAttribute(Z)}function Be(){this.removeAttributeNS(Z.space,Z.local)}function Ue(){this.setAttribute(Z,oe)}function We(){this.setAttributeNS(Z.space,Z.local,oe)}function wt(){var zt=oe.apply(this,arguments);zt==null?this.removeAttribute(Z):this.setAttribute(Z,zt)}function tt(){var zt=oe.apply(this,arguments);zt==null?this.removeAttributeNS(Z.space,Z.local):this.setAttributeNS(Z.space,Z.local,zt)}return oe==null?Z.local?Be:we:typeof oe=="function"?Z.local?tt:wt:Z.local?We:Ue}function ct(Z){return Z.trim().replace(/\s+/g," ")}Ce.classed=function(Z,oe){if(arguments.length<2){if(typeof Z=="string"){var we=this.node(),Be=(Z=rt(Z)).length,Ue=-1;if(oe=we.classList){for(;++Ue<Be;)if(!oe.contains(Z[Ue]))return!1}else for(oe=we.getAttribute("class");++Ue<Be;)if(!qt(Z[Ue]).test(oe))return!1;return!0}for(oe in Z)this.each(ot(oe,Z[oe]));return this}return this.each(ot(Z,oe))};function qt(Z){return new RegExp("(?:^|\\s+)"+e.requote(Z)+"(?:\\s+|$)","g")}function rt(Z){return(Z+"").trim().split(/^|\s+/)}function ot(Z,oe){Z=rt(Z).map(Rt);var we=Z.length;function Be(){for(var We=-1;++We<we;)Z[We](this,oe)}function Ue(){for(var We=-1,wt=oe.apply(this,arguments);++We<we;)Z[We](this,wt)}return typeof oe=="function"?Ue:Be}function Rt(Z){var oe=qt(Z);return function(we,Be){if(Ue=we.classList)return Be?Ue.add(Z):Ue.remove(Z);var Ue=we.getAttribute("class")||"";Be?(oe.lastIndex=0,oe.test(Ue)||we.setAttribute("class",ct(Ue+" "+Z))):we.setAttribute("class",ct(Ue.replace(oe," ")))}}Ce.style=function(Z,oe,we){var Be=arguments.length;if(Be<3){if(typeof Z!="string"){Be<2&&(oe="");for(we in Z)this.each(kt(we,Z[we],oe));return this}if(Be<2){var Ue=this.node();return a(Ue).getComputedStyle(Ue,null).getPropertyValue(Z)}we=""}return this.each(kt(Z,oe,we))};function kt(Z,oe,we){function Be(){this.style.removeProperty(Z)}function Ue(){this.style.setProperty(Z,oe,we)}function We(){var wt=oe.apply(this,arguments);wt==null?this.style.removeProperty(Z):this.style.setProperty(Z,wt,we)}return oe==null?Be:typeof oe=="function"?We:Ue}Ce.property=function(Z,oe){if(arguments.length<2){if(typeof Z=="string")return this.node()[Z];for(oe in Z)this.each(Ct(oe,Z[oe]));return this}return this.each(Ct(Z,oe))};function Ct(Z,oe){function we(){delete this[Z]}function Be(){this[Z]=oe}function Ue(){var We=oe.apply(this,arguments);We==null?delete this[Z]:this[Z]=We}return oe==null?we:typeof oe=="function"?Ue:Be}Ce.text=function(Z){return arguments.length?this.each(typeof Z=="function"?function(){var oe=Z.apply(this,arguments);this.textContent=oe==null?"":oe}:Z==null?function(){this.textContent=""}:function(){this.textContent=Z}):this.node().textContent},Ce.html=function(Z){return arguments.length?this.each(typeof Z=="function"?function(){var oe=Z.apply(this,arguments);this.innerHTML=oe==null?"":oe}:Z==null?function(){this.innerHTML=""}:function(){this.innerHTML=Z}):this.node().innerHTML},Ce.append=function(Z){return Z=Yt(Z),this.select(function(){return this.appendChild(Z.apply(this,arguments))})};function Yt(Z){function oe(){var Be=this.ownerDocument,Ue=this.namespaceURI;return Ue===ce&&Be.documentElement.namespaceURI===ce?Be.createElement(Z):Be.createElementNS(Ue,Z)}function we(){return this.ownerDocument.createElementNS(Z.space,Z.local)}return typeof Z=="function"?Z:(Z=e.ns.qualify(Z)).local?we:oe}Ce.insert=function(Z,oe){return Z=Yt(Z),oe=me(oe),this.select(function(){return this.insertBefore(Z.apply(this,arguments),oe.apply(this,arguments)||null)})},Ce.remove=function(){return this.each(xr)};function xr(){var Z=this.parentNode;Z&&Z.removeChild(this)}Ce.data=function(Z,oe){var we=-1,Be=this.length,Ue,We;if(!arguments.length){for(Z=new Array(Be=(Ue=this[0]).length);++we<Be;)(We=Ue[we])&&(Z[we]=We.__data__);return Z}function wt(lr,Dr){var Ir,oi=lr.length,ui=Dr.length,qr=Math.min(oi,ui),Kr=new Array(ui),ii=new Array(ui),vi=new Array(oi),ci,Jr;if(oe){var un=new A,dn=new Array(oi),En;for(Ir=-1;++Ir<oi;)(ci=lr[Ir])&&(un.has(En=oe.call(ci,ci.__data__,Ir))?vi[Ir]=ci:un.set(En,ci),dn[Ir]=En);for(Ir=-1;++Ir<ui;)(ci=un.get(En=oe.call(Dr,Jr=Dr[Ir],Ir)))?ci!==!0&&(Kr[Ir]=ci,ci.__data__=Jr):ii[Ir]=er(Jr),un.set(En,!0);for(Ir=-1;++Ir<oi;)Ir in dn&&un.get(dn[Ir])!==!0&&(vi[Ir]=lr[Ir])}else{for(Ir=-1;++Ir<qr;)ci=lr[Ir],Jr=Dr[Ir],ci?(ci.__data__=Jr,Kr[Ir]=ci):ii[Ir]=er(Jr);for(;Ir<ui;++Ir)ii[Ir]=er(Dr[Ir]);for(;Ir<oi;++Ir)vi[Ir]=lr[Ir]}ii.update=Kr,ii.parentNode=Kr.parentNode=vi.parentNode=lr.parentNode,tt.push(ii),zt.push(Kr),or.push(vi)}var tt=Lt([]),zt=Te([]),or=Te([]);if(typeof Z=="function")for(;++we<Be;)wt(Ue=this[we],Z.call(Ue,Ue.parentNode.__data__,we));else for(;++we<Be;)wt(Ue=this[we],Z);return zt.enter=function(){return tt},zt.exit=function(){return or},zt};function er(Z){return{__data__:Z}}Ce.datum=function(Z){return arguments.length?this.property("__data__",Z):this.property("__data__")},Ce.filter=function(Z){var oe=[],we,Be,Ue;typeof Z!="function"&&(Z=Ke(Z));for(var We=0,wt=this.length;We<wt;We++){oe.push(we=[]),we.parentNode=(Be=this[We]).parentNode;for(var tt=0,zt=Be.length;tt<zt;tt++)(Ue=Be[tt])&&Z.call(Ue,Ue.__data__,tt,We)&&we.push(Ue)}return Te(oe)};function Ke(Z){return function(){return ze(this,Z)}}Ce.order=function(){for(var Z=-1,oe=this.length;++Z<oe;)for(var we=this[Z],Be=we.length-1,Ue=we[Be],We;--Be>=0;)(We=we[Be])&&(Ue&&Ue!==We.nextSibling&&Ue.parentNode.insertBefore(We,Ue),Ue=We);return this},Ce.sort=function(Z){Z=xt.apply(this,arguments);for(var oe=-1,we=this.length;++oe<we;)this[oe].sort(Z);return this.order()};function xt(Z){return arguments.length||(Z=f),function(oe,we){return oe&&we?Z(oe.__data__,we.__data__):!oe-!we}}Ce.each=function(Z){return bt(this,function(oe,we,Be){Z.call(oe,oe.__data__,we,Be)})};function bt(Z,oe){for(var we=0,Be=Z.length;we<Be;we++)for(var Ue=Z[we],We=0,wt=Ue.length,tt;We<wt;We++)(tt=Ue[We])&&oe(tt,We,we);return Z}Ce.call=function(Z){var oe=r(arguments);return Z.apply(oe[0]=this,oe),this},Ce.empty=function(){return!this.node()},Ce.node=function(){for(var Z=0,oe=this.length;Z<oe;Z++)for(var we=this[Z],Be=0,Ue=we.length;Be<Ue;Be++){var We=we[Be];if(We)return We}return null},Ce.size=function(){var Z=0;return bt(this,function(){++Z}),Z};function Lt(Z){return ie(Z,St),Z}var St=[];e.selection.enter=Lt,e.selection.enter.prototype=St,St.append=Ce.append,St.empty=Ce.empty,St.node=Ce.node,St.call=Ce.call,St.size=Ce.size,St.select=function(Z){for(var oe=[],we,Be,Ue,We,wt,tt=-1,zt=this.length;++tt<zt;){Ue=(We=this[tt]).update,oe.push(we=[]),we.parentNode=We.parentNode;for(var or=-1,lr=We.length;++or<lr;)(wt=We[or])?(we.push(Ue[or]=Be=Z.call(We.parentNode,wt.__data__,or,tt)),Be.__data__=wt.__data__):we.push(null)}return Te(oe)},St.insert=function(Z,oe){return arguments.length<2&&(oe=Et(this)),Ce.insert.call(this,Z,oe)};function Et(Z){var oe,we;return function(Be,Ue,We){var wt=Z[We].update,tt=wt.length,zt;for(We!=we&&(we=We,oe=0),Ue>=oe&&(oe=Ue+1);!(zt=wt[oe])&&++oe<tt;);return zt}}e.select=function(Z){var oe;return typeof Z=="string"?(oe=[Ee(Z,n)],oe.parentNode=n.documentElement):(oe=[Z],oe.parentNode=i(Z)),Te([oe])},e.selectAll=function(Z){var oe;return typeof Z=="string"?(oe=r(Ae(Z,n)),oe.parentNode=n.documentElement):(oe=r(Z),oe.parentNode=null),Te([oe])},Ce.on=function(Z,oe,we){var Be=arguments.length;if(Be<3){if(typeof Z!="string"){Be<2&&(oe=!1);for(we in Z)this.each(dt(we,Z[we],oe));return this}if(Be<2)return(Be=this.node()["__on"+Z])&&Be._;we=!1}return this.each(dt(Z,oe,we))};function dt(Z,oe,we){var Be="__on"+Z,Ue=Z.indexOf("."),We=$t;Ue>0&&(Z=Z.slice(0,Ue));var wt=Ht.get(Z);wt&&(Z=wt,We=fr);function tt(){var lr=this[Be];lr&&(this.removeEventListener(Z,lr,lr.$),delete this[Be])}function zt(){var lr=We(oe,r(arguments));tt.call(this),this.addEventListener(Z,this[Be]=lr,lr.$=we),lr._=oe}function or(){var lr=new RegExp("^__on([^.]+)"+e.requote(Z)+"$"),Dr;for(var Ir in this)if(Dr=Ir.match(lr)){var oi=this[Ir];this.removeEventListener(Dr[1],oi,oi.$),delete this[Ir]}}return Ue?oe?zt:tt:oe?W:or}var Ht=e.map({mouseenter:"mouseover",mouseleave:"mouseout"});n&&Ht.forEach(function(Z){"on"+Z in n&&Ht.remove(Z)});function $t(Z,oe){return function(we){var Be=e.event;e.event=we,oe[0]=this.__data__;try{Z.apply(this,oe)}finally{e.event=Be}}}function fr(Z,oe){var we=$t(Z,oe);return function(Be){var Ue=this,We=Be.relatedTarget;(!We||We!==Ue&&!(We.compareDocumentPosition(Ue)&8))&&we.call(Ue,Be)}}var _r,Br=0;function Or(Z){var oe=".dragsuppress-"+ ++Br,we="click"+oe,Be=e.select(a(Z)).on("touchmove"+oe,_e).on("dragstart"+oe,_e).on("selectstart"+oe,_e);if(_r==null&&(_r="onselectstart"in Z?!1:G(Z.style,"userSelect")),_r){var Ue=i(Z).style,We=Ue[_r];Ue[_r]="none"}return function(wt){if(Be.on(oe,null),_r&&(Ue[_r]=We),wt){var tt=function(){Be.on(we,null)};Be.on(we,function(){_e(),tt()},!0),setTimeout(tt,0)}}}e.mouse=function(Z){return ut(Z,Me())};var Nr=this.navigator&&/WebKit/.test(this.navigator.userAgent)?-1:0;function ut(Z,oe){oe.changedTouches&&(oe=oe.changedTouches[0]);var we=Z.ownerSVGElement||Z;if(we.createSVGPoint){var Be=we.createSVGPoint();if(Nr<0){var Ue=a(Z);if(Ue.scrollX||Ue.scrollY){we=e.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var We=we[0][0].getScreenCTM();Nr=!(We.f||We.e),we.remove()}}return Nr?(Be.x=oe.pageX,Be.y=oe.pageY):(Be.x=oe.clientX,Be.y=oe.clientY),Be=Be.matrixTransform(Z.getScreenCTM().inverse()),[Be.x,Be.y]}var wt=Z.getBoundingClientRect();return[oe.clientX-wt.left-Z.clientLeft,oe.clientY-wt.top-Z.clientTop]}e.touch=function(Z,oe,we){if(arguments.length<3&&(we=oe,oe=Me().changedTouches),oe){for(var Be=0,Ue=oe.length,We;Be<Ue;++Be)if((We=oe[Be]).identifier===we)return ut(Z,We)}},e.behavior.drag=function(){var Z=ke(Ue,"drag","dragstart","dragend"),oe=null,we=We(W,e.mouse,a,"mousemove","mouseup"),Be=We(Ne,e.touch,H,"touchmove","touchend");function Ue(){this.on("mousedown.drag",we).on("touchstart.drag",Be)}function We(wt,tt,zt,or,lr){return function(){var Dr=this,Ir=e.event.target.correspondingElement||e.event.target,oi=Dr.parentNode,ui=Z.of(Dr,arguments),qr=0,Kr=wt(),ii=".drag"+(Kr==null?"":"-"+Kr),vi,ci=e.select(zt(Ir)).on(or+ii,dn).on(lr+ii,En),Jr=Or(Ir),un=tt(oi,Kr);oe?(vi=oe.apply(Dr,arguments),vi=[vi.x-un[0],vi.y-un[1]]):vi=[0,0],ui({type:"dragstart"});function dn(){var Nn=tt(oi,Kr),ga,ya;Nn&&(ga=Nn[0]-un[0],ya=Nn[1]-un[1],qr|=ga|ya,un=Nn,ui({type:"drag",x:Nn[0]+vi[0],y:Nn[1]+vi[1],dx:ga,dy:ya}))}function En(){tt(oi,Kr)&&(ci.on(or+ii,null).on(lr+ii,null),Jr(qr),ui({type:"dragend"}))}}}return Ue.origin=function(wt){return arguments.length?(oe=wt,Ue):oe},e.rebind(Ue,Z,"on")};function Ne(){return e.event.changedTouches[0].identifier}e.touches=function(Z,oe){return arguments.length<2&&(oe=Me().touches),oe?r(oe).map(function(we){var Be=ut(Z,we);return Be.identifier=we.identifier,Be}):[]};var Ye=1e-6,Ve=Ye*Ye,Xe=Math.PI,ht=2*Xe,Le=ht-Ye,xe=Xe/2,Se=Xe/180,lt=180/Xe;function Gt(Z){return Z>0?1:Z<0?-1:0}function Vt(Z,oe,we){return(oe[0]-Z[0])*(we[1]-Z[1])-(oe[1]-Z[1])*(we[0]-Z[0])}function ar(Z){return Z>1?0:Z<-1?Xe:Math.acos(Z)}function Qr(Z){return Z>1?xe:Z<-1?-xe:Math.asin(Z)}function ai(Z){return((Z=Math.exp(Z))-1/Z)/2}function jr(Z){return((Z=Math.exp(Z))+1/Z)/2}function ri(Z){return((Z=Math.exp(2*Z))-1)/(Z+1)}function bi(Z){return(Z=Math.sin(Z/2))*Z}var nn=Math.SQRT2,Wi=2,Ni=4;e.interpolateZoom=function(Z,oe){var we=Z[0],Be=Z[1],Ue=Z[2],We=oe[0],wt=oe[1],tt=oe[2],zt=We-we,or=wt-Be,lr=zt*zt+or*or,Dr,Ir;if(lr<Ve)Ir=Math.log(tt/Ue)/nn,Dr=function(vi){return[we+vi*zt,Be+vi*or,Ue*Math.exp(nn*vi*Ir)]};else{var oi=Math.sqrt(lr),ui=(tt*tt-Ue*Ue+Ni*lr)/(2*Ue*Wi*oi),qr=(tt*tt-Ue*Ue-Ni*lr)/(2*tt*Wi*oi),Kr=Math.log(Math.sqrt(ui*ui+1)-ui),ii=Math.log(Math.sqrt(qr*qr+1)-qr);Ir=(ii-Kr)/nn,Dr=function(vi){var ci=vi*Ir,Jr=jr(Kr),un=Ue/(Wi*oi)*(Jr*ri(nn*ci+Kr)-ai(Kr));return[we+un*zt,Be+un*or,Ue*Jr/jr(nn*ci+Kr)]}}return Dr.duration=Ir*1e3,Dr},e.behavior.zoom=function(){var Z={x:0,y:0,k:1},oe,we,Be,Ue=[960,500],We=_n,wt=250,tt=0,zt="mousedown.zoom",or="mousemove.zoom",lr="mouseup.zoom",Dr,Ir="touchstart.zoom",oi,ui=ke(ci,"zoomstart","zoom","zoomend"),qr,Kr,ii,vi;zn||(zn="onwheel"in n?($i=function(){return-e.event.deltaY*(e.event.deltaMode?120:1)},"wheel"):"onmousewheel"in n?($i=function(){return e.event.wheelDelta},"mousewheel"):($i=function(){return-e.event.detail},"MozMousePixelScroll"));function ci(pn){pn.on(zt,io).on(zn+".zoom",_s).on("dblclick.zoom",Ns).on(Ir,Ss)}ci.event=function(pn){pn.each(function(){var za=ui.of(this,arguments),Lo=Z;Ro?e.select(this).transition().each("start.zoom",function(){Z=this.__chart__||{x:0,y:0,k:1},ya(za)}).tween("zoom:zoom",function(){var Fo=Ue[0],js=Ue[1],xl=we?we[0]:Fo/2,fu=we?we[1]:js/2,dl=e.interpolateZoom([(xl-Z.x)/Z.k,(fu-Z.y)/Z.k,Fo/Z.k],[(xl-Lo.x)/Lo.k,(fu-Lo.y)/Lo.k,Fo/Lo.k]);return function(xc){var At=dl(xc),Er=Fo/At[2];this.__chart__=Z={x:xl-At[0]*Er,y:fu-At[1]*Er,k:Er},so(za)}}).each("interrupt.zoom",function(){wa(za)}).each("end.zoom",function(){wa(za)}):(this.__chart__=Z,ya(za),so(za),wa(za))})},ci.translate=function(pn){return arguments.length?(Z={x:+pn[0],y:+pn[1],k:Z.k},ga(),ci):[Z.x,Z.y]},ci.scale=function(pn){return arguments.length?(Z={x:Z.x,y:Z.y,k:null},dn(+pn),ga(),ci):Z.k},ci.scaleExtent=function(pn){return arguments.length?(We=pn==null?_n:[+pn[0],+pn[1]],ci):We},ci.center=function(pn){return arguments.length?(Be=pn&&[+pn[0],+pn[1]],ci):Be},ci.size=function(pn){return arguments.length?(Ue=pn&&[+pn[0],+pn[1]],ci):Ue},ci.duration=function(pn){return arguments.length?(wt=+pn,ci):wt},ci.x=function(pn){return arguments.length?(Kr=pn,qr=pn.copy(),Z={x:0,y:0,k:1},ci):Kr},ci.y=function(pn){return arguments.length?(vi=pn,ii=pn.copy(),Z={x:0,y:0,k:1},ci):vi};function Jr(pn){return[(pn[0]-Z.x)/Z.k,(pn[1]-Z.y)/Z.k]}function un(pn){return[pn[0]*Z.k+Z.x,pn[1]*Z.k+Z.y]}function dn(pn){Z.k=Math.max(We[0],Math.min(We[1],pn))}function En(pn,za){za=un(za),Z.x+=pn[0]-za[0],Z.y+=pn[1]-za[1]}function Nn(pn,za,Lo,Fo){pn.__chart__={x:Z.x,y:Z.y,k:Z.k},dn(Math.pow(2,Fo)),En(we=za,Lo),pn=e.select(pn),wt>0&&(pn=pn.transition().duration(wt)),pn.call(ci.event)}function ga(){Kr&&Kr.domain(qr.range().map(function(pn){return(pn-Z.x)/Z.k}).map(qr.invert)),vi&&vi.domain(ii.range().map(function(pn){return(pn-Z.y)/Z.k}).map(ii.invert))}function ya(pn){tt++||pn({type:"zoomstart"})}function so(pn){ga(),pn({type:"zoom",scale:Z.k,translate:[Z.x,Z.y]})}function wa(pn){--tt||(pn({type:"zoomend"}),we=null)}function io(){var pn=this,za=ui.of(pn,arguments),Lo=0,Fo=e.select(a(pn)).on(or,fu).on(lr,dl),js=Jr(e.mouse(pn)),xl=Or(pn);ea.call(pn),ya(za);function fu(){Lo=1,En(e.mouse(pn),js),so(za)}function dl(){Fo.on(or,null).on(lr,null),xl(Lo),wa(za)}}function Ss(){var pn=this,za=ui.of(pn,arguments),Lo={},Fo=0,js,xl=".zoom-"+e.event.changedTouches[0].identifier,fu="touchmove"+xl,dl="touchend"+xl,xc=[],At=e.select(pn),Er=Or(pn);wi(),ya(za),At.on(zt,null).on(Ir,wi);function Wr(){var Bi=e.touches(pn);return js=Z.k,Bi.forEach(function(cn){cn.identifier in Lo&&(Lo[cn.identifier]=Jr(cn))}),Bi}function wi(){var Bi=e.event.target;e.select(Bi).on(fu,Ui).on(dl,Oi),xc.push(Bi);for(var cn=e.event.changedTouches,On=0,Bn=cn.length;On<Bn;++On)Lo[cn[On].identifier]=null;var yn=Wr(),to=Date.now();if(yn.length===1){if(to-oi<500){var Rn=yn[0];Nn(pn,Rn,Lo[Rn.identifier],Math.floor(Math.log(Z.k)/Math.LN2)+1),_e()}oi=to}else if(yn.length>1){var Rn=yn[0],Dn=yn[1],fn=Rn[0]-Dn[0],Ai=Rn[1]-Dn[1];Fo=fn*fn+Ai*Ai}}function Ui(){var Bi=e.touches(pn),cn,On,Bn,yn;ea.call(pn);for(var to=0,Rn=Bi.length;to<Rn;++to,yn=null)if(Bn=Bi[to],yn=Lo[Bn.identifier]){if(On)break;cn=Bn,On=yn}if(yn){var Dn=(Dn=Bn[0]-cn[0])*Dn+(Dn=Bn[1]-cn[1])*Dn,fn=Fo&&Math.sqrt(Dn/Fo);cn=[(cn[0]+Bn[0])/2,(cn[1]+Bn[1])/2],On=[(On[0]+yn[0])/2,(On[1]+yn[1])/2],dn(fn*js)}oi=null,En(cn,On),so(za)}function Oi(){if(e.event.touches.length){for(var Bi=e.event.changedTouches,cn=0,On=Bi.length;cn<On;++cn)delete Lo[Bi[cn].identifier];for(var Bn in Lo)return void Wr()}e.selectAll(xc).on(xl,null),At.on(zt,io).on(Ir,Ss),Er(),wa(za)}}function _s(){var pn=ui.of(this,arguments);Dr?clearTimeout(Dr):(ea.call(this),oe=Jr(we=Be||e.mouse(this)),ya(pn)),Dr=setTimeout(function(){Dr=null,wa(pn)},50),_e(),dn(Math.pow(2,$i()*.002)*Z.k),En(we,oe),so(pn)}function Ns(){var pn=e.mouse(this),za=Math.log(Z.k)/Math.LN2;Nn(this,pn,Jr(pn),e.event.shiftKey?Math.ceil(za)-1:Math.floor(za)+1)}return e.rebind(ci,ui,"on")};var _n=[0,1/0],$i,zn;e.color=Wn;function Wn(){}Wn.prototype.toString=function(){return this.rgb()+""},e.hsl=It;function It(Z,oe,we){return this instanceof It?(this.h=+Z,this.s=+oe,void(this.l=+we)):arguments.length<2?Z instanceof It?new It(Z.h,Z.s,Z.l):Ha(""+Z,oo,It):new It(Z,oe,we)}var ft=It.prototype=new Wn;ft.brighter=function(Z){return Z=Math.pow(.7,arguments.length?Z:1),new It(this.h,this.s,this.l/Z)},ft.darker=function(Z){return Z=Math.pow(.7,arguments.length?Z:1),new It(this.h,this.s,Z*this.l)},ft.rgb=function(){return jt(this.h,this.s,this.l)};function jt(Z,oe,we){var Be,Ue;Z=isNaN(Z)?0:(Z%=360)<0?Z+360:Z,oe=isNaN(oe)||oe<0?0:oe>1?1:oe,we=we<0?0:we>1?1:we,Ue=we<=.5?we*(1+oe):we+oe-we*oe,Be=2*we-Ue;function We(tt){return tt>360?tt-=360:tt<0&&(tt+=360),tt<60?Be+(Ue-Be)*tt/60:tt<180?Ue:tt<240?Be+(Ue-Be)*(240-tt)/60:Be}function wt(tt){return Math.round(We(tt)*255)}return new Fa(wt(Z+120),wt(Z),wt(Z-120))}e.hcl=Zt;function Zt(Z,oe,we){return this instanceof Zt?(this.h=+Z,this.c=+oe,void(this.l=+we)):arguments.length<2?Z instanceof Zt?new Zt(Z.h,Z.c,Z.l):Z instanceof Zr?Ki(Z.l,Z.a,Z.b):Ki((Z=xn((Z=e.rgb(Z)).r,Z.g,Z.b)).l,Z.a,Z.b):new Zt(Z,oe,we)}var yr=Zt.prototype=new Wn;yr.brighter=function(Z){return new Zt(this.h,this.c,Math.min(100,this.l+Vr*(arguments.length?Z:1)))},yr.darker=function(Z){return new Zt(this.h,this.c,Math.max(0,this.l-Vr*(arguments.length?Z:1)))},yr.rgb=function(){return Fr(this.h,this.c,this.l).rgb()};function Fr(Z,oe,we){return isNaN(Z)&&(Z=0),isNaN(oe)&&(oe=0),new Zr(we,Math.cos(Z*=Se)*oe,Math.sin(Z)*oe)}e.lab=Zr;function Zr(Z,oe,we){return this instanceof Zr?(this.l=+Z,this.a=+oe,void(this.b=+we)):arguments.length<2?Z instanceof Zr?new Zr(Z.l,Z.a,Z.b):Z instanceof Zt?Fr(Z.h,Z.c,Z.l):xn((Z=Fa(Z)).r,Z.g,Z.b):new Zr(Z,oe,we)}var Vr=18,gi=.95047,Si=1,Mi=1.08883,Pi=Zr.prototype=new Wn;Pi.brighter=function(Z){return new Zr(Math.min(100,this.l+Vr*(arguments.length?Z:1)),this.a,this.b)},Pi.darker=function(Z){return new Zr(Math.max(0,this.l-Vr*(arguments.length?Z:1)),this.a,this.b)},Pi.rgb=function(){return Gi(this.l,this.a,this.b)};function Gi(Z,oe,we){var Be=(Z+16)/116,Ue=Be+oe/500,We=Be-we/200;return Ue=ka(Ue)*gi,Be=ka(Be)*Si,We=ka(We)*Mi,new Fa(la(3.2404542*Ue-1.5371385*Be-.4985314*We),la(-.969266*Ue+1.8760108*Be+.041556*We),la(.0556434*Ue-.2040259*Be+1.0572252*We))}function Ki(Z,oe,we){return Z>0?new Zt(Math.atan2(we,oe)*lt,Math.sqrt(oe*oe+we*we),Z):new Zt(NaN,NaN,Z)}function ka(Z){return Z>.206893034?Z*Z*Z:(Z-4/29)/7.787037}function jn(Z){return Z>.008856?Math.pow(Z,1/3):7.787037*Z+4/29}function la(Z){return Math.round(255*(Z<=.00304?12.92*Z:1.055*Math.pow(Z,1/2.4)-.055))}e.rgb=Fa;function Fa(Z,oe,we){return this instanceof Fa?(this.r=~~Z,this.g=~~oe,void(this.b=~~we)):arguments.length<2?Z instanceof Fa?new Fa(Z.r,Z.g,Z.b):Ha(""+Z,Fa,jt):new Fa(Z,oe,we)}function Ra(Z){return new Fa(Z>>16,Z>>8&255,Z&255)}function jo(Z){return Ra(Z)+""}var oa=Fa.prototype=new Wn;oa.brighter=function(Z){Z=Math.pow(.7,arguments.length?Z:1);var oe=this.r,we=this.g,Be=this.b,Ue=30;return!oe&&!we&&!Be?new Fa(Ue,Ue,Ue):(oe&&oe<Ue&&(oe=Ue),we&&we<Ue&&(we=Ue),Be&&Be<Ue&&(Be=Ue),new Fa(Math.min(255,oe/Z),Math.min(255,we/Z),Math.min(255,Be/Z)))},oa.darker=function(Z){return Z=Math.pow(.7,arguments.length?Z:1),new Fa(Z*this.r,Z*this.g,Z*this.b)},oa.hsl=function(){return oo(this.r,this.g,this.b)},oa.toString=function(){return"#"+Sn(this.r)+Sn(this.g)+Sn(this.b)};function Sn(Z){return Z<16?"0"+Math.max(0,Z).toString(16):Math.min(255,Z).toString(16)}function Ha(Z,oe,we){var Be=0,Ue=0,We=0,wt,tt,zt;if(wt=/([a-z]+)\((.*)\)/.exec(Z=Z.toLowerCase()),wt)switch(tt=wt[2].split(","),wt[1]){case"hsl":return we(parseFloat(tt[0]),parseFloat(tt[1])/100,parseFloat(tt[2])/100);case"rgb":return oe(br(tt[0]),br(tt[1]),br(tt[2]))}return(zt=Hr.get(Z))?oe(zt.r,zt.g,zt.b):(Z!=null&&Z.charAt(0)==="#"&&!isNaN(zt=parseInt(Z.slice(1),16))&&(Z.length===4?(Be=(zt&3840)>>4,Be=Be>>4|Be,Ue=zt&240,Ue=Ue>>4|Ue,We=zt&15,We=We<<4|We):Z.length===7&&(Be=(zt&16711680)>>16,Ue=(zt&65280)>>8,We=zt&255)),oe(Be,Ue,We))}function oo(Z,oe,we){var Be=Math.min(Z/=255,oe/=255,we/=255),Ue=Math.max(Z,oe,we),We=Ue-Be,wt,tt,zt=(Ue+Be)/2;return We?(tt=zt<.5?We/(Ue+Be):We/(2-Ue-Be),Z==Ue?wt=(oe-we)/We+(oe<we?6:0):oe==Ue?wt=(we-Z)/We+2:wt=(Z-oe)/We+4,wt*=60):(wt=NaN,tt=zt>0&&zt<1?0:wt),new It(wt,tt,zt)}function xn(Z,oe,we){Z=_t(Z),oe=_t(oe),we=_t(we);var Be=jn((.4124564*Z+.3575761*oe+.1804375*we)/gi),Ue=jn((.2126729*Z+.7151522*oe+.072175*we)/Si),We=jn((.0193339*Z+.119192*oe+.9503041*we)/Mi);return Zr(116*Ue-16,500*(Be-Ue),200*(Ue-We))}function _t(Z){return(Z/=255)<=.04045?Z/12.92:Math.pow((Z+.055)/1.055,2.4)}function br(Z){var oe=parseFloat(Z);return Z.charAt(Z.length-1)==="%"?Math.round(oe*2.55):oe}var Hr=e.map({aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074});Hr.forEach(function(Z,oe){Hr.set(Z,Ra(oe))});function ti(Z){return typeof Z=="function"?Z:function(){return Z}}e.functor=ti,e.xhr=zi(H);function zi(Z){return function(oe,we,Be){return arguments.length===2&&typeof we=="function"&&(Be=we,we=null),Yi(oe,we,Z,Be)}}function Yi(Z,oe,we,Be){var Ue={},We=e.dispatch("beforesend","progress","load","error"),wt={},tt=new XMLHttpRequest,zt=null;self.XDomainRequest&&!("withCredentials"in tt)&&/^(http(s)?:)?\/\//.test(Z)&&(tt=new XDomainRequest),"onload"in tt?tt.onload=tt.onerror=or:tt.onreadystatechange=function(){tt.readyState>3&&or()};function or(){var lr=tt.status,Dr;if(!lr&&hi(tt)||lr>=200&&lr<300||lr===304){try{Dr=we.call(Ue,tt)}catch(Ir){We.error.call(Ue,Ir);return}We.load.call(Ue,Dr)}else We.error.call(Ue,tt)}return tt.onprogress=function(lr){var Dr=e.event;e.event=lr;try{We.progress.call(Ue,tt)}finally{e.event=Dr}},Ue.header=function(lr,Dr){return lr=(lr+"").toLowerCase(),arguments.length<2?wt[lr]:(Dr==null?delete wt[lr]:wt[lr]=Dr+"",Ue)},Ue.mimeType=function(lr){return arguments.length?(oe=lr==null?null:lr+"",Ue):oe},Ue.responseType=function(lr){return arguments.length?(zt=lr,Ue):zt},Ue.response=function(lr){return we=lr,Ue},["get","post"].forEach(function(lr){Ue[lr]=function(){return Ue.send.apply(Ue,[lr].concat(r(arguments)))}}),Ue.send=function(lr,Dr,Ir){if(arguments.length===2&&typeof Dr=="function"&&(Ir=Dr,Dr=null),tt.open(lr,Z,!0),oe!=null&&!("accept"in wt)&&(wt.accept=oe+",*/*"),tt.setRequestHeader)for(var oi in wt)tt.setRequestHeader(oi,wt[oi]);return oe!=null&&tt.overrideMimeType&&tt.overrideMimeType(oe),zt!=null&&(tt.responseType=zt),Ir!=null&&Ue.on("error",Ir).on("load",function(ui){Ir(null,ui)}),We.beforesend.call(Ue,tt),tt.send(Dr==null?null:Dr),Ue},Ue.abort=function(){return tt.abort(),Ue},e.rebind(Ue,We,"on"),Be==null?Ue:Ue.get(an(Be))}function an(Z){return Z.length===1?function(oe,we){Z(oe==null?we:null)}:Z}function hi(Z){var oe=Z.responseType;return oe&&oe!=="text"?Z.response:Z.responseText}e.dsv=function(Z,oe){var we=new RegExp('["'+Z+`
]`),Be=Z.charCodeAt(0);function Ue(or,lr,Dr){arguments.length<3&&(Dr=lr,lr=null);var Ir=Yi(or,oe,lr==null?We:wt(lr),Dr);return Ir.row=function(oi){return arguments.length?Ir.response((lr=oi)==null?We:wt(oi)):lr},Ir}function We(or){return Ue.parse(or.responseText)}function wt(or){return function(lr){return Ue.parse(lr.responseText,or)}}Ue.parse=function(or,lr){var Dr;return Ue.parseRows(or,function(Ir,oi){if(Dr)return Dr(Ir,oi-1);var ui=function(qr){for(var Kr={},ii=Ir.length,vi=0;vi<ii;++vi)Kr[Ir[vi]]=qr[vi];return Kr};Dr=lr?function(qr,Kr){return lr(ui(qr),Kr)}:ui})},Ue.parseRows=function(or,lr){var Dr={},Ir={},oi=[],ui=or.length,qr=0,Kr=0,ii,vi;function ci(){if(qr>=ui)return Ir;if(vi)return vi=!1,Dr;var un=qr;if(or.charCodeAt(un)===34){for(var dn=un;dn++<ui;)if(or.charCodeAt(dn)===34){if(or.charCodeAt(dn+1)!==34)break;++dn}qr=dn+2;var En=or.charCodeAt(dn+1);return En===13?(vi=!0,or.charCodeAt(dn+2)===10&&++qr):En===10&&(vi=!0),or.slice(un+1,dn).replace(/""/g,'"')}for(;qr<ui;){var En=or.charCodeAt(qr++),Nn=1;if(En===10)vi=!0;else if(En===13)vi=!0,or.charCodeAt(qr)===10&&(++qr,++Nn);else if(En!==Be)continue;return or.slice(un,qr-Nn)}return or.slice(un)}for(;(ii=ci())!==Ir;){for(var Jr=[];ii!==Dr&&ii!==Ir;)Jr.push(ii),ii=ci();lr&&(Jr=lr(Jr,Kr++))==null||oi.push(Jr)}return oi},Ue.format=function(or){if(Array.isArray(or[0]))return Ue.formatRows(or);var lr=new V,Dr=[];return or.forEach(function(Ir){for(var oi in Ir)lr.has(oi)||Dr.push(lr.add(oi))}),[Dr.map(zt).join(Z)].concat(or.map(function(Ir){return Dr.map(function(oi){return zt(Ir[oi])}).join(Z)})).join(`
`)},Ue.formatRows=function(or){return or.map(tt).join(`
`)};function tt(or){return or.map(zt).join(Z)}function zt(or){return we.test(or)?'"'+or.replace(/\"/g,'""')+'"':or}return Ue},e.csv=e.dsv(",","text/csv"),e.tsv=e.dsv(" ","text/tab-separated-values");var Ji,ua,Fn,Sa,go=this[G(this,"requestAnimationFrame")]||function(Z){setTimeout(Z,17)};e.timer=function(){Oo.apply(this,arguments)};function Oo(Z,oe,we){var Be=arguments.length;Be<2&&(oe=0),Be<3&&(we=Date.now());var Ue=we+oe,We={c:Z,t:Ue,n:null};return ua?ua.n=We:Ji=We,ua=We,Fn||(Sa=clearTimeout(Sa),Fn=1,go(ho)),We}function ho(){var Z=Mo(),oe=xo()-Z;oe>24?(isFinite(oe)&&(clearTimeout(Sa),Sa=setTimeout(ho,oe)),Fn=0):(Fn=1,go(ho))}e.timer.flush=function(){Mo(),xo()};function Mo(){for(var Z=Date.now(),oe=Ji;oe;)Z>=oe.t&&oe.c(Z-oe.t)&&(oe.c=null),oe=oe.n;return Z}function xo(){for(var Z,oe=Ji,we=1/0;oe;)oe.c?(oe.t<we&&(we=oe.t),oe=(Z=oe).n):oe=Z?Z.n=oe.n:Ji=oe.n;return ua=Z,we}e.round=function(Z,oe){return oe?Math.round(Z*(oe=Math.pow(10,oe)))/oe:Math.round(Z)},e.geom={};function zs(Z){return Z[0]}function ks(Z){return Z[1]}e.geom.hull=function(Z){var oe=zs,we=ks;if(arguments.length)return Be(Z);function Be(Ue){if(Ue.length<3)return[];var We=ti(oe),wt=ti(we),tt,zt=Ue.length,or=[],lr=[];for(tt=0;tt<zt;tt++)or.push([+We.call(this,Ue[tt],tt),+wt.call(this,Ue[tt],tt),tt]);for(or.sort(Xs),tt=0;tt<zt;tt++)lr.push([or[tt][0],-or[tt][1]]);var Dr=Zs(or),Ir=Zs(lr),oi=Ir[0]===Dr[0],ui=Ir[Ir.length-1]===Dr[Dr.length-1],qr=[];for(tt=Dr.length-1;tt>=0;--tt)qr.push(Ue[or[Dr[tt]][2]]);for(tt=+oi;tt<Ir.length-ui;++tt)qr.push(Ue[or[Ir[tt]][2]]);return qr}return Be.x=function(Ue){return arguments.length?(oe=Ue,Be):oe},Be.y=function(Ue){return arguments.length?(we=Ue,Be):we},Be};function Zs(Z){for(var oe=Z.length,we=[0,1],Be=2,Ue=2;Ue<oe;Ue++){for(;Be>1&&Vt(Z[we[Be-2]],Z[we[Be-1]],Z[Ue])<=0;)--Be;we[Be++]=Ue}return we.slice(0,Be)}function Xs(Z,oe){return Z[0]-oe[0]||Z[1]-oe[1]}e.geom.polygon=function(Z){return ie(Z,wl),Z};var wl=e.geom.polygon.prototype=[];wl.area=function(){for(var Z=-1,oe=this.length,we,Be=this[oe-1],Ue=0;++Z<oe;)we=Be,Be=this[Z],Ue+=we[1]*Be[0]-we[0]*Be[1];return Ue*.5},wl.centroid=function(Z){var oe=-1,we=this.length,Be=0,Ue=0,We,wt=this[we-1],tt;for(arguments.length||(Z=-1/(6*this.area()));++oe<we;)We=wt,wt=this[oe],tt=We[0]*wt[1]-wt[0]*We[1],Be+=(We[0]+wt[0])*tt,Ue+=(We[1]+wt[1])*tt;return[Be*Z,Ue*Z]},wl.clip=function(Z){for(var oe,we=Cs(Z),Be=-1,Ue=this.length-Cs(this),We,wt,tt=this[Ue-1],zt,or,lr;++Be<Ue;){for(oe=Z.slice(),Z.length=0,zt=this[Be],or=oe[(wt=oe.length-we)-1],We=-1;++We<wt;)lr=oe[We],os(lr,tt,zt)?(os(or,tt,zt)||Z.push(cl(or,lr,tt,zt)),Z.push(lr)):os(or,tt,zt)&&Z.push(cl(or,lr,tt,zt)),or=lr;we&&Z.push(Z[0]),tt=zt}return Z};function os(Z,oe,we){return(we[0]-oe[0])*(Z[1]-oe[1])<(we[1]-oe[1])*(Z[0]-oe[0])}function cl(Z,oe,we,Be){var Ue=Z[0],We=we[0],wt=oe[0]-Ue,tt=Be[0]-We,zt=Z[1],or=we[1],lr=oe[1]-zt,Dr=Be[1]-or,Ir=(tt*(zt-or)-Dr*(Ue-We))/(Dr*wt-tt*lr);return[Ue+Ir*wt,zt+Ir*lr]}function Cs(Z){var oe=Z[0],we=Z[Z.length-1];return!(oe[0]-we[0]||oe[1]-we[1])}var ml,Ys,Hs,Eo=[],fs,Ql,Hu=[];function fc(){Ls(this),this.edge=this.site=this.circle=null}function ms(Z){var oe=Eo.pop()||new fc;return oe.site=Z,oe}function on(Z){ko(Z),Hs.remove(Z),Eo.push(Z),Ls(Z)}function fa(Z){var oe=Z.circle,we=oe.x,Be=oe.cy,Ue={x:we,y:Be},We=Z.P,wt=Z.N,tt=[Z];on(Z);for(var zt=We;zt.circle&&p(we-zt.circle.x)<Ye&&p(Be-zt.circle.cy)<Ye;)We=zt.P,tt.unshift(zt),on(zt),zt=We;tt.unshift(zt),ko(zt);for(var or=wt;or.circle&&p(we-or.circle.x)<Ye&&p(Be-or.circle.cy)<Ye;)wt=or.N,tt.push(or),on(or),or=wt;tt.push(or),ko(or);var lr=tt.length,Dr;for(Dr=1;Dr<lr;++Dr)or=tt[Dr],zt=tt[Dr-1],Al(or.edge,zt.site,or.site,Ue);zt=tt[0],or=tt[lr-1],or.edge=cf(zt.site,or.site,null,Ue),Zn(zt),Zn(or)}function Qu(Z){for(var oe=Z.x,we=Z.y,Be,Ue,We,wt,tt=Hs._;tt;)if(We=Rl(tt,we)-oe,We>Ye)tt=tt.L;else if(wt=oe-vo(tt,we),wt>Ye){if(!tt.R){Be=tt;break}tt=tt.R}else{We>-Ye?(Be=tt.P,Ue=tt):wt>-Ye?(Be=tt,Ue=tt.N):Be=Ue=tt;break}var zt=ms(Z);if(Hs.insert(Be,zt),!(!Be&&!Ue)){if(Be===Ue){ko(Be),Ue=ms(Be.site),Hs.insert(zt,Ue),zt.edge=Ue.edge=cf(Be.site,zt.site),Zn(Be),Zn(Ue);return}if(!Ue){zt.edge=cf(Be.site,zt.site);return}ko(Be),ko(Ue);var or=Be.site,lr=or.x,Dr=or.y,Ir=Z.x-lr,oi=Z.y-Dr,ui=Ue.site,qr=ui.x-lr,Kr=ui.y-Dr,ii=2*(Ir*Kr-oi*qr),vi=Ir*Ir+oi*oi,ci=qr*qr+Kr*Kr,Jr={x:(Kr*vi-oi*ci)/ii+lr,y:(Ir*ci-qr*vi)/ii+Dr};Al(Ue.edge,or,ui,Jr),zt.edge=cf(or,Z,null,Jr),Ue.edge=cf(Z,ui,null,Jr),Zn(Be),Zn(Ue)}}function Rl(Z,oe){var we=Z.site,Be=we.x,Ue=we.y,We=Ue-oe;if(!We)return Be;var wt=Z.P;if(!wt)return-1/0;we=wt.site;var tt=we.x,zt=we.y,or=zt-oe;if(!or)return tt;var lr=tt-Be,Dr=1/We-1/or,Ir=lr/or;return Dr?(-Ir+Math.sqrt(Ir*Ir-2*Dr*(lr*lr/(-2*or)-zt+or/2+Ue-We/2)))/Dr+Be:(Be+tt)/2}function vo(Z,oe){var we=Z.N;if(we)return Rl(we,oe);var Be=Z.site;return Be.y===oe?Be.x:1/0}function Zl(Z){this.site=Z,this.edges=[]}Zl.prototype.prepare=function(){for(var Z=this.edges,oe=Z.length,we;oe--;)we=Z[oe].edge,(!we.b||!we.a)&&Z.splice(oe,1);return Z.sort(Xl),Z.length};function Ks(Z){for(var oe=Z[0][0],we=Z[1][0],Be=Z[0][1],Ue=Z[1][1],We,wt,tt,zt,or=Ys,lr=or.length,Dr,Ir,oi,ui,qr,Kr;lr--;)if(Dr=or[lr],!(!Dr||!Dr.prepare()))for(oi=Dr.edges,ui=oi.length,Ir=0;Ir<ui;)Kr=oi[Ir].end(),tt=Kr.x,zt=Kr.y,qr=oi[++Ir%ui].start(),We=qr.x,wt=qr.y,(p(tt-We)>Ye||p(zt-wt)>Ye)&&(oi.splice(Ir,0,new Hc(rh(Dr.site,Kr,p(tt-oe)<Ye&&Ue-zt>Ye?{x:oe,y:p(We-oe)<Ye?wt:Ue}:p(zt-Ue)<Ye&&we-tt>Ye?{x:p(wt-Ue)<Ye?We:we,y:Ue}:p(tt-we)<Ye&&zt-Be>Ye?{x:we,y:p(We-we)<Ye?wt:Be}:p(zt-Be)<Ye&&tt-oe>Ye?{x:p(wt-Be)<Ye?We:oe,y:Be}:null),Dr.site,null)),++ui)}function Xl(Z,oe){return oe.angle-Z.angle}function Ec(){Ls(this),this.x=this.y=this.arc=this.site=this.cy=null}function Zn(Z){var oe=Z.P,we=Z.N;if(!(!oe||!we)){var Be=oe.site,Ue=Z.site,We=we.site;if(Be!==We){var wt=Ue.x,tt=Ue.y,zt=Be.x-wt,or=Be.y-tt,lr=We.x-wt,Kr=We.y-tt,Dr=2*(zt*Kr-or*lr);if(!(Dr>=-Ve)){var Ir=zt*zt+or*or,oi=lr*lr+Kr*Kr,ui=(Kr*Ir-or*oi)/Dr,qr=(zt*oi-lr*Ir)/Dr,Kr=qr+tt,ii=Hu.pop()||new Ec;ii.arc=Z,ii.site=Ue,ii.x=ui+wt,ii.y=Kr+Math.sqrt(ui*ui+qr*qr),ii.cy=Kr,Z.circle=ii;for(var vi=null,ci=Ql._;ci;)if(ii.y<ci.y||ii.y===ci.y&&ii.x<=ci.x)if(ci.L)ci=ci.L;else{vi=ci.P;break}else if(ci.R)ci=ci.R;else{vi=ci;break}Ql.insert(vi,ii),vi||(fs=ii)}}}}function ko(Z){var oe=Z.circle;oe&&(oe.P||(fs=oe.N),Ql.remove(oe),Hu.push(oe),Ls(oe),Z.circle=null)}function Co(Z,oe,we,Be){return function(Ue){var We=Ue.a,wt=Ue.b,tt=We.x,zt=We.y,or=wt.x,lr=wt.y,Dr=0,Ir=1,oi=or-tt,ui=lr-zt,qr;if(qr=Z-tt,!(!oi&&qr>0)){if(qr/=oi,oi<0){if(qr<Dr)return;qr<Ir&&(Ir=qr)}else if(oi>0){if(qr>Ir)return;qr>Dr&&(Dr=qr)}if(qr=we-tt,!(!oi&&qr<0)){if(qr/=oi,oi<0){if(qr>Ir)return;qr>Dr&&(Dr=qr)}else if(oi>0){if(qr<Dr)return;qr<Ir&&(Ir=qr)}if(qr=oe-zt,!(!ui&&qr>0)){if(qr/=u