MATLAB: How to find the feasible solution space of a nonlinear constraint optimization problem

MATLABoptimization

I want to find the feasible objective space of a Multi objective nonlinear constraint optimisation problem. The problem is in the following form.
min [F1(X),F2(X)]
hk(X)=0 k=1,...,ne % equality constraints
gi(X)0 i=1,...,n % Inequality constraints.
Ul<X<UB % UB and UL are upper and lower bounds of X
where X=[x1,x2,...,xj]
It should be noted that, some optimisation variables, (`some x`) are not bounded at the Ul<X<UB . But they will be restricted through the equality and inequality constraints.
SO basically as a possible solution I think that I should generate some random numbers for X=[x1,…,xn] first and then check the constraints. if generated point satisfies the constraint, so it is a feasible point in the solution space. Thus, I can pass it to the objective function to get its value [F1(X),F2(X)] in order for obtaining the feasible objective space. But I don't know how to check the constraint. Any idea?
Thanks for your help.

Best Answer

Assuming for the moment that you have no equality constraints, you would have to use NDGRID to generate a grid of samples in your N-dimensional space covering your bounded region Ul<X<UB. Then you would loop through the lattice of points, check which points satisfy the other inequality constraints, and then compute [f1,f2] for those points. Depending on the form of your constraints and objectives, there may also be vectorized ways of doing this, instead of looping.
When you do have equality constraints, then you would have to eliminate them by reparametrization. For example, linear equality constraints Aeq*x=0 define a linear space with basis vectors B1,B2,B3,... You can eliminate those constraints by reparametrizing X in terms of basis coefficients c1,c2,c3...
X=c1*B1+c2*B2+...
In other words, your vector of unknowns is now the vector c=[c1,c2,c3,...]. Rewriting your problem in terms of c eliminates the equality constraints. With non-linear equalities, this is harder to do, but I don't think you have much choice.
Finally, doing what you are attempting is only going to be possible if the dimension of the problem after eliminating equality constraints is reasonably low. Obviously, though, brute force numerical sampling is only something that was ever going to work in low dimensions. Random sampling won't work in large dimensions either. The volume of the feasible region can get very small as a fraction of an N-dimensional box as N gets large.