Implementing efficiency suggestion by Joel in SnoptSolver