IDAES / idaes-pse

The IDAES Process Systems Engineering Framework
https://idaes-pse.readthedocs.io/
Other
206 stars 228 forks source link

Fixing spurious DoF in Gibbs reactor model #1393

Closed andrewlee94 closed 2 months ago

andrewlee94 commented 2 months ago

Fixes #1392

Summary/Motivation:

The current implementation of the Gibbs reactor model includes all elements in the Lagrange multipliers expressions, even if the elemental composition for a given component is 0. This leads to spurious degrees of freedom where the variable appears to be in active constraints but is multiplied y zero (and thus filtered out in the Pyomo solver writers).

Changes proposed in this PR:

Legal Acknowledgement

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

  1. I agree my contributions are submitted under the license terms described in the LICENSE.txt file at the top level of this directory.
  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[bot] commented 2 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 77.62%. Comparing base (f8ccdec) to head (59dc412).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1393 +/- ## ========================================== - Coverage 77.63% 77.62% -0.01% ========================================== Files 391 391 Lines 64375 64386 +11 Branches 14257 14262 +5 ========================================== + Hits 49978 49981 +3 - Misses 11827 11834 +7 - Partials 2570 2571 +1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.