Add residue and Jacobian closure generator

Function closure can now be generated to return the residue and Jacobian
for any given vector of Morse parameters. They are designed to be able
to work with the scipy leastsq function.