Explore
Courses
Batches
Sketches
Statistics
Code a Pookkalam
Jobs
Devsprint
People
Course Creation
Create a Course
Guidelines
Resources
Support
Blogs
My Profile
About Us
Login
Sketches
0
New Sketch
By
Neha Rajesh
Run
#colors_in_concentric_circle fill=[color(55, 6, 23),color(208, 0, 0),color(244, 140, 6),color(255, 186, 8),color(254, 250, 224)] def concirc(maxR,N): s=maxR/N r=maxR shapes=[] x=0 for i in range(N): x=x+r c=circle(r=r,fill=fill[i%5],stroke="none") shapes.append(c) r=r-s return combine(shapes) #outter_circle c=concirc(150,50) #concentric_circle_pattern x=concirc(50,5)|translate(-100) z=x|repeat(12,rotate(30)) y=x|repeat(10,rotate(60)) #2ndcircle mid=circle(r=100,fill=color(27, 67, 50),stroke="none") #petals e2=ellipse(w=35,h=15,fill=color(179, 36, 120),stroke=fill[4])|rotate(90)|translate (0,20)|scale(1.75) e4=e2|repeat(12,rotate(45)) #squares sq1=rectangle(x=30,w=75,h=75,fill=color(201, 24, 74),stroke=fill[4],stroke_width="3px")|rotate(45) sq=sq1|repeat(4,rotate(90)) sq2=sq|scale(0.5) #inner_polygon p1=point(0,50) p2=point(-20,40) p3=point(20,40) p4=point(0,-20) p=polygon([p1,p2,p4,p3],stroke=fill[4],stroke_width="3px",fill=fill[2])|translate(0,45) py=p|repeat(15,rotate(24)) pz=py|scale(0.7) #concentric_polygon ps=[] for i in range(4): pw=polygon([p1,p2,p4,p3],fill=fill[i],stroke="none")|translate(0,45) ps.append(pw) py1=ps[0]|repeat(15,rotate(24))|scale(0.9) py2=ps[1]|repeat(15,rotate(24))|scale(0.75) py3=ps[2]|repeat(15,rotate(24))|scale(0.55) py4=ps[3]|repeat(15,rotate(24))|scale(0.35) #3rd_mid_circle mid2=mid|scale(0.3) #midsquare sq3=rectangle(w=40,h=40,fill=fill[3],stroke=fill[0],stroke_width="2px") sq4=sq3|repeat(4,rotate(45)) #midcircle mid3=circle(r=21,fill=fill[4],stroke="none") mid4=x|scale(0.35)|translate(35) #show l=[c,z,y,mid,py,pz,py1,py2,py3,py4,e4,sq2,mid2,sq4,mid3,mid4] pookalam=combine(l) show(pookalam)
Comments
Want to discuss?
Post it here, our mentors will help you out.
Login