NL optimization problem with equality constraint can be posted as:
Min f(x)
h_j(x) = 0, j = 1..n
We can use Lagrange multiplier to incorporate equality constraint conditions into the objective function, i.e. turn constrained to unconstrained problem. Thus,
Min x: f(x) + L_j h_j(x)
The optimal solution of the above equation can be obtained when
df(x)/dx = 0 and
h_j(x) = 0 Example