sketchucation logo sketchucation
    • Login
    πŸ€‘ SketchPlus 1.3 | 44 Tools for $15 until June 20th Buy Now

    [Plugin] Menger Sponge 1.0

    Scheduled Pinned Locked Moved Plugins
    8 Posts 6 Posters 7.9k Views 6 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R Offline
      Regular Polygon
      last edited by Regular Polygon

      This plugin is strictly just for fun. The Menger Sponge is a 3D fractal in the Mathematics world. In the computer graphics world you can only draw the first few levels before it becomes too complex to render. However, it still has an interesting self-similar shape, which makes it possible to build using a plugin.

      It is constructed iteratively. You start with a cube. Scale the cube down to one third the size, and make 27 copies arranged like the cells in a Rubik’s Cube. Then remove the cube at the middle of every face, and remove the cube in the center, leaving 20 cubes. Merge them together so there are no coplanar edges. This gives you the first level.

      level 1.png

      The second iteration is the same process, only instead of a cube, you start with the first level sponge, scale it down, and translate 20 copies as before.

      level 2.png

      The third level is constructed from 20 copies of the second level sponge, and so on. Below is an image of the fourth level, which is probably about as far as you want to go. It has 200k faces, and takes about a minute to generate all the geometry.

      level 4.png

      You can color the outside by clicking on the component with the paint bucket. The inside faces have a different color for each level. You are not stuck with my color choices. They are grouped by material. So, just open the component, and apply the paint bucket to any face. That will paint all the faces that are the same color.

      There is more documentation, and a link to download this plugin, here: Menger Sponge 1.0.

      Thanks.

      My SketchUp Plugins

      1 Reply Last reply Reply Quote 0
      • Rich O BrienR Offline
        Rich O Brien Moderator
        last edited by

        Thank you for this, useful and interesting, plugin

        Download the free D'oh Book for SketchUp πŸ“–

        1 Reply Last reply Reply Quote 0
        • Didier BurD Offline
          Didier Bur
          last edited by

          Welcome Sierpinski and Menger to SCF !
          But I don't agree with Regular Polygon when he says on the plugin's page "It is constructed iteratively". I'd say it is constructed recursively, that's the opposite and the basis of the fractal algorithm. Or did I miss something ?

          DB

          1 Reply Last reply Reply Quote 0
          • R Offline
            Regular Polygon
            last edited by

            Hi Didier,

            You are correct, the implementation is recursive. What I mean by iterative is that the construction is a repetitive process, where each level is built up from subcomponents of the previous level in the same way.

            Nice to see someone is checking the source code. πŸ‘

            My SketchUp Plugins

            1 Reply Last reply Reply Quote 0
            • R Offline
              remus
              last edited by

              Cool plugin. I do enjoy a bit of maths geekery πŸ˜„

              http://remusrendering.wordpress.com/

              1 Reply Last reply Reply Quote 0
              • D Offline
                d12dozr
                last edited by

                Very cool plugin, RP...so many new plugins, so little time... πŸ’š

                3D Printing with SketchUp Book
                http://goo.gl/f7ooYh

                1 Reply Last reply Reply Quote 0
                • S Offline
                  Starling75
                  last edited by

                  Menger in the field


                  menger in the field.jpg

                  http://www.starlingarch.cz

                  1 Reply Last reply Reply Quote 0
                  • R Offline
                    Regular Polygon
                    last edited by

                    @starling75 said:

                    Menger in the field

                    Abstract art at its best. πŸ‘ πŸ˜†

                    My SketchUp Plugins

                    1 Reply Last reply Reply Quote 0
                    • 1 / 1
                    • First post
                      Last post
                    Buy SketchPlus
                    Buy SUbD
                    Buy WrapR
                    Buy eBook
                    Buy Modelur
                    Buy Vertex Tools
                    Buy SketchCuisine
                    Buy FormFonts

                    Advertisement