Joe Strout posted recent on the RB Network Users Group list about a cool project he did a while ago called Pythonica (in the context of symbolic evaluation). While Pythonica is a bit out of date (the page last updated in ’97), it’s still pretty nifty.

Pythonica is a symbolic evaluation program written in Python. It’s loosely based off of Mathematica and is a really good start. It’s missing a lot and it’s weak in other areas, but it’s still fun to play around with and can be extended.

Anyway, over the last couple of days I’ve been updating it a bit (replacing uses of the regex module with re, removing some deprecated uses of the string module, etc) and improving it. I’ve implemented some new functions (Sin/Cos/Tan/ASin/ACos/ATan/Rad2Deg/Deg2Rad), added a couple of default symbols (pi and e), and fixed some bugs (for example, Sin[pi/4] used to produce Sin[pi,4] instead of Sin[Divide[pi,4]]). At some point I’m probably going to start re-writing some of the internals to support some things Joe suggests on his page.

Anyway, Pythonica is pretty cool and a decent example of Python code. If you like Python, you should check it out.

I’m now maintaining Pythonica. Joe Strout doesn’t want to maintain it any longer ;) You can find my page at http://www.tildesoft.com/Pythonica.html
Leave a Reply

Preview: