An efficient method for solving a model predictive control problem is
described. A large sparse matrix equation is formed based upon the model
predictive control problem. The square root of H, Hr, is then formed
directly, without first forming H. A square root (LSMroot) of a large
sparse matrix of the large sparse matrix equation is then formed using Hr
in each of a plurality of iterations of a quadratic programming solver,
without first forming the large sparse matrix and without recalculating
Hr in each of the plurality of iterations. The solution of the large
sparse matrix equation is completed based upon LSMroot.