Merge pull request #15 from bchretien/master

Fix a difference of behavior between GCC and Clang.
Add missing gradient size in finite-difference sparse Jacobian computation.