(function(){function v(b){return"m0,"+b+"a"+b+","+b+" 0 1,1 0,"+-2*b+"a"+b+","+b+" 0 1,1 0,"+ +2*b+"z"}function u(){return 0}function q(b,d){return d&&d.type in b?b[d.type](d):""}function w(b,d){if(b.type in y)y[b.type](b,d)}function z(b,d){for(var g=b.coordinates,e=0,k=g.length;e<k;e++)d.apply(null,g[e])}d3.geo={};d3.geo.albers=function(){function b(a){var c=l*(r*a[0]-i);a=Math.sqrt(p-2*l*Math.sin(r*a[1]))/l;return[k*a*Math.sin(c)+h[0],k*(a*Math.cos(c)-s)+h[1]]}function d(){var a=r*e[0],c=r*e[1],
f=r*g[1],j=Math.sin(a);a=Math.cos(a);i=r*g[0];l=0.5*(j+Math.sin(c));p=a*a+2*l*j;s=Math.sqrt(p-2*l*Math.sin(f))/l;return b}var g=[-98,38],e=[29.5,45.5],k=1E3,h=[480,250],i,l,p,s;b.origin=function(a){if(!arguments.length)return g;g=[+a[0],+a[1]];return d()};b.parallels=function(a){if(!arguments.length)return e;e=[+a[0],+a[1]];return d()};b.scale=function(a){if(!arguments.length)return k;k=+a;return b};b.translate=function(a){if(!arguments.length)return h;h=[+a[0],+a[1]];return b};return d()};d3.geo.albersUsa=
function(){function b(h){var i=h[0],l=h[1];return(l<25?i<-100?e:k:l>50?g:d)(h)}var d=d3.geo.albers(),g=d3.geo.albers().origin([-160,60]).parallels([55,65]),e=d3.geo.albers().origin([-160,20]).parallels([8,18]),k=d3.geo.albers().origin([-60,10]).parallels([8,18]);b.scale=function(h){if(!arguments.length)return d.scale();d.scale(h);g.scale(h*0.6);e.scale(h);k.scale(h*1.5);return b.translate(d.translate())};b.translate=function(h){if(!arguments.length)return d.translate();var i=d.scale()/1E3,l=h[0],
p=h[1];d.translate(h);g.translate([l-400*i,p+170*i]);e.translate([l-190*i,p+200*i]);k.translate([l+580*i,p+430*i]);return b};return b.scale(d.scale())};var r=Math.PI/180;d3.geo.mercator=function(){function b(e){return[d*(e[0]/360)+g[0],d*Math.max(-0.5,Math.min(0.5,-180/Math.PI*Math.log(Math.tan(Math.PI/4+e[1]*Math.PI/360))/360))+g[1]]}var d=500,g=[480,250];b.scale=function(e){if(!arguments.length)return d;d=+e;return b};b.translate=function(e){if(!arguments.length)return g;g=[+e[0],+e[1]];return b};
return b};d3.geo.path=function(){function b(a){if(typeof k=="function")h=v(k.apply(this,arguments));return q(l,a)}function d(a){return i(a).join(",")}function g(a){for(var c=Math.abs(d3.geom.polygon(a[0].map(i)).area()),f=0,j=a.length;++f<j;)c-=Math.abs(d3.geom.polygon(a[f].map(i)).area());return c}function e(a){for(var c=d3.geom.polygon(a[0].map(i)),f=c.centroid(1),j=f[0],m=f[1],n=Math.abs(c.area()),o=0,t=a.length;++o<t;){c=d3.geom.polygon(a[o].map(i));f=c.centroid(1);j-=f[0];m-=f[1];n-=Math.abs(c.area())}return[j,
m,6*n]}var k=4.5,h=v(k),i=d3.geo.albersUsa(),l={FeatureCollection:function(a){var c=[];a=a.features;for(var f=-1,j=a.length;++f<j;)c.push(q(l,a[f].geometry));return c.join("")},Feature:function(a){return q(l,a.geometry)},Point:function(a){return"M"+d(a.coordinates)+h},MultiPoint:function(a){var c=[];a=a.coordinates;for(var f=-1,j=a.length;++f<j;)c.push("M",d(a[f]),h);return c.join("")},LineString:function(a){var c=["M"];a=a.coordinates;for(var f=-1,j=a.length;++f<j;)c.push(d(a[f]),"L");c.pop();return c.join("")},
MultiLineString:function(a){var c=[];a=a.coordinates;for(var f=-1,j=a.length,m,n,o;++f<j;){m=a[f];n=-1;o=m.length;for(c.push("M");++n<o;)c.push(d(m[n]),"L");c.pop()}return c.join("")},Polygon:function(a){var c=[];a=a.coordinates;for(var f=-1,j=a.length,m,n,o;++f<j;){m=a[f];n=-1;o=m.length;for(c.push("M");++n<o;)c.push(d(m[n]),"L");c[c.length-1]="Z"}return c.join("")},MultiPolygon:function(a){var c=[];a=a.coordinates;for(var f=-1,j=a.length,m,n,o,t,x,A;++f<j;){m=a[f];n=-1;for(o=m.length;++n<o;){t=
m[n];x=-1;A=t.length-1;for(c.push("M");++x<A;)c.push(d(t[x]),"L");c[c.length-1]="Z"}}return c.join("")},GeometryCollection:function(a){var c=[];a=a.geometries;for(var f=-1,j=a.length;++f<j;)c.push(q(l,a[f]));return c.join("")}},p={FeatureCollection:function(a){var c=0;a=a.features;for(var f=-1,j=a.length;++f<j;)c+=q(p,a[f]);return c},Feature:function(a){return q(p,a.geometry)},Point:u,MultiPoint:u,LineString:u,MultiLineString:u,Polygon:function(a){return g(a.coordinates)},MultiPolygon:function(a){var c=
0;a=a.coordinates;for(var f=-1,j=a.length;++f<j;)c+=g(a[f]);return c},GeometryCollection:function(a){var c=0;a=a.geometries;for(var f=-1,j=a.length;++f<j;)c+=q(p,a[f]);return c}},s={Feature:function(a){return q(s,a.geometry)},Polygon:function(a){a=e(a.coordinates);return[a[0]/a[2],a[1]/a[2]]},MultiPolygon:function(a){a=a.coordinates;for(var c,f=0,j=0,m=0,n=-1,o=a.length;++n<o;){c=e(a[n]);f+=c[0];j+=c[1];m+=c[2]}return[f/m,j/m]}};b.projection=function(a){i=a;return b};b.area=function(a){return q(p,
a)};b.centroid=function(a){return q(s,a)};b.pointRadius=function(a){if(typeof a=="function")k=a;else{k=+a;h=v(k)}return b};return b};d3.geo.bounds=function(b){var d=Infinity,g=Infinity,e=-Infinity,k=-Infinity;w(b,function(h,i){if(h<d)d=h;if(h>e)e=h;if(i<g)g=i;if(i>k)k=i});return[[d,g],[e,k]]};var y={Feature:function(b,d){w(b.geometry,d)},FeatureCollection:function(b,d){for(var g=b.features,e=0,k=g.length;e<k;e++)w(g[e].geometry,d)},LineString:z,MultiLineString:function(b,d){for(var g=b.coordinates,
e=0,k=g.length;e<k;e++)for(var h=g[e],i=0,l=h.length;i<l;i++)d.apply(null,h[i])},MultiPoint:z,MultiPolygon:function(b,d){for(var g=b.coordinates,e=0,k=g.length;e<k;e++)for(var h=g[e][0],i=0,l=h.length;i<l;i++)d.apply(null,h[i])},Point:function(b,d){d.apply(null,b.coordinates)},Polygon:function(b,d){for(var g=b.coordinates[0],e=0,k=g.length;e<k;e++)d.apply(null,g[e])}}})();
