Solver switching support & implementation of Nesterov's accelerated grad...

...ient and AdaGrad
This delete is not exception-safe. Instead of new-ing up an instance in GetSolver, consider using [boost::variant](http://www.boost.org/doc/libs/1_55_0/doc/html/variant.html) to create polymorphic instances. Pointers are a liability because they leak, dangle and get double-deleted, all of which are runtime errors that can be designed out.