Last Update Apr. 17, 1998  日本語はこちら


NUMERICAL SPACE / CUBES


POV-Ray has many internal functins and
control comands. So we can easily make
arranged groups of objects.
For example, you can get 10x10x10=1000
cubes in the X-Y-Z space by the script
I show right. They will be colored one
by one with the position.
I can get tipical computer graphics by
this way on X-Z plane and trigonometrical
functions or other. Images in this page
are those I got from that. I colored
them by the value of Y direction to show
their structure clearly.

I wrote functions I used for all images
so that you can get similar images.

    #declare Cy=0
    #while (Cy < 11)
    #declare Cz=0
    #while (Cz < 11)
    #declare Cx=0
    #while (Cx < 11)
    box { <-0.15,-0.15,-0.15> <0.15,0.15,0.15>
    translate < Cx, Cy, Cz >
    pigment { color red 1-Cx/10 green Cy/10 blue 1-Cz/10}
    }
    #declare Cx=Cx+1
    #end
    #declare Cz=Cz+1
    #end
    #declare Cy=Cy+1
    #end


    #declare C = (Cx*Cx+Cz*Cz)*0.004
    #if ( C<3.1415*1.2 )
    box { <-0.15,-0.15,-0.15> <0.15,0.15,0.15>
    translate
    finish {phong 0.3} finish {ambient 0.5}
    pigment {color red 1-sin(C-3.1415/2) green 0.2-0.2*sin(C-3.1415/2) blue sin(C-3.1415/2)}
    }

Arranged to Dish / 70k / Mar. 1998 / by Tsutomu Higo


    C=sin(Cx*0.5)*sin(Cz*0.5)+(Cx-5)*(Cx-5)*0.0009+(Cz-2)*(Cz-2)*0.0009
    box { <-0.15,-0.15,-0.15> <0.15,0.15,0.15>
    translate < Cx, C, Cz >
    finish {phong 0.3 ambient 0.5}
    pigment {color red 1-C green 0.2+0.3*C blue C}
    }

Arranged to Knots / 84k / Mar. 1998 / by Tsutomu Higo


    #declare C=2*sin(0.003*Cx*Cx+0.003*Cz*Cz)+(Cx-5)*(Cz-15)*0.01+(Cz-2)*(Cz-7)*0.005-(Cz+2)*(Cz+1)*0.0015
    box { <-0.15,-0.15,-0.15> <0.15,0.15,0.15>
    translate < Cx, Ct, Cz>
    finish {phong 0.2 ambient 0.3}
    pigment {color red 1-0.5*C green 0.8-0.1*C*C blue 0.5*C}
    }

Arranged to Wave / 68k / Mar. 1998 / by Tsutomu Higo


    #declare C=400-Cx*Cx-Cz*Cz
    # if ( C>0 )
    #declare C=sqrt(C)
    box { <-0.15,-0.15,-0.15> < 0.15,0.15,0.15>
    translate < Cx, C, Cz>
    finish {phong 0.2 ambient 0.3}
    pigment {color red 1+C/20 green 0.2+C/50 blue -C/20}
    }
    box { <-0.15,-0.15,-0.15> <0.15,0.15,0.15>
    translate < Cx, -C, Cz>
    finish {phong 0.2 ambient 0.3}
    pigment {color red 1-C/20 green 0.2-C/50 blue C/20}
    }

Arranged to Sphere / 83k / Mar. 1998 / by Tsutomu Higo



All rights reserved.

JUMPReturn to Virtual Space INDEX