Problem 1 (ContEst)
3GC3[mpfootnoteProblem 1 is a two-stage problem, a special form of a bilevel problem; the outer optimization contains the value of the lower-level problem, not its argmin. Solving a bilevel problem directly is hard since it requires implicitly differentiating the inner optimality conditions. Instead, in the two-stage case, the envelope theorem supplies the gradient directly from the duals the inner solver already returns.