Skip to content

MindtPy: maintain a valid dual bound in each iteration when no-good c… - #4038

Open
ZedongPeng wants to merge 2 commits into
Pyomo:mainfrom
ZedongPeng:mindtpy-remove-extra-master-solve
Open

MindtPy: maintain a valid dual bound in each iteration when no-good c…#4038
ZedongPeng wants to merge 2 commits into
Pyomo:mainfrom
ZedongPeng:mindtpy-remove-extra-master-solve

Conversation

@ZedongPeng

Copy link
Copy Markdown
Contributor

Fixes # .

Summary/Motivation:

When no-good cuts or the tabu list are active (always the case for GOA), the MILP main problem is not a relaxation of the original MINLP, so its objective value alone is not a valid dual bound. MindtPy currently corrects this after termination by deactivating the no-good cuts added after the incumbent was found and re-solving the main problem (fix_dual_bound). This extra solve is unnecessary: the no-good cuts only exclude integer combinations whose NLP subproblems were already solved to (global) optimality or proven infeasible, so the incumbent is the exact optimum over the explored combinations, while the main problem bound remains valid for the unexplored ones. A valid dual bound is therefore simply min(UB, v) for minimization, where v is the main problem bound. This PR maintains that bound directly in update_dual_bound in every iteration, so no extra MIP/NLP solve is needed. The sequence of explored integer combinations and the termination point are unchanged.

Changes proposed in this PR:

  • Clamp the dual bound to the primal bound in update_dual_bound when add_no_good_cuts or use_tabu_list is active
  • Remove fix_dual_bound (re-solved the main problem and possibly one extra NLP subproblem after termination) and its support machinery: deactivate_no_good_cuts_when_fixing_bound, num_no_good_cuts_added, last_iter_cuts, and the single-tree stored_bound mechanism
  • Update the dual bound from the final single-tree MIP results also when no-good cuts are active (the clamped bound is valid)

AI-Use Disclosure

  • AI tools contributed to the development of this PR

    • AI tools generated documentation (including the PR description/comments, code comments, and/or Sphinx documentation)
    • AI tools generated tests (baselines, examples, and/or code)
    • AI tools generated code (apart from tests)

    Review process (select ONE):

    • Rewritten: All AI-generated content was rewritten by me before being committed.
    • Reviewed/verified: I retained AI-generated content and verified it before committing. Verification included (as applicable):
      • Ran the code and fixed issues
      • Added and ran tests
      • Checked correctness/logic of code and tests
      • Checked for alignment with the contribution guide
      • Considered security implications
    • As-is: AI-generated content was commited directly to the repository

Notes for reviewers (optional): The dual bound shown during iterations is now the clamped valid bound, and single-tree GOA reports the clamped B&B tree bound instead of the stored bound from one iteration before the incumbent. Existing GOA and LP/NLP tests cover these paths.

Legal Acknowledgement

By contributing to this software project, I have read the contribution guide and agree to the following terms and conditions for my contribution:

  1. I agree my contributions are submitted under the BSD license.
  2. I represent I am authorized to make the contributions and grant the license. If my employer has rights to intellectual property that includes these contributions, I represent that I have received permission to make contributions and grant the required license on behalf of that employer.

@ZedongPeng

Copy link
Copy Markdown
Contributor Author

@bernalde

Close the bound gap when certified integer exclusions exhaust the main problem, including single-tree solves. Retain the preceding dual bound after an unresolved fixed NLP so exclusions cannot certify false optimality or infeasibility.

Add solver-backed regressions for both objective senses and document the assumptions behind the bound calculation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants