memoscan
← all memos

Memo 0x7d340a96…56c097 on Ethereum

S=Uint32Array.from([0,1,s=t=2,3].map(t=>parseInt(tokenData.hash.substr(8*t+2,8),16)));let ggPrev=!(R=e=>(t=S[3],S[3]=S[2],S[2]=S[1],S[1]=s=S[0],t^=t<<11,S[0]^=t^t>>>8^s>>>19,S[0]/2**32)),gy2=0,clrC,width,height;const hashPairs=[];for(let t=0;t<32;t++)hashPairs.push(tokenData.hash.slice(2+2*t,4+2*t));const decPairs=hashPairs.map(t=>parseInt(t,16));let seed=parseInt(tokenData.hash.slice(0,16),16),hWob,vWob,wobRes;function setup(){noiseSeed(seed),randomSeed(seed),clrC=new ClrC,wobRes=pow(2,floor(rnd(5,9))),noCanvas();width=900,height=1200;const s=new M;s.setup();var i="http://www.w3.org/2000/svg";let e=document.createElementNS(i,"svg");e.setAttribute("class","plot"),e.setAttribute("width","9in"),e.setAttribute("height","12in"),e.setAttribute("viewBox","0 0 "+width+" "+height),e.setAttribute("style","background-color:white;");for(let t=0;t<Object.keys(s.ps).length;t++){var h=Object.keys(s.ps)[t];const a=document.createElementNS(i,"g");a.setAttribute("id",`${clrC.nms[h]}`);var r=s.ps[h];for(let e=0;e<r.length;e++){let s="";s="M "+r[e][0].x+" "+r[e][0].y;for(let t=1;t<r[e].length;t++)s+=" L "+r[e][t].x+" "+r[e][t].y,t===r[e].length-1&&r[e][t]&&(s+=" L "+r[e][0].x+" "+r[e][0].y);if(s){const o=document.createElementNS(i,"path");o.setAttribute("style",`fill:none;stroke-width:1.5;stroke:${clrC.vals[h]};`),o.setAttribute("d",s),a.appendChild(o)}}e.appendChild(a)}if(s.aps.length){const c=document.createElementNS(i,"g");c.setAttribute("id","Accent Lines (Bold Black)");for(let t=0;t<s.aps.length;t++){var n=s.aps[t];if(n.length){let s="M "+n[0].x+" "+n[0].y;if(1===n.length)s+=" L "+n[0].x+" "+n[0].y;else for(let t=1;t<n.length;t++)s+=" L "+n[t].x+" "+n[t].y;const l=document.createElementNS(i,"path");l.setAttribute("style","fill:none;stroke-width:2.25;stroke:black;"),l.setAttribute("d",s),c.appendChild(l)}}e.appendChild(c)}document.body.appendChild(e);let t=document.createElement("style");t.appendChild(document.createTextNode(".plot{width:100vw;height:100vh;}")),document.head.appendChild(t)}function rnd(t,s){var e,i=R();return void 0===t?i:void 0===s?t instanceof Array?t[Math.floor(i*t.length)]:i*t:(s<t&&(e=t,t=s,s=e),i*(s-t)+t)}function rndFromArray(t){return t[floor(rnd(0,t.length))]}function shuffleArray(t,s){var e=ArrayBuffer&&ArrayBuffer.isView&&ArrayBuffer.isView(t);let i,h,r=(t=s||e?t:t.slice()).length;for(;1<r;)i=rnd(0,1)*r|0,h=t[--r],t[r]=t[i],t[i]=h;return t}const rAttH=function(t,s){var e=Object.keys(t);return t[e[(e.length-1e-9)*dptp(decPairs[s])<<0]]},rAtt=function(t){var s=Object.keys(t);return t[s[Math.floor(s.length*R())]]};function dptp(t){return map(t,0,255,0,1)}const wChsr=function(s,...t){const e=[],i=[];Object.keys(s).forEach(t=>{i.push(s[t].weight),e.push(s[t].value)});let h=rnd();if(0<decPairs.length&&void 0!==t[0]){let s="";t.forEach(t=>{s+=hashPairs[t]}),h=map(parseInt(s,16),0,Math.pow(16,2*t.length),0,1)}for(let t=0;t<e.length;t++)if(h<=i[t])return e[t]};class M{constructor(){this.field=[];var t=[5,6,7,8,9,10,11,12,13,14,15,16],s=floor(map(dptp(decPairs[8]),0,1,0,t.length-1e-8));this.gs=4*t[s];t=height/1200,s=height/800;hWob=random(t,s),vWob=random(t,s),this.rez=height/this.gs,this.cols=1+width/this.rez,this.inc=rnd([.1,.08,.05]),this.rows=1+height/this.rez;this.lAmt=rAttH({small:.25,medium:.375,large:.5},6),this.ps={},this.aps=[],this.cClr;const o={a:()=>()=>R()*TWO_PI,b:()=>{const t=R()*TWO_PI;return()=>t}},c={a:()=>()=>rnd(5*PI/12,11*PI/12),b:()=>()=>rnd(PI/12,PI/4),c:()=>()=>PI/3,d:()=>{const t=rnd(PI/12,PI/4);return()=>t},e:()=>{const t=rnd(5*PI/12,11*PI/12);return()=>t}},l={a:{weight:.25,value:(t,s)=>({disX:()=>rndGaussian(1,.175)*t/2,disY:()=>rnd(s)})},b:{weight:.5,value:(t,s)=>({disX:()=>rnd(t),disY:()=>rndGaussian(1,.175)*s/2})},c:{weight:.6,value:(t,s)=>({disX:()=>rndGaussian(1,.21)*t/2,disY:()=>rndGaussian(1,.21)*s/2})},d:{weight:1,value:(t,s)=>({disX:()=>rnd(t),disY:()=>rnd(s)})}},d={a:()=>{const t=rnd(width/15,width/3);return()=>t},b:()=>()=>rnd(width/100,width/2)};s={a:s=>{const t=[...clrC.clrs];shuffleArray(t,!0);const e=t.slice(0,floor(rnd(2,max(2,floor(s/2+1))))),i=[];for(let t=0;t<s;t++)i.push(e[0]),e.push(e.shift());return i},b:s=>{const e=[clrC.rand()];for(let t=1;t<s;t++)e.push(clrC.new(e[t-1]));return e}};this.mLvls=floor(map(R(),0,1,4,20)),this.fTs={circles:{weight:.2,value:()=>{const{disX:s,disY:e}=wChsr(l,5)(width,height),i=rAtt(d)(),n=[];for(let t=0;t<100;t++)n.push(new LevelCircle(s(),e(),i(),Math.ceil(R()*this.mLvls)));const a=rAtt(easeFs);return({i:s,j:e})=>{for(let t=0;t<n.length;t++){var i=n[t],h=dist(i.x,i.y,s*this.rez,e*this.rez),r=map(h,0,i.radius,0,1);h<i.radius?this.field[s][e]=max(min(map(a(r),0,1,i.levels,1),i.levels),this.field[s][e]):this.field[s][e]=this.field[s][e]}}}},centered:{weight:.3,value:()=>{const n=rAtt(easeFs);return({xOff:t,yOff:s,zOff:e,i,j:h})=>{var r=constrain(map(dist(i*this.rez,h*this.rez,width/2,height/2),0,width/2,0,1),0,1);this.field[i][h]=map(noise(t,s,e)*n(r),0,1,0,this.mLvls)}}},classic:{weight:.4,value:()=>({xOff:t,yOff:s,zOff:e,i,j:h})=>{this.field[i][h]=map(noise(t,s,e),0,1,0,this.mLvls)}},points:{weight:.5,value:()=>({xOff:t,yOff:s,zOff:e,i,j:h})=>{this.field[i][h]=map(Math.pow(noise(t,s,e),2),0,1,0,this.mLvls)}},island:{weight:.6,value:()=>{let n=rAtt(easeFs);return({xOff:t,yOff:s,zOff:e,i,j:h})=>{var r=constrain(map(dist(i*this.rez,h*this.rez,width/2,height/2),0,width/2,1,0),0,1),e=map(noise(t,s,e),0,1,0,this.mLvls);this.field[i][h]=e*n(r)}}},triangles:{weight:.8,value:()=>{const s=rAtt(o)(),e=rAtt(c)(),{disX:i,disY:h}=wChsr(l,5)(width,height),r=rAtt(d)(),n=[];for(let t=0;t<100;t++)n.push(new LevelTriangle(i(),h(),r(),e(),Math.ceil(R()*this.mLvls),s()));const a=rAtt(easeFs);return({i:s,j:e})=>{for(let t=0;t<n.length;t++){const h=n[t];var i;h.containsPoint(s*this.rez,e*this.rez)?(i=h.distanceToTriangle(s*this.rez,e*this.rez),i=map(i,0,h.distanceToEdge,0,1),this.field[s][e]=max(min(map(a(i),0,1,h.levels,1),h.levels),this.field[s][e])):this.field[s][e]=this.field[s][e]}}}},squares:{weight:1,value:()=>{const s=rAtt(o)(),{disX:e,disY:i}=wChsr(l,5)(width,height),h=rAtt(d)(),r=[];for(let t=0;t<100;t++)r.push(new LevelSquare(e(),i(),h(),Math.ceil(R()*this.mLvls),s()));const n=rAtt(easeFs);return({i:s,j:e})=>{for(let t=0;t<r.length;t++){const h=r[t];var i;h.containsPoint(s*this.rez,e*this.rez)?(i=h.distanceToSquare(s*this.rez,e*this.rez),i=map(i,0,h.distanceToEdge,0,1),this.field[s][e]=max(min(map(n(i),0,1,h.levels,1),h.levels),this.field[s][e])):this.field[s][e]=this.field[s][e]}}}}},this.cSchm=rAttH(s,4)(this.mLvls),this.fType=wChsr(this.fTs,3)}setup(){for(let t=0;t<this.cols;t++){const V=[];for(let t=0;t<this.rows;t++)V.push(0);this.field.push(V)}const i=this.fType();let h=0;for(let e=0;e<this.cols;e++){let s=0;for(let t=0;t<this.rows;t++)i({xOff:h,yOff:s,zOff:0,i:e,j:t}),s+=this.inc;h+=this.inc}const r=[];push();for(let i=0;i<this.cols-1;i++)for(let e=0;e<this.rows-1;e++){var n=i*this.rez,a=e*this.rez,o=createVector(n,a),c=createVector(n+this.rez/2,a+this.rez/2),l=createVector(n+this.rez,a),d=createVector(n,a+this.rez),p=createVector(n+this.rez,a+this.rez),u=createVector(n+.5*this.rez,a),g=createVector(n+this.rez,a+.5*this.rez),f=createVector(n+.5*this.rez,a+this.rez),w=createVector(n,a+.5*this.rez),y=this.field[i][e],v=this.field[i+1][e],m=this.field[i+1][e+1],b=this.field[i][e+1],q=floor(Math.min(y,v,m,b)),x=floor(y)-q,S=floor(v)-q,T=floor(m)-q,P=floor(b)-q;let t=new Set;t.add(x),t.add(S),t.add(T),t.add(P);const M=[{i:0,p:x},{i:1,p:S},{i:2,p:T},{i:3,p:P}];M.sort((t,s)=>t.p-s.p);let s=0;const O=[];O[M[0].i]=M[0];for(let t=1;t<M.length;t++)M[t].p!=M[t-1].p&&s++,O[M[t].i]={i:M[t].i,p:s};var z=this.cSchm[floor(y)%this.cSchm.length],A=this.cSchm[floor(v)%this.cSchm.length],L=this.cSchm[floor(m)%this.cSchm.length],n=this.cSchm[floor(b)%this.cSchm.length],a=O[0].p,q=O[1].p,x=O[2].p,S=O[3].p;if(t.size<=2){var T=this.getState(a,q,x,S),P=floor(Math.max(y,v,m,b)),b=floor(Math.min(y,v,m,b)),k=this.cSchm[P%this.cSchm.length],C=this.cSchm[b%this.cSchm.length];switch(T){case 0:this.sgc(C),this.qwe(l,p,d,o);break;case 1:this.sgc(C),this.qwe(w,f,p,l,o),this.sgc(k),this.qwe(f,w,d),r.push([f,w]);break;case 2:this.sgc(C),this.qwe(g,f,d,o,l),this.sgc(k),this.qwe(g,f,p),r.push([g,f]),r.push([d,l]);break;case 3:this.sgc(C),this.qwe(g,w,o,l),this.sgc(k),this.qwe(g,w,d,p),r.push([g,w]),r.push([o,l]);break;case 4:this.sgc(C),this.qwe(u,g,p,d,o),this.sgc(k),this.qwe(u,g,l),r.push([u,g]);break;case 5:this.sgc(C),this.qwe(u,w,o),this.qwe(f,g,p),this.sgc(k),this.qwe(u,w,d,f,g,l),r.push([u,w]),r.push([g,f]);break;case 6:this.sgc(C),this.qwe(u,f,d,o),this.sgc(k),this.qwe(u,f,p,l),r.push([u,f]),r.push([d,o]);break;case 7:this.sgc(C),this.qwe(u,w,o),this.sgc(k),this.qwe(u,w,d,p,l),r.push([u,w]);break;case 8:this.sgc(C),this.qwe(u,w,d,p,l),this.sgc(k),this.qwe(u,w,o),r.push([u,w]);break;case 9:this.sgc(C),this.qwe(u,f,p,l),this.sgc(k),this.qwe(u,f,d,o),r.push([u,f]);break;case 10:this.sgc(C),this.qwe(u,g,l),this.qwe(f,w,d),this.sgc(k),this.qwe(u,g,p,f,w,o),r.push([u,g]),r.push([f,w]);break;case 11:this.sgc(C),this.qwe(u,g,l),this.sgc(k),this.qwe(u,g,p,d,o),r.push([u,g]);break;case 12:this.sgc(C),this.qwe(g,w,d,p),this.sgc(k),this.qwe(g,w,o,l),r.push([g,w]);break;case 13:this.sgc(C),this.qwe(g,f,p),this.sgc(k),this.qwe(g,f,d,o,l),r.push([g,f]);break;case 14:this.sgc(C),this.qwe(f,w,d),this.sgc(k),this.qwe(f,w,o,l,p),r.push([f,w]);break;case 15:this.sgc(k),this.qwe(o,l,p,d)}}else a!==x?q!==S?a!==q?q!==x?x!==S?S!==a?(this.sgc(z),this.qwe(u,c,w,o,u),this.sgc(A),this.qwe(u,c,g,l,u),this.sgc(n),this.qwe(f,c,w,d,f),this.sgc(L),this.qwe(f,c,g,p,f),r.push([u,f]),r.push([w,g])):(this.sgc(z),this.qwe(u,f,d,o),this.sgc(A),this.qwe(u,c,g,l),this.sgc(L),this.qwe(f,c,g,p),r.push([u,f]),r.push([g,c])):(this.sgc(n),this.qwe(w,g,p,d),this.sgc(z),this.qwe(u,c,w,o),this.sgc(A),this.qwe(u,c,g,l),r.push([w,g]),r.push([u,c])):(this.sgc(A),this.qwe(u,f,p,l),this.sgc(z),this.qwe(u,c,w,o),this.sgc(n),this.qwe(f,c,w,d),r.push([u,f]),r.push([c,w])):(this.sgc(z),this.qwe(w,g,l,o),this.sgc(L),this.qwe(g,c,f,p),this.sgc(n),this.qwe(w,c,f,d),r.push([w,g]),r.push([c,f])):(this.sgc(L),this.qwe(g,f,p),this.sgc(z),this.qwe(u,w,o),this.sgc(A),this.qwe(u,w,d,f,g,l),r.push([u,w]),r.push([g,f])):(this.sgc(A),this.qwe(u,g,l),this.sgc(n),this.qwe(w,f,d),this.sgc(z),this.qwe(u,g,p,f,w,o),r.push([u,g]),r.push([f,w]))}pop(),this.aSegs=[],r.forEach(t=>this.aSegs.push(new Seg(t[0],t[1],0)));var t=[cos,sin,t=>sin(t)*sin(t),t=>1.2*sin(3*t)*cos(t),t=>sin(t)/(Math.atanh(t)||1)];const s=rnd(t),e=rnd(t);if(dptp(decPairs[11])<.75){const I=dptp(decPairs[10])<.75,E=this.sSegs(this.aSegs);E.forEach(t=>{t.forEach(t=>this.aps.push(...t.show(I,s,e)))})}}sgc(t){this.ps[t]||(this.ps[t]=[]),this.cClr=t}sSegs(s){const n={},a={},e=[],i=[],h=[];for(let t=0;t<s.length;t++){var r=s[t];r.aType===aTypes.h?n[r.start.y]?n[r.start.y].push(r):n[r.start.y]=[r]:r.aType===aTypes.v?a[r.start.x]?a[r.start.x].push(r):a[r.start.x]=[r]:(r.aType===aTypes.da?e:r.aType===aTypes.db?i:h).push(r)}const o=[];Object.keys(n).forEach(t=>{const s=n[t];s.sort((t,s)=>t.start.x-s.start.x);let e=s[0].start,i=s[0].end,h=s[0].clr;if(1===s.length)return o.push(new Line(e,i,h));for(let t=1;t<s.length;t++){var r=s[t];r.start.x!==i.x||r.clr!==h?(o.push(new Line(e,i,h)),e=r.start,i=r.end,h=r.clr,t===s.length-1&&o.push(new Line(e,i,h))):t===s.length-1?o.push(new Line(e,r.end,h)):i=r.end}});const c=[];Object.keys(a).forEach(t=>{const s=a[t];s.sort((t,s)=>t.start.y-s.start.y);let e=s[0].start,i=s[0].end,h=s[0].clr;if(1===s.length)return c.push(new Line(e,i,h));for(let t=1;t<s.length;t++){var r=s[t];r.start.y!==i.y||r.clr!==h?(c.push(new Line(e,i,h)),e=r.start,i=r.end,h=r.clr,t===s.length-1&&c.push(new Line(e,i,h))):t===s.length-1?c.push(new Line(e,r.end,h)):i=r.end}});var t=this.gDiag(e),l=this.gDiag(i);const d=[];return h.forEach(t=>{d.push(new Line(t.start,t.end,t.clr))}),[o,c,t,l,d]}gDiag(e){const i=[];for(let t=0;t<e.length;t++){var h=e[t];let s=!1;for(let t=0;t<i.length;t++){var r=i[t];h.clr===r.clr&&(h.start.x===r.end.x&&h.start.y===r.end.y?(i[t]=new Line(r.start,h.end,r.clr),s=!0):h.end.x===r.start.x&&h.end.y===r.start.y&&(i[t]=new Line(h.start,r.end,r.clr),s=!0))}s||i.push(new Line(h.start,h.end,h.clr))}return i}qwe(...s){let e=0,i=0;for(let t=0;t<s.length;t++)e+=s[t].x,i+=s[t].y;const h=[],r=createVector(e/s.length,i/s.length);s.forEach(t=>{h.push(p5.Vector.lerp(t,r,this.lAmt))}),this.ps[this.cClr].push(h)}getState(t,s,e,i){return t%2*8+s%2*4+e%2*2+i%2*1}}class Seg{constructor(t,s,e){t.x=round(t.x,8),t.y=round(t.y,8),s.x=round(s.x,8),s.y=round(s.y,8),this.clr=e,t.y===s.y?(this.aType=aTypes.h,t.x<s.x?(this.start=t,this.end=s):(this.start=s,this.end=t)):t.x===s.x?(this.aType=aTypes.v,t.y<s.y?(this.start=t,this.end=s):(this.start=s,this.end=t)):(t.y<s.y?(this.start=t,this.end=s):(this.start=s,this.end=t),1===(e=round((this.end.y-this.start.y)/(this.end.x-this.start.x),8))?this.aType=aTypes.da:-1===e?this.aType=aTypes.db:(this.aType=aTypes.o,this.start=t,this.end=s))}}class Line{constructor(t,s,e){this.start=t,this.end=s,this.clr=e,this.isHorizontal=t.y===s.y,this.isVertical=t.x===s.x}show(t=!1,i,h){var s=p5.Vector.dist(this.start,this.end);const r=[];let n=[];if(t){var a=map(s,0,height,2,400);for(let e=0;e<a;e++){let t,s;var o=map(e,0,a-1,this.start.x,this.end.x),c=map(e,0,a-1,this.start.y,this.end.y);this.isHorizontal?(t=o,s=this.start.y+map(i(wobRes*t/width),-1,1,-hWob,hWob)):this.isVertical?(s=c,t=this.start.x+map(h(wobRes*s/width),-1,1,-vWob,vWob)):(t=o+map(h(wobRes*c/width),-1,1,-vWob,vWob),s=c+map(i(wobRes*o/width),-1,1,-hWob,hWob)),0<=t&&t<=width&&0<=s&&s<=height?n.push(createVector(t,s)):(1<n.length&&r.push([...n]),n=[])}1<n.length&&r.push(n)}else r.push([this.start,this.end]);return r}}class LevelCircle{constructor(t,s,e,i,h){this.x=t,this.y=s,this.radius=e,this.levels=i}}class LevelTriangle{constructor(t,s,e,i,h,r=0){this.points=[],this.levels=h;var n=createVector(t,s),a=(PI-i)/2,o=2*e/3,h=sqrt(pow(e/3,2)+pow(e/tan(a),2)),e=asin(e/3/h);const c=createVector(0,-o);c.rotate(r),this.points.push(p5.Vector.add(n,c)),c.rotate(PI-(i/2+(a-e))),c.setMag(h),this.points.push(p5.Vector.add(n,c)),c.rotate(PI-2*e),this.points.push(p5.Vector.add(n,c)),this.distanceToEdge=this.distanceToTriangle(t,s)}distanceToTriangle(s,e){let i;for(let t=0;t<this.points.length;t++){var h=this.points[t],r=this.points[(t+1)%this.points.length],h=abs((r.x-h.x)*(h.y-e)-(h.x-s)*(r.y-h.y))/sqrt(pow(r.x-h.x,2)+pow(r.y-h.y,2));i=i?min(h,i):h}return i}containsPoint(t,s){return pointInPolygon(createVector(t,s),[this.points[0],this.points[1],this.points[2]])}}class LevelSquare{constructor(t,s,e,i,h=0){this.points=[],this.levels=i;i=createVector(t,s);const r=createVector(-e/2,-e/2);r.rotate(h),this.points.push(p5.Vector.add(i,r)),r.rotate(PI/2),this.points.push(p5.Vector.add(i,r)),r.rotate(PI/2),this.points.push(p5.Vector.add(i,r)),r.rotate(PI/2),this.points.push(p5.Vector.add(i,r)),this.distanceToEdge=this.distanceToSquare(t,s)}distanceToSquare(s,e){let i;for(let t=0;t<this.points.length;t++){var h=this.points[t],r=this.points[(t+1)%this.points.length],h=abs((r.x-h.x)*(h.y-e)-(h.x-s)*(r.y-h.y))/sqrt(pow(r.x-h.x,2)+pow(r.y-h.y,2));i=i?min(h,i):h}return i}containsPoint(t,s){return pointInPolygon(createVector(t,s),[this.points[0],this.points[1],this.points[2],this.points[3]])}}function pointInPolygon(t,e){var{x:i,y:h}=t;let r=!1;var n=e.length;for(let t=0,s=n-1;t<n;s=t++){var a=e[t].x,o=e[t].y,c=e[s].x,l=e[s].y;h<o!=h<l&&i<(c-a)*(h-o)/(l-o)+a&&(r=!r)}return r}const aTypes={h:0,v:1,da:2,db:3,o:4};class ClrC{nms=["Micron Rose","Micron Red","Micron Orange","Micron Green","Micron Blue","Micron Purple","Micron Brown","Micron Light Cool Gray","Micron Cool Gray","Micron Black"];vals=["#df4a82","#f1230a","#f47d3d","#47a858","#0972c4","#842eae","#a14725","#cac8c9","#979699","#000"];constructor(){const t=[0,1,2,3,4,5,6];dptp(decPairs[15])<.15?this.clrs=[7,8,9]:(shuffleArray(t,!0),this.clrs=t.slice(0,rnd([3,5])))}rand(){return rnd(this.clrs)}new(t){if(this.clrs.length<=1)return t;let s=this.rand();for(;s===t;)s=this.rand();return s}}const easeFs={a:t=>t,b:t=>t<.5?2*t*t:1-pow(-2*t+2,2)/2,c:t=>t*t,d:t=>1-(1-t)*(1-t),e:t=>1-easeFs.f(1-t),f:t=>{var s=7.5625,e=2.75;return t<1/e?s*t*t:t<2/e?s*(t-=1.5/e)*t+.75:t<2.5/e?s*(t-=2.25/e)*t+.9375:s*(t-=2.625/e)*t+.984375},g:t=>t<.5?(1-easeFs.f(1-2*t))/2:(1+easeFs.f(2*t-1))/2,h:t=>t<=.5?2*t:2*(.5-(t-.5))};function rndGaussian(t,s=1){let e,i,h,r;if(ggPrev)e=gy2,ggPrev=!1;else{for(;i=rnd(2)-1,h=rnd(2)-1,r=i*i+h*h,1<=r;);r=Math.sqrt(-2*Math.log(r)/r),e=i*r,gy2=h*r,ggPrev=!0}return e*s+(t||0)}