Open
Conversation
np.complex_ was removed in NumPy 2.0. np.complex128 is semantically identical and available in all supported NumPy versions. Also fixes a pre-existing bug in combine_split_comp.py where dtype=np.dtype (the class itself) was passed instead of the local variable dtype. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
NumPy 2.0 removed automatic coercion of 1-element arrays to Python scalars, so math.cos/sin/sqrt no longer accept numpy array inputs. Replace with np.cos/sin/sqrt which handle arrays natively. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…enMDAO 3.43 Small numerical differences (~3e-6 relative) in surge_margin (N3) and battery SOC_final (HybridTwin) arise from library version changes and are not correctness regressions. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
During Newton solver warmup iterations, fltcond|Utrue can temporarily go negative, making Re negative and causing log(negative) = NaN which propagates through the Jacobian. Fix: compute Re = U*L/visc_kin and apply abs(Re) for real-valued arrays only, so complex-step derivative checking still propagates the imaginary part correctly (for complex arrays, negate Re where real(Re)<0). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Explain the goal of this PR, if it addresses an existing issue be sure to link to it. Describe the big picture of your changes here, perhaps using a bullet list if multiple changes are done to accomplish a single goal. If it accomplishes multiple goals, it would be best to create separate PR's for each.
Makes openconcept compatible with numpy 2.4+
Type of change
What types of change is it?
Select the appropriate type(s) that describe this PR
Testing
Explain the steps needed to test the new code to verify that it does indeed address the issue and produce the expected behavior.
Checklist
Put an
xin the boxes that apply.