File:Menger sponge diagonal section.gif

Summary

Description
English: GIF animation of cross-sections of a level-4 Menger sponge perpendicular to a space diagonal. The cross-section through its centroid comprises regular hexagrams arranged in six-fold symmetry. The cross-sections are true-view and to scale.
Source Own work
Author Cmglee
Other versions
27 / 9  =  3
26 / 9
25 / 9
24 / 9  =  8 / 3
23 / 9
22 / 9
21 / 9  =  7 / 3
20 / 9
19 / 9
18 / 9  =  2
17 / 9
16 / 9
15 / 9  =  5 / 3
14 / 9
13 / 9
12 / 9  =  4 / 3
11 / 9
10 / 9
9 / 9  =  1
8 / 9
7 / 9
6 / 9  =  2 / 3
5 / 9
4 / 9
3 / 9  =  1 / 3
2 / 9
1 / 9
0 / 9  =  0
−1 / 9
−2 / 9
−3 / 9  =  −1 / 3
−4 / 9
−5 / 9
−6 / 9  =  −2 / 3
−7 / 9
−8 / 9
−9 / 9  =  −1
−10 / 9
−11 / 9
−12 / 9  =  −4 / 3
−13 / 9
−14 / 9
−15 / 9  =  −5 / 3
−16 / 9
−17 / 9
−18 / 9  =  −2
−19 / 9
−20 / 9
−21 / 9  =  −7 / 3
−22 / 9
−23 / 9
−24 / 9  =  −8 / 3
−25 / 9
−26 / 9
GIF development
InfoField

POV-Ray source code

Menger_sponge_diagonal_section.povMenger_sponge_diagonal_section.ini
#declare HOLE1 =
 box { <1/6,1/6,0.50001>,<-1/6,-1/6,-0.50001> }
#declare HOLE2_8 =
 union {
  object { HOLE1 translate < 1, 1,0> }
  object { HOLE1 translate < 0, 1,0> }
  object { HOLE1 translate <-1, 1,0> }
  object { HOLE1 translate <-1, 0,0> }
  object { HOLE1 translate <-1,-1,0> }
  object { HOLE1 translate < 0,-1,0> }
  object { HOLE1 translate < 1,-1,0> }
  object { HOLE1 translate < 1, 0,0> }
  scale <1/3,1/3,1>
 }
#declare HOLE3_8 =
 union {
  object { HOLE2_8 translate < 1, 1,0> }
  object { HOLE2_8 translate < 0, 1,0> }
  object { HOLE2_8 translate <-1, 1,0> }
  object { HOLE2_8 translate <-1, 0,0> }
  object { HOLE2_8 translate <-1,-1,0> }
  object { HOLE2_8 translate < 0,-1,0> }
  object { HOLE2_8 translate < 1,-1,0> }
  object { HOLE2_8 translate < 1, 0,0> }
  scale <1/3,1/3,1>
 }
#declare HOLE4_8 =
 union {
  object { HOLE3_8 translate < 1, 1,0> }
  object { HOLE3_8 translate < 0, 1,0> }
  object { HOLE3_8 translate <-1, 1,0> }
  object { HOLE3_8 translate <-1, 0,0> }
  object { HOLE3_8 translate <-1,-1,0> }
  object { HOLE3_8 translate < 0,-1,0> }
  object { HOLE3_8 translate < 1,-1,0> }
  object { HOLE3_8 translate < 1, 0,0> }
  scale <1/3,1/3,1>
 }
#declare HOLE4 =
 union {
  object { HOLE1 }
  object { HOLE2_8 }
  object { HOLE3_8 }
  object { HOLE4_8 }
 }
#declare SPONGE4 =
 difference {
  box    { <0.5,0.5,0.5>, <-0.5,-0.5,-0.5> }
  union {
   object { HOLE4 }
   object { HOLE4 rotate <0,90,0> }
   object { HOLE4 rotate <90,0,0> }
  }
 }

#declare CLOCK       = 1 - 2 * clock;
//#declare CLOCK       = 0;
#declare CLOCK_PLANE =  1.5 * CLOCK;
#declare CLOCK_ALL   = -0.5 * CLOCK;
#debug concat(str(CLOCK, 8, 3), "\n")
difference {
 object {
  //cylinder { <1,1,1>, <-1,-1,-1>, 0.5 } /// check scale constant
  SPONGE4
  pigment { rgb <0.5,1,1> }
 }
 plane  { <-1,-1,-1>, 0 translate <CLOCK_PLANE,0,0> }
 translate <CLOCK_ALL,CLOCK_ALL,CLOCK_ALL>
 rotate    <0,45,degrees(-atan(1/sqrt(2)))>
 no_shadow
}

background { color 1 }
camera {
 right x * image_width / image_height
 location <3.1,0,0>
 look_at  <0,0,0>
 angle    30
}
light_source { <0,9,0> color 1 parallel }
light_source { <9,0,0> color 2 parallel }
; POV-Ray animation ini file
Antialias=Off
;Antialias=On
Antialias_Threshold=0.1
Antialias_Depth=1

Input_File_Name="Menger_sponge_diagonal_section.pov"

Initial_Frame=0
Initial_Clock=0
Final_Frame=54
Final_Clock=1

Cyclic_Animation=off
Pause_when_Done=off

Debug_File=on

Licensing

I, the copyright holder of this work, hereby publish it under the following licenses:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
Category:CC-BY-SA-4.0#Menger%20sponge%20diagonal%20section.gif
GNU head Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled GNU Free Documentation License.
Category:License migration redundant#Menger%20sponge%20diagonal%20section.gifCategory:GFDL#Menger%20sponge%20diagonal%20section.gif
You may select the license of your choice.
Category:Self-published work
Category:Menger sponge diagonal section Category:User:cmglee Category:Animated GIF files Category:Animations with Povray source code Category:Animations of fractals
Category:Animated GIF files Category:Animations of fractals Category:Animations with Povray source code Category:CC-BY-SA-4.0 Category:Created with Persistence of Vision Category:GFDL Category:License migration redundant Category:Menger sponge diagonal section Category:Self-published work Category:User:cmglee