Modified to work with the new polyfit.py design.
Now pased on SciPy minimizer. Streamlined the design.
Bug fixes.