Constrained Optimization and the KKT Conditions