hessian generation for equations with loops makes use of sparseForJacHessian()