Create Journals
Update Journals

Journals
Find Users
Random

Read
Search
Create New

Communities
Latest News
How to Use

Support
Privacy
T.O.S.

Legal
Username:
Password:

ClaudiusMaximus (claudiusmaximus) wrote,
@ 2006-02-28 23:21:00
Previous Entry  Add to memories!  Add to Topic Directory  Tell a Friend!  Next Entry

    Current mood:geometrical
    Current music:BBC Radio 4

    Polyhedra

    More fun with Fluxus - I've been learning how to use (build-polygons), where you define the vertices that make up the faces (and the normals to the faces which control lighting). I had a heck of a time getting the tetrahedron working, I found that (recalc-normals) didn't work in a way that was suitable. The function (hint-normal) shows the normals as red lines, so you can check they are pointing in the right directions, very helpful. Once I got used to it, making an octahedron was much easier.

    Cube and Octahedron

    Cube and Octahedron

    Five Tetrahedra (left-handed and right-handed variants)

    Five Tetrahedra

    Five Tetrahedra

    Ten Tetrahedra (some misalignment due to rounding errors or mistakes in my maths)

    Ten Tetrahedra

    (define (pow a b) (exp (* (log a) b)))
    
    (define (build-octahedron)
      (let ((ob (build-polygons 24 2))
            (L (pow (/ 1 3) (/ 1 3)) )
            (-L (- 0 (pow (/ 1 3) (/ 1 3))))
           )
    
        (grab ob)
    
        (pdata-set "p"  0 (vector  1  0  0))
        (pdata-set "p"  1 (vector  0  1  0))
        (pdata-set "p"  2 (vector  0  0  1))
    
        (pdata-set "p"  3 (vector  1  0  0))
        (pdata-set "p"  4 (vector  0  0  1))
        (pdata-set "p"  5 (vector  0 -1  0))
    
        (pdata-set "p"  6 (vector  1  0  0))
        (pdata-set "p"  7 (vector  0 -1  0))
        (pdata-set "p"  8 (vector  0  0 -1))
    
        (pdata-set "p"  9 (vector  1  0  0))
        (pdata-set "p" 10 (vector  0  0 -1))
        (pdata-set "p" 11 (vector  0  1  0))
    
        (pdata-set "p" 12 (vector -1  0  0))
        (pdata-set "p" 13 (vector  0  0  1))
        (pdata-set "p" 14 (vector  0  1  0))
    
        (pdata-set "p" 15 (vector -1  0  0))
        (pdata-set "p" 16 (vector  0 -1  0))
        (pdata-set "p" 17 (vector  0  0  1))
    
        (pdata-set "p" 18 (vector -1  0  0))
        (pdata-set "p" 19 (vector  0  0 -1))
        (pdata-set "p" 20 (vector  0 -1  0))
    
        (pdata-set "p" 21 (vector -1  0  0))
        (pdata-set "p" 22 (vector  0  1  0))
        (pdata-set "p" 23 (vector  0  0 -1))
    
    
        (pdata-set "n"  0 (vector  L  L  L))
        (pdata-set "n"  1 (vector  L  L  L))
        (pdata-set "n"  2 (vector  L  L  L))
    
        (pdata-set "n"  3 (vector  L -L  L))
        (pdata-set "n"  4 (vector  L -L  L))
        (pdata-set "n"  5 (vector  L -L  L))
    
        (pdata-set "n"  6 (vector  L -L -L))
        (pdata-set "n"  7 (vector  L -L -L))
        (pdata-set "n"  8 (vector  L -L -L))
    
        (pdata-set "n"  9 (vector  L  L -L))
        (pdata-set "n" 10 (vector  L  L -L))
        (pdata-set "n" 11 (vector  L  L -L))
    
        (pdata-set "n" 12 (vector -L  L  L))
        (pdata-set "n" 13 (vector -L  L  L))
        (pdata-set "n" 14 (vector -L  L  L))
    
        (pdata-set "n" 15 (vector -L -L  L))
        (pdata-set "n" 16 (vector -L -L  L))
        (pdata-set "n" 17 (vector -L -L  L))
    
        (pdata-set "n" 18 (vector -L -L -L))
        (pdata-set "n" 19 (vector -L -L -L))
        (pdata-set "n" 20 (vector -L -L -L))
    
        (pdata-set "n" 21 (vector -L  L -L))
        (pdata-set "n" 22 (vector -L  L -L))
        (pdata-set "n" 23 (vector -L  L -L))
    
        (finalise)
    
        (ungrab)
    
        ob
    
      )
    )


(Post a new comment)


psyclone
2006-03-06 22:45 (link)
Your work is getting more impressive as you go along. It's fun to watch you progress...

(Reply to this) (Thread)

Thanks!
claudiusmaximus
2006-03-08 11:50 (link)
Hopefully that trend will continue, too :)

(Reply to this) (Parent) (Thread)


antisocialme
2006-03-16 09:33 (link)
WHOA That's awesome! You're a freaking genius!

(Reply to this) (Thread)


claudiusmaximus
2006-03-17 19:17 (link)
Heh, I'm no genius, just standing on the shoulders of giants. But thanks :)

(Reply to this) (Parent) (Thread)


(Post a new comment)

© 2002-2008. Blurty Journal. All rights reserved.