appliedopt/gpkit — pull request #45 by bqpd (2014-07-07 09:21:12+00:00)
Title: Leaner and meaner

Well, making substitutions better only made it a second faster, but the code's a bit more elegant!

Be warned: lots of changes below. Should still work on your computer, but give it a test.

You'll probably want to fix the *-imports...I left them because I don't like helper.py at all, and think it should be put somewhere else.

A lot of the changes to the GP take advantage of the fact that it looks a heck of a lot like a posynomial when stored...currently the PosyTuple class acts as a bit of a 'save' feature for a GP, which I think could be extended usefully...right now I just use it to preserve state before/after a sweep.