A common optimization problem is the minimization of a symmetric positive
definite quadratic form $< x,Tx >$ under linear constrains. The solution to
this problem may be given using the Moore-Penrose inverse matrix. In this work
we extend this result to infinite dimensional complex Hilbert spaces, making
use of the generalized inverse of an operator. A generalization is given for
positive diagonizable and arbitrary positive operators, not necessarily
invertible, considering as constraint a singular operator.