Optimizing: the Minimum Variance (or Maximum Return) Portfolio example
The aim is the optimization either by maximizing total return (or minimizing risk), in keeping with the constraints of normalization for a given risk (or return).
Thus Lagrange method is perfectly suited for the job.
For minimizing risk, respect to a desired total return , one must consider the function of total risk
and minimize the lagrangian with constrain over the desired return and sum to one of weights.