pub fn ipm_user_iterate(
nlp: &Rc<RefCell<dyn IpoptNlp>>,
data: &IpoptDataHandle,
cq: &IpoptCqHandle,
fixed_var_duals: bool,
) -> Option<UserIterate>Expand description
The interior-point iterate in the space of the TNLP the NLP wraps, by
the conversions finalize_via_orig_nlp applies to the final one, so the
iterate read at the last fire is the solution finalize_solution
reports:
xthroughfinalize_solution_x(fixed variables spliced back in);z_L,z_U,λthrough thefinalize_solution_*lifts, which divide outobj_scale_factor(the unscaled-Lagrangian convention);- the bound multipliers of variables
make_parameterremoved recovered fromz_L − z_U = ∇f + Jᵀλwhenfixed_var_duals— upstreamTNLP::get_curr_iteratedoes the same throughTNLPAdapter::ResortBoundMultipliersfor every treatment butmake_parameter_nodual. Left at0they were not a zero multiplier but a missing one; - per-variable
user-scaling(x̃ = d ⊙ x) is not undone here: theScalingTnlpthat substitutes it undoes it on the iterate’s way through itsintermediate_callback, as itsfinalize_solutiondoes; gfrom the iterate’s ownc/dvalues, unscaled.
The fixed-variable recovery evaluates the TNLP, so this must run before the callback borrows it, never from inside the callback.