fivemack: (balls)
[personal profile] fivemack
Have some pretty sphere-packing pictures:

Here they are. An evening's work, which I feel is probably a little more than it would have taken an actually competent mathematician, but hopefully adequately attractive.

I do not promise to hand over the Mars bar in person to any of my foreign correspondents who solves the problem, at least not with any unusual dispatch.

It also gives an optical illusion I hadn't seen before; the circle below is circular - rotate it in GIMP and overlay it on itself if you doubt me - but with the converging pink lines below it, it looks very squashed at the bottom:

Date: 2004-08-05 01:53 am (UTC)
From: [identity profile] uon.livejournal.com
almost interactive use

OpenGL is your friend.

Date: 2004-08-05 02:26 pm (UTC)
From: [identity profile] fivemack.livejournal.com
Thanks for that :)

I couldn't get it to work on my Win32 perl - I tried the "ppm install http://www.bribes.org/perl/ppm/OpenGL.ppd" command, but the perl interpreter then complained it couldn't find OpenGL/Simple.pm.

So I moved to python, and, after downloading PyOpenGL, OpenGLContext, Numeric, PIL and PyDispatcher (all of which come as single .EXE files), got this (http://www.chiark.greenend.org.uk/~twomack/spheres/my_spheres.py) to work. It's not perfect - the spheres have something of a black-metal Goth look which suggests I've missed something critical in the definition of the lighting model - but it's reasonably pretty.

My interesting discovery of the evening is that the problem is chiral - after the yellow stage, there are 24 equally-good centres for the next smaller sphere, but they come in pairs and you can only choose one of each pair. At which point all sorts of awkward questions about which of the 4096 is the natural one to choose start to rear their ugly heads ...

Date: 2004-08-11 07:14 am (UTC)
From: [identity profile] uon.livejournal.com
I couldn't get it to work on my Win32 perl

I've just been sent some patches that ought to make OpenGL::Simple build on Win32; how soon a new version appears on CPAN may be a function of how dull the conference I'm attending next week is..

March 2024

S M T W T F S
     12
3456789
10111213141516
17181920212223
24 252627282930
31      

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jan. 31st, 2026 07:35 pm
Powered by Dreamwidth Studios