The Sierpinski triangle can be implemented in MAILAB by plotting points iteratively according to one of the
Question:
Rule 1: xn+1 = 0.5xn, yn+1 = 0.5yn.
Rule2: xn+1 = 0.5xn + 0.25, yn+1 = 0.5yn + (√3)/4
Rule 3: xn+1 = 0.5xn + 1 + 0.5, yn+1 = 0.5yn.
Write a program in a script file that calculates the x and y vectors and then plots y versus x as individual points (use plot (x, y, '^')). Start with x1 = o and y1 = o. Run the program four times with 10, 100, 1,000, and 10,000 iterations.
Fantastic news! We've Found the answer you've been seeking!
Step by Step Answer:
Related Book For
Question Posted: