using math functions in python turtle graphics
import turtle as t
import math as m
import colorsys as c
t.bgcolor('black')
t.tracer(190)
t.width(2)
f=0
d=0
t.setup(1537,865)
for i in range(200000):
f+=0.0001
d+=0.001
color=c.hsv_to_rgb(d,1,1)
t.pencolor(color)
t.fillcolor('black')
t.begin_fill()
y=m.sin(20*f)+m.sin(21*f)
r=m.cos(60*f)+m.cos(9.01*f)
t.setpos(300*y,300*r)
t.circle(30,i/90)
t.end_fill()
t.done()
Comments
Post a Comment