ফাইলোট্যাক্সিস প্যাটার্ন কি?
যখন আমরা ফিরে যাই, আমাদের উদ্ভিদবিদ্যার ক্লাসে এবং উদ্ভিদ জগতে, ফাইলোট্যাক্সিস মানে উদ্ভিদের কান্ডে ফুল, পাতা বা বীজের বিন্যাস, যা ফিবোনাচি সর্পিল পাওয়া যায়। ফিবোনাচি সিকোয়েন্সের উপর ভিত্তি করে, ফিবোনাচি সর্পিল হল সংখ্যার একটি সেট যা প্যাসকেলের ত্রিভুজের অনুরূপ একটি প্যাটার্ন অনুসরণ করে। ফিবোনাচি সিকোয়েন্স সংখ্যাগুলো এমন কিছু - 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, ইত্যাদি। তাই ফিবোনাচি ক্রম সংখ্যা হল তার আগের সংখ্যার যোগফল।
ফিবোনাচি সর্পিল
আমরা সাধারণত আমাদের চারপাশের বস্তুগুলি বোঝার জন্য প্রতিসাম্য এবং নিদর্শনগুলি সন্ধান করি। এটি উপলব্ধি না করেই আমাদের চোখ ফিবোনাচি সিকোয়েন্স বা সূর্যমুখী মাথার ক্ষেত্রে, একটি ফিবোনাচি সর্পিল দেখতে পাচ্ছে।
সমাধান


সূর্যমুখী সর্পিল
উদাহরণ কোড
import math
import turtle
def PhyllotacticPattern( t, petalstart, angle = 137.508, size = 2, cspread = 4 ):
"""print a pattern of circles using spiral phyllotactic data"""
# initialize position
turtle.pen(outline=1,pencolor="black",fillcolor="orange")
# turtle.color("orange")
phi = angle * ( math.pi / 180.0 )
xcenter = 0.0
ycenter = 0.0
# for loops iterate in this case from the first value until < 4, so
for n in range (0,t):
r = cspread * math.sqrt(n)
theta = n * phi
x = r * math.cos(theta) + xcenter
y = r * math.sin(theta) + ycenter
# move the turtle to that position and draw
turtle.up()
turtle.setpos(x,y)
turtle.down()
# orient the turtle correctly
turtle.setheading(n * angle)
if n > petalstart-1:
#turtle.color("yellow")
drawPetal(x,y)
else: turtle.stamp()
def drawPetal( x, y ):
turtle.up()
turtle.setpos(x,y)
turtle.down()
turtle.begin_fill()
#turtle.fill(True)
turtle.pen(outline=1,pencolor="black",fillcolor="yellow")
turtle.right(25)
turtle.forward(100)
turtle.left(45)
turtle.forward(100)
turtle.left(140)
turtle.forward(100)
turtle.left(45)
turtle.forward(100)
turtle.up()
turtle.end_fill() # this is needed to complete the last petal
turtle.shape("turtle")
turtle.speed(0) # make the turtle go as fast as possible
PhyllotacticPattern( 200, 160, 137.508, 4, 10 )
turtle.exitonclick() # lets you x out of the window when outside of idle সমাধান

আপনার উপরের প্রোগ্রামে একটি ছোট পরিবর্তনের সাথে, আপনি কিছু স্থানচ্যুত হতে পারেন যেমন (কাস্টম রঙ দিন এবং কিছু মান পরিবর্তন করুন):
