In this paper, we discuss optimality conditions for optimization problems {involving} random state constraints, which are modeled in probabilistic or almost sure form. While the latter can be understood as the limiting case of the former, the derivation of optimality conditions requires substantially different approaches. We apply them to a linear elliptic partial differential equation (PDE) with random inputs.
In the probabilistic case, we rely on the spherical-radial decomposition of Gaussian random vectors in order to formulate fully explicit optimality conditions involving a spherical integral. In the almost sure case, we derive optimality conditions and compare them to a model based on robust constraints with respect to the (compact) support of the given distribution.
We consider the optimal control of a PDE with random source term subject to probabilistic or almost sure state constraints. In the main theoretical result, we provide an exact formula for the Clarke subdifferential of the probability function without a restrictive assumption made in an earlier paper. The focus of the paper is on numerical solution algorithms. As for probabilistic constraints, we apply the method of spherical radial decomposition. Almost sure constraints are dealt with a Moreau--Yosida smoothing of the constraint function accompanied by Monte Carlo sampling of the given distribution or its support or even just the boundary of its support. Moreover, one can understand the almost sure constraint as a probabilistic constraint with safety level one which offers yet another perspective. Finally, robust optimization can be applied efficiently when the support is sufficiently simple. A comparative study of these five different methodologies is carried out and illustrated.