Switch to an interpolating line search

* New line search is more robust
* New line search is more costly in terms of gradient calls,
  so we'll need to have mechanism for switching default line
  search.
* Lots of generic code cleanup
* Fixed a bug in the README
* New tests