Pookkalam by Sidharth.R

Code

col=["#F0E89E","#F3BF44","#F08F20","#E85C4C","#A83022"]

for i in range(5):# outer boundary gradient
    shape = rectangle(w=215, h=215,fill=col[i],stroke="none") | repeat(9, rotate(10))
    s=shape
    for j in range(i):
        s=s|scale(0.92)|rotate(15)
    show(s)
    
rectcorrection=rectangle(w=154.0245,h=154.0245,fill="#A83022",stroke="none")|repeat(9,rotate(10))
show(rectcorrection)

b1=color(119,16,236)
b2=color(155,77,243)
c5=color(210,199,99)

ci=circle(x=0,y=50,r=50,fill=c5,stroke="none")
ci2=circle(x=0,y=50,r=125/3,fill=b2,stroke="none")
ci3=circle(x=0,y=50,r=100/3,fill=b1,stroke="none")
pat=ci+ci2+ci3
fin=pat|repeat(8,rotate(360/8))
# show(fin)
fin2=pat|repeat(4,rotate(90))
sho=pat+(pat|rotate(180))+(pat|rotate(90))+(pat|rotate(270))
show(sho,sho|rotate(45))

# greens
g1=color(130,182,119)

# ellipses
e1=ellipse(x=0,y=30,w=30,h=80,fill="#F0E89E",stroke="none")
ye1=ellipse(x=5,y=15,w=18,h=105,fill=g1,stroke="none")
ye2=ellipse(x=-5,y=15,w=18,h=105,fill=g1,stroke="none")
e2=ellipse(x=10,y=15,w=15,h=90,fill="green",stroke="none")
e3=ellipse(x=-10,y=15,w=15,h=90,fill="green",stroke="none")
e4=ellipse(x=0,y=15,w=15,h=90,fill="green",stroke="none")
#show(e1,e2,e3,e4)
efin=e1+ye1+ye2+e2+e3+e4
efin2=efin|repeat(8,rotate(360/8))
show(efin2)

def sector(n,colour):## function to create a sector
    p1=point(0,0)
    p2=point(-50/n,0)
    p3=point(-50/n,1)
    
    shape=polygon([p1,p2,p3],fill=colour,stroke="none")
    sec=shape|repeat(90,rotate(1))
    return sec
# cutsom colours
c1=color(r=78,g=10,b=10)
c2=color(203,21,21)  
c3=color(243,198,51)
c4=color(243,228,92)
c5=color(240,232,158)
# making 1st pair of sectors
s1=sector(1,c1)
s2=sector(1.2,c2)
s3=sector(1.4,"orange")
s4=sector(1.7,c3)
s5=sector(2,c4)
s6=sector(2.5,c5)
ts=s1+s2+s3+s4+s5+s6
tst=ts|rotate(180)
show(ts,tst)

## making 2nd pair of sectors
s11=sector(1,c5)
s22=sector(1.2,c4)
s33=sector(1.4,c3)
s44=sector(1.7,"orange")
s55=sector(2,c2)
s66=sector(2.5,c1)
p=s11+s22+s33+s44+s55+s66
ts2=p|rotate(90)
tst2=ts2|rotate(180)
show(ts2,tst2)

b1=color(119,16,236)
b2=color(155,77,243)
show(circle(r=10,fill=b1,stroke="none"),circle(r=6,fill=b2,stroke="none"))