In the last 50 years, many great algorithms have been developed for numerical optimization and these algorithms work well, especially in case of quadratic functions. As we have seen in the previous section, we only have quadratic functions and constraints; so these methods (that are implemented in R as well) can be used in the worst case scenarios (if there is nothing better).
However, a detailed discussion of numerical optimization is out of the scope of this book. Fortunately, in the special case of linear and quadratic functions and constraints, these methods are unnecessary; we can use the Lagrange theorem from the 18th century.
If and , (where ) have continuous partial derivatives and is a relative extreme point of f(x) subject to the constraint where .
In other words, all of the partial derivatives of the function are 0 (Bertsekas Dimitri P. (1999)).
In our case, the condition is also sufficient. The...