Python in "math through programming" curriculum

Kirby Urner urner at alumni.princeton.edu
Wed Dec 20 21:29:42 EST 2000


neelk at alum.mit.edu (Neelakantan Krishnaswami) wrote:

>Yes -- the reference to Knuth's _Concrete Mathematics_ made me think
>that an introduction to CS was envisioned. For things like graphing
>and statistics, there's no reason not to use Python, since it has good
>graphing and statistical libraries. Static typechecking doesn't help
>here, I don't think, and in Haskell's case it becomes a positive
>nuisance (because of all the IO).

Certainly don't want to close the door to CS at all, no way.
Just trying to get computers used more in math class, instead
of just calculators all the time.  'Concrete Mathematics' is
mathematics too, not just CS (same with Knuth's 'Art of...'
-- Miller-Rabin derives from number theory).

Of course more computers in math class'd open more doors to 
CS.  But I'm fighting the prejudice that you don't get to 
use the computer for serious tasks until you do some CS 
elective -- as if math were some whole other domain that 
shouldn't be sullied with computers (but calculators OK 
for some reason).

One thing computers have over calculators is better spatial
geometry displays.  I graft Python to Povray, suggesting Povray
might be more fully exploited in its own right (independently
of Python) -- in art class for example.  In the meantime, I 
encourage Polyhedra as paradigm Objects in both a geometric
and in an OO sense.[1]

Your remarks re strongly typed FP languages are interesting 
and I still want to learn more in that domain -- glad it's 
being discussed.  

I think Python opens doors to languages like Haskell, vs 
closes them, because it has some of the FP syntax, even if 
it's not built around lazy evaluation, tail recursion etc.
etc.  The map, lambda, zip, filter and other syntax has an
FP flavor.  So I think if students pick up on Python first, 
they're not thereby ruined for Haskell or ML later (or Java
either, or any number of other worthy, useful languages).

Anyway, thanks for your intelligent contributions -- learned
some stuff.

Kirby

[1] http://www.inetarena.com/~pdx4d/ocn/trends2000.html





More information about the Python-list mailing list