How to draw a Sierpiński carpet with a geometrical drawing board

Source: Internet
Author: User

Analysis: Take the square 9 equal, get 9 small squares, give away the central small square, keep around 8 small squares. Then 9 equal parts for each small square, and likewise the central square. According to this rule constantly subdivided and shed, until infinity. The limit graph area of Sierpiński carpet tends to zero, the number of small square and its side line is more and more infinite, it is a line set, and the graph has strict self-similarity.

The specific drawing steps are as follows:

1. Open the geometry of the artboard software, on the plane arbitrarily draw line AB, to segment AB for the edge of the long structure square ABCD.

Construction of square ABCD with segment AB as side length

2. With point A as the Zoom center, the point B, D is scaled to 1/3 to get E, F, and D to zoom Center, the point A, c scaling to 1/3 to get G, H. Get the same point I, J, K, L. Connect the points and divide the squares into nine halves.

Square ABCD nine equal parts by scaling

3. Click on "Data-new parameter" New parameter n, the value is changed to 2. Click a, b two points in turn (note: These two points are the two endpoints of the segment you first drew) and parameter n, hold down the SHIFT key and click "Transform-depth iteration" To open the iteration dialog, select G, p Two, click "Structure"-"Add a new map", select P, o two, and continue adding new mappings. Select O, J; F, M; N, K; A, E; E, L; L, B. (Note: The middle of the M, n two points do not point) click "Iteration", complete the iteration production.

Perform depth iterations on points of squares

4. Fill in the middle square mnop, measure the area of the MNOP, select the measurement result and fill the square, click "Show"--"color"--"Parameters", click "OK" in the pop-up dialog box.

Fill square Mnop and set color parameters

5. Finally, select all points and press Ctrl+h to hide unnecessary points.

Hide a little finished Sierpiński carpet making

Warm tip: Change the size of the square ABCD, the color of the square mnop changes with its area. The difference of Sierpiński carpet is observed by changing the value of parameter N.

Change parameter n to observe the difference of Sierpiński carpet

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.