Consider the problem: \begin{align} \min_{x\in X}f(x)\qquad {\rm s.t.}\;\;h(x)=0,\;\;g(x)\leq0. \end{align} Assume that $X$ is closed and convex, $f$ and $g$ are continuously differentiable and convex over $X$, and $h$ is affine. Also assume that the Slater condition holds. Define the Lagrangian as $L(x,\lambda,\mu)=f(x)+\lambda^Th(x)+\mu^Tg(x)$.
I am confused with the KKT stationarity condition of the above problem. If $X=\mathbb{R}^n$, I know that the KKT stationarity condition is $\nabla_xL(x,\lambda,\mu)=\nabla_xf(x)+\sum_{j}\lambda_j\nabla_xh_j(x)+\sum_{l}\mu_l\nabla_xg_l(x)=0$. Now, if $X\neq\mathbb{R}^n$, what shoud the condition be? I am thinking that it should be $\nabla_xL(x,\lambda,\mu)\in N_X(x)$, where $N_X(x)$ is the inward normal cone to $X$ at $x$, i.e., $N_X(x)=\{p\in\mathbb{R}^n:p^T(x-y)\leq0,\;\forall y\in X\}$. The overall KKT conditions are then \begin{align} x\in X,\;\;\nabla_xL(x,\lambda,\mu)\in N_X(x),\;\;h(x)=0,\;\;g(x)\leq0,\;\;\mu^Tg(x)=0,\;\;\mu\geq0. \end{align} I am not sure whether the above conditions are correct.