fix mapping of meta data for variable bounds #590
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Mapping from full x to x without fixed vars was not taken into account.
@danieloliveira56 I think this should fix the issue with the variable names for variable bounds that you reported to GAMS support.
It looks to me like when going from full x to the reduced x (fixed variables removed), things were ok and that's why we got
But for the lower variable bounds (x_L), both the mapping from full x to the reduced x and then from the reduced x to the variables with lower bound needs to be taken into account. But only the latter was used in the code. (same for x_U)
So here I change it to use
pos_idx
(full x -> reduced x) and pos_idxL (reduced x -> x_L).I now get
As you are an expert on this kind of Ipopt code (#570), I thought I may ask you to have another look. :)