I am solving a problem which has bilevel optimization with integration involved. The problem is:
(w^*,k^*) = argmax_{w\geq c,k\geq 0} (w-c)E_{\theta_1- \theta_2}[E_{\epsilon=-\delta - \delta}[min(\theta+\epsilon-p^*,k)]]
where
p^*(\theta,w,k) = argmax_{p\geq w}E_{\epsilon}[min(\theta+\epsilon-p,k)]
OO = (c-w) * (int( 0.02*max(min(theta+x-p,k),0) ,[x theta], [double(-delta) double(theta_1)], [double(delta) double(theta_2)] ));
CO = [w<= 1000, k<=1000, w >= c, k >= 0, p<=1000, p >= 0 , theta >= theta_1, theta <= theta_2, x >= -delta, x <= delta];
OI = (w-p) * (int( 0.02*max(min(theta+x-p,k),0), x, -delta, delta));
CI = [w<= 1000, k<=1000, w >= c, k >= 0, p<=1000, p >= 0 , theta >= theta_1, theta <= theta_2, x >= -delta, x <= delta];
solvebilevel(CO,OO,CI,OI,[p w k])
However, I can't get the result. Can anyone help me about this? Thanks!!!