Skip to content

Simple disjunctive transform#3982

Draft
cjohnston1 wants to merge 2 commits into
Pyomo:mainfrom
cjohnston1:SimpleDisjunctiveTransform
Draft

Simple disjunctive transform#3982
cjohnston1 wants to merge 2 commits into
Pyomo:mainfrom
cjohnston1:SimpleDisjunctiveTransform

Conversation

@cjohnston1

@cjohnston1 cjohnston1 commented Jun 22, 2026

Copy link
Copy Markdown

Fixes # .

Summary/Motivation:

This PR is a draft meant to facilitate conversation and is not ready to be reviewed and committed.

This PR is a draft of the simple disjunctive transformation module. This creates a new transformed disjunction which has a single inequality per disjunct for either user given disjunctions or all disjunctions on a model if no input is given. The transformation can be done in multiple ways which are selected by the user. This is motivated by the development of another module which can generate a family of inequalities for these transformed disjunctive constraints.

Changes proposed in this PR:

  • Adds the simple disjunction transform module
  • Adds tests for the simple disjunction transform module.

AI-Use Disclosure

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

or

  • 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):

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.

@codecov

codecov Bot commented Jun 22, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 93.02326% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 90.02%. Comparing base (44c4697) to head (76293ed).
⚠️ Report is 136 commits behind head on main.

Files with missing lines Patch % Lines
pyomo/gdp/plugins/simple_disjunction_transform.py 93.02% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3982      +/-   ##
==========================================
- Coverage   90.12%   90.02%   -0.11%     
==========================================
  Files         909      918       +9     
  Lines      108561   109888    +1327     
==========================================
+ Hits        97836    98922    +1086     
- Misses      10725    10966     +241     
Flag Coverage Δ
builders 29.10% <25.58%> (-0.01%) ⬇️
default 86.12% <93.02%> (?)
expensive 35.11% <25.58%> (?)
linux 85.90% <93.02%> (-3.72%) ⬇️
linux_other 85.90% <93.02%> (-1.73%) ⬇️
oldsolvers 28.03% <25.58%> (-0.01%) ⬇️
osx 83.12% <93.02%> (+0.06%) ⬆️
win 85.42% <93.02%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

3 participants