fractalkitty looking for math? fractalkitty.com

Mathober 2026 ยท day 6, Connected Topology

Connected Topology

#trig#interactive#animation#topology#wave#symmetry#packing#mathober


let t1=0

function setup() {
	theSizeThatFits = min(windowWidth, windowHeight)*0.9
	theCanvasThatIsFilled=createCanvas(theSizeThatFits, theSizeThatFits);
	background(20,70,80);
	strokeWeight(0.1);
	describe("a frame made of very tightly packed waves stretches and dances with strands toward the center with 4-fold symmetry. ")
	stroke(200,240,255)
	noFill()
	
}
function draw() {
	t1+=0.001
background(20,70,80,40);
	
	for(let j = PI;j<3*PI;j+=PI/5){
		stroke(180+j*5,220+j*5,230+j*5)
		beginShape()
			for(let t = 0.001;t<2*PI;t+=t/100){
				y = width/4*t+10;
				x =width/2+width/2*Math.sin(1/t+t1-j)
				vertex(x,y)
			}
		endShape()
		beginShape()
			for(let t = 0.001;t<2*PI;t+=t/100){
				y = width/4*t+10;
				x =width/2+width/2*Math.sin(1/t+t1-j)
				vertex(x,width-y)
			}
		endShape()
		beginShape()
			for(let t = 0.001;t<2*PI;t+=t/100){
				y = width/4*t+10;
				x =width/2+width/2*Math.sin(1/t+t1-j)
				vertex(y,x)
			}
		endShape()
		beginShape()
			for(let t = 0.001;t<2*PI;t+=t/100){
				y = width/4*t+10;
				x =width/2+width/2*Math.sin(1/t+t1-j)
				vertex(width-y,x)
			}
		endShape()
	}
	
	
}
function keyPressed(){
	if(keyCode===83){
		save(theCanvasThatIsFilled,"connected","png")
	}
}