added gradients (to Python solver) and unit tests
adding gradients and tests to basic solver
Merge branch 'grad'