Optimization problem with constraint containing one design variable and one non-design variable I have an objective function $f(x_1,x_2)$ which should be minimized while a function $g(x,x_1,x_2)$ MUST be greater than 0.8 for ALL x in an intervall $x=[0,10]$. As you can see, the constraint has a design variable from function $f$ and at the same time it has a "normal" variable. How can one define a mathematical problem for that? If the constraint would only contain design variables, I would know how to do it. 
Notice: the functions are a bit simplified. The objective function and the constraint are non-linear.
EDIT: Since the original functions were requested, here they are:
$f(x_1,x_2)=150 - \frac{x_2\cdot(5\cdot x_1 - 20)}{5} - 25\cdot2^{0.5}\cdot pi^{0.5}\cdot2\cdot erf(\frac{3\cdot 50^{1/2}}{10}) - \frac{c}{5}$
$g(x,x_1,x_2)=-\frac{1+x_1}{x_2}*x+x_1+5*exp(-\frac{(x-15)^2}{50}) \leqq 0.8$
 A: In general, you have a bilevel optimization problem in which the inner problem is maximum of g with respect to x, subject to 0≤x≤10, is ≤ 0.8. If you want to read all about bilevel optimization, here is an expensive book "Practical Bilevel Optimization" by Bard https://www.springer.com/us/book/9780792354581 .
One easy but not completely rigorous way to deal with this is to make the g constraint into n constraints, one for each of n grid points for x in [0,10]. For instance, with grid spacing of 0.01, there are 1001 such constraints. And also −10 ≤ x1 ≤ −0.5 and 0 ≤ x2 ≤ 20. The objective function is −x1∗x2. This is a non-convex optimization problem, so you'll have to use a global optimizer to ensure finding the global minimum.
You could use FMINCON to solve this formulation, but that is a local optimizer, so you might not find the global optimum. You could install YALMIP. then use BMIBNB (global optimizer which comes with YALMIP), specifying FMINCON as the upper solver. 
Here is the YALMIP code your example in the comment:
x1 = sdpvar; 
x2 = sdpvar; 
x = 0:.01:10; 
Con = [-10<=x1<=-0.5,0<=x2<=20,-(1+x1)/x1.*x+x1+5*exp(-(x-15).^2/50)<=0.8];
optimize(Con,-x1*x2,sdpsettings('solver','bmibnb','bmibnb.uppersolver','fmincon'))
disp(value([x1 x2]

This example is quickly solved, with resulting optimal x1 = -10, x2 = 0. Actually any x1 in the range $-10 \le x1 \le -1.125$, which are the feasible values of x1, is optimal in conjunction with x2 = 0. This is a very easy problem to solve to global optimality. A little theoretical analysis could probably arrive at this solution for this example without the need for numerical optimization. 
