Skip to content

calc_variable_from_constraint: guard against expression overflow #3541

Merged
jsiirola merged 2 commits intoPyomo:mainfrom
jsiirola:calc-var-overflow
Mar 28, 2025
Merged

calc_variable_from_constraint: guard against expression overflow #3541
jsiirola merged 2 commits intoPyomo:mainfrom
jsiirola:calc-var-overflow

Conversation

@jsiirola
Copy link
Copy Markdown
Member

Fixes #3540 .

Summary/Motivation:

This adds additional guards to calculate_variable_from_constraint() to catch OverflowError exceptions when evaluating the constraint during the initial linear test and during the line search.

Changes proposed in this PR:

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.

Copy link
Copy Markdown
Contributor

@Robbybp Robbybp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FBBT may be nice as well, but I see no reason not to do this.

@jsiirola jsiirola merged commit b524a24 into Pyomo:main Mar 28, 2025
64 of 65 checks passed
@jsiirola jsiirola deleted the calc-var-overflow branch March 28, 2025 03:43
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.

calculate_variable_from_constraint is unreliable for exponential functions

3 participants