fractalkitty looking for math? fractalkitty.com

all

kissing kiss

#trig#animation#math#geometry#mathober

daypromptborder

let day = 1
let a = 1
let prompt = ''
function setup(){
  createCanvas(500,500)
  background(200,223,255)
  noStroke()
}
function draw(){
  translate(width/2,height/2)
  fill(0)
  t = frameCount/500
  a = 100 +20*cos(t)
  background(220,243,255,200)
  if(day ===1){
    prompt = 'kiss'
    for (u=0;u<TWO_PI;u+=PI/10){
      for(v=0;v<PI;v+=PI/100){
        x = a*v*v*cos(u+t)*sqrt(abs(1 - v)/2);
        y = a*v*v*sqrt(abs(1-v)/2)*sin(u+t);
        z = a*v;
        push()
        translate(x,z)
        circle(0,0,2)
        pop()
        push()
        translate(x,-z)
        circle(0,0,2)
        pop()
      }
    }
  
  }
  border()
}

function border(){
  strokeWeight(50)
  noFill()
  stroke(180,203,225)
  rect(-width/2,-height/2,width,height)
  strokeWeight(2)
  stroke(0)
  noStroke()
  fill(0)
  
}