I have to convert this system of equations
$$\begin{cases} f(x_i) = 0 \\ g(x_i) \leq 0 \\ h(x_i) \leq 0 \end{cases}$$
into an optimization problem. In other words I need a function, say $H = H(x_i)$, such that the values of $\{x_i\}$ at its minimum satisfy the system above.
If I had only the first equation of the system I would set $H = (f(x_i))^2$.
Is $$H = (f(x_i))^2 + \lambda (g(x_i) + h(x_i))$$ (for $\lambda > 0$) a good choice?
I guess there're better alternatives I didn't find them yet.
Let $x\in \mathbb{R}^m$ and consider the problem $$\begin{cases} f(x) = 0 \\ g(x) \leq 0 \end{cases},\tag{1}$$ where $f(x)=(f_1(x),f_2(x),\,\ldots,\,f_m(x))$ and $g(x)=(g_1(x),g_2(x),\,\ldots,\,g_n(x))$.
Define the function $$F(x)=\frac{1}{2}\|f(x)\|^2$$ and the minimizing problem $$\begin{cases} \min_x\quad F(x) \\ s.t\,\,\,\,\,\, \quad g(x) \leq 0 \end{cases} \tag{2}.$$
Then the values of $\{x_i\}$ which satisfy the system $(1)$ satisfy this minimizing problem $(2)$.
The associated Lagrangian function is $$L(x,\lambda)=F(x)+\lambda^Tg(x).$$
Please see KKT conditions.
You can find related results searching for "\( \min_x F(x) \) with \( g(x) \leq 0\)" on SearchOnMath.