1. A method, comprising: solving on computing system an optimal power flow formulation for a plurality of generators in a power system, wherein the solving comprises: computing using multi-threaded parallelism a plurality of constraints for the formulation; computing using multi-threaded parallelism a plurality of Jacobian functions of the constraints; and computing using multi-threaded parallelism a Hessian or Lagrangian functions; and outputting results of the solving, wherein the results comprise values of generation levels for the plurality of generators.