Pookkalam by JUMANA YASIR

Code

def cir(rad,col):
    c=circle(r=rad,fill=col,stroke="none")
    return c

c1=cir(rad=150,col="red")
c2=cir(rad=130,col="red")
c3=cir(rad=105,col='#ff8c04')
c4=cir(rad=80,col="green")
show(c1,c2,c3,c4)

def rec(sid,col):
    r=rectangle(w=sid,h=sid,fill=col,stroke="none")
    return r
r1=rec(sid=20,col="green")|translate(x=140)|repeat(18,rotate(20))
r2=rec(sid=25.38,col="orange")|translate(x=117)|rotate(10)|repeat(18,rotate(20))
r3=rec(sid=25.38,col="yellow")|translate(x=91)|rotate(10)|repeat(18,rotate(20))
show(r1,r2,r3)

colo = color(r=178, g=34, b=34, a=0.5)
shape=rectangle(w=130,h=130,fill=colo)| repeat(20, rotate(10))
show(shape)

c6=cir(rad=30,col='#228b22')|translate(x=40)|repeat(4,rotate(90))
c7=cir(rad=30,col="red")|translate(x=30)|repeat(4,rotate(90))
c8=cir(rad=30,col="yellow")|translate(x=40)|rotate(45)|repeat(4,rotate(90))
c9=cir(rad=30,col="orange")|translate(x=30)|rotate(45)|repeat(4,rotate(90))
c10=cir(rad=30,col="yellow")|translate(x=20)|rotate(45)|repeat(4,rotate(90))
c11=cir(rad=30,col='#800000')|translate(x=25)|repeat(4,rotate(90))
c12=cir(rad=30,col="white")|translate(x=15)|repeat(4,rotate(90))
show(c6,c7,c8,c9,c10,c11,c12)

f1 = circle(x=50,y=0,r=15,fill="red")|repeat(20,rotate(18))
f2= circle(x=28,y=0,r=10,fill="blue")|repeat(20,rotate(18))
f3 = circle(x=80,y=0,r=20,fill="green")|repeat(20,rotate(18))
f= combine([f1,f2,f3])|scale(.35)
show(f)