[Edu-sig] Pythonic Mathematics (session four)
kirby urner
kirby.urner at gmail.com
Sat May 13 23:17:52 CEST 2006
I had a successful breakthrough regarding my Saturday Academy class in
Python Mathematics: use kepler.dodecahedron and plato.dodecahedron to
show why dodecahedron alone is ambiguous and/or why a name collision
might happen.
That was part of a much longer thread on what I'm calling the four
eras of computer programming: wild west (spaghetti code); civilized
(structured programming); organic (OO); and managed (design patterns).
As you may gather, I'm so far not blown away by the relevance of
lambda calculus.
One student asked how 3D Mandelbrot Sets were mathematically
determined, given he understands the 2D case using the complex plane.
I guessed using Quaternions but who wants to tell me for sure? My
guess formed a good branching off point, in any case.
I had 'em dive into VPython today, with just the API docs and a few
pointers as I fumbled, beginner-like, in a projected IDLE session
(later, I'd show them where to download a stash of canned VPython
polyhedra -- a star student got it going in no time, started exploring
my methods). Even the youngest had a space ship with two solar panels
to show his mom when she came by to collect him. And my fractal guy,
he had Saturn saved in planets.py, using a ring and a sphere object.
We discovered how to do color, first by setting object.red
object.green and object.blue (pause to re-explain RGB), then by
setting object.color to color.somecolor (the visual.color module just
has a very few -- I'd think they'd want more, especially given the
lack of textures).
I also downloaded, installed and booted up Panda3D on the Toshiba (my
laptop on the projector). We started with Greeting Card then went
exploring. One of the Panda demos quickly tosses out a 3D fractal tree
with a few keyboard controls. All of these are Python programs, with
the C++ API imported (I still haven't solved the dark matter problem,
alluding to blog).
So yes, we finally went graphical today, which was a big step. I also
projected video.google of a fractal, me talking about domes, and Chieh
doing one of his Tk-with-Python lectures. The technology is still a
tad too low rez, so I can see where all that optical fiber might come
in useful some day. We could watch Chieh in high rez and actually
read what he's typing. I also shared a bit of Eskimo culture on
You-tube.
Last week, session three [*], was a lot of dense number theory with
modulo operator, very left brain, nothing especially graphical. So
I'm glad we got good and GUI today. I've been promising we would.
Today I made good.
Kirby
[*] http://mathforum.org/kb/thread.jspa?threadID=1380445
More information about the Edu-sig
mailing list