lbfgs
Logistic regression with checkgrad function to ensure correctness