Skip to content

Update PyROS coefficient matching conditions and decision rule variable fixing heuristics - #4116

Open
shermanjasonaf wants to merge 18 commits into
Pyomo:mainfrom
shermanjasonaf:pyros-fix-dr-treatment-coeff-matching
Open

shermanjasonaf wants to merge 18 commits into
Pyomo:mainfrom
shermanjasonaf:pyros-fix-dr-treatment-coeff-matching

Conversation

@shermanjasonaf

Copy link
Copy Markdown
Contributor

Summary/Motivation:

This PR updates PyROS's polynomial coefficient matching approach and decision rule fixing heuristic for exactness:

  • To ensure that the polynomial coefficient matching approach always yields an exact reformulation following Revise PyROS second-stage equality reformulation under discrete (scenario-based) uncertainty #3533, the approach is applied only if the effective uncertainty set (see Add PyROS Uncertain Parameter Reduction #3503) is known to have a positive Lebesgue measure.
  • To ensure that the decision rule fixing heuristic is exact following Modify PyROS DR Order Efficiency #3562, particularly when quadratic decision rules are used, the heuristic is altered such that the decision rule coefficients are frozen according to the structure of the (effective) uncertain parameter realizations that have been added to the master problem, rather than the PyROS iteration number. In particular, the quadratic decision rule coefficients are fixed only if the unique effective uncertain parameter realizations are considered affinely independent.

We also ensure that:

  • The fixing heuristic is consistently applied to not only the master problem, but also the master feasibility (slack) problem and decision rule polishing problem.
  • The decision rule polishing problem is solved if and only if there are unfixed nonstatic decision rule coefficients.

Changes proposed in this PR:

  • Add a new protected UncertaintySet method to check sufficient conditions for an uncertainty set slice having a positive Lebesgue measure. Implement efficient and expansive checks for the various UncertaintySet subclasses.
  • Ensure preprocessor performs coefficient matching only when the effective uncertainty set satisfies explicitly checked sufficient conditions for having positive Lebesgue measure.
  • Update contrib.pyros.master_problem_methods.get_master_dr_degree() so that the decision rule coefficients are fixed according to the number and structure of the effective uncertain parameter scenarios added to the master problem, not the PyROS iteration number.
  • Ensure that in-context application of contrib.pyros.master_problem_methods.higher_order_decision_rule_efficiency() yields consistent decision rule variable fixing for master, master feasibility, and decision rule polishing problems.
  • Update documentation of UncertaintySet.dim for disambiguation.
  • Ensure that PyROS solves decision rule polishing problem iff there are unfixed decision rule variables corresponding to nonstatic terms.

AI-Use Disclosure

  • AI tools were NOT used during the preparation of this PR

Notes for reviewers (optional):

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.

@shermanjasonaf

Copy link
Copy Markdown
Contributor Author

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.

1 participant