-
-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revisiting Boundary Value Problems #477
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AI-Maintainer Review for PR - Revisiting Boundary Value Problems
Title and Description 👍
The Title and description are clear, concise and helpful
The title and description of the pull request are clear and concise. They effectively communicate the purpose of the changes, which is to revisit and improve the handling of boundary value problems. The description provides a detailed explanation of the shortcomings of the current implementation and proposes specific improvements to address them. It also mentions the implemented features related to the TwoPointBVPFunction
.
Scope of Changes 👍
The changes are narrowly focused and address a specific set of issues
The changes proposed in this pull request are focused on addressing specific issues related to boundary value problems. The proposed improvements and implemented features are all related to enhancing the definition and functionality of boundary value problems. The author is not trying to tackle multiple unrelated problems simultaneously, which is a good practice.
Documentation 👎
Some newly added functions and methods lack docstrings
The following newly added functions and methods do not have docstrings:
TwoPointBVPFunction
(constructor)(f::TwoPointBVPFunction)(residuala, residualb, ua, ub, p)
method(f::TwoPointBVPFunction)(residual::Tuple, u, p)
method
These additions would benefit from having docstrings to describe their behavior, arguments, and return values. Please add these docstrings to improve code readability and maintainability.
Testing 👎
The description does not mention how the changes were tested
The description does not provide information about how the changes were tested. It would be beneficial to include details about the testing approach and any test cases that were used to validate the changes. This would provide transparency and ensure the changes have been adequately tested.
Suggested Changes
- Please add docstrings to the newly added functions and methods to describe their behavior, arguments, and return values. This will improve code readability and maintainability.
- Please provide information about how the changes were tested. This could include the testing approach and any test cases that were used to validate the changes.
Reviewed with AI Maintainer
Codecov Report
@@ Coverage Diff @@
## master #477 +/- ##
==========================================
- Coverage 57.65% 0.00% -57.66%
==========================================
Files 50 50
Lines 3710 3635 -75
==========================================
- Hits 2139 0 -2139
- Misses 1571 3635 +2064
... and 45 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
The first. We require matching in all other instances (for example, SDEs).
It's just been a waiting for a BVPFunction. Yes we should do this. The reason why it was waiting though was to confirm whether we wanted two different
Well justified.
Length assumes
Yeah having a transition path like that is good. That will keep old codes working, if unoptimized (but it wasn't well-optimized before anyways so whatever). |
I want to add a few more things here:
SciMLBase.jl/src/problems/bvp_problems.jl Lines 117 to 122 in cce1ce0
SciMLBase.jl/src/problems/bvp_problems.jl Lines 153 to 160 in cce1ce0
I think maybe we also need another property in |
I think this looks good. Failing test though? I want this to be merged at the same time as #497 |
Give me a few hours, I am finishing up the ODEInterface integration to confirm we have everything we need. The tests here also need updating due to the breaking change |
If this tests, pass we can bump it to 2.0 and then merge. Testing with 2.0 doesn't work due to version conflicts while installing StochasticDiffEq and others |
With the recent developments around BoundaryValueDiffEq.jl and adjoint sensitivity computation for BVPs, there seem to be some clear shortcomings in how these problems and functions are defined.
Proposals
TwoPointBVPFunction: Should take 2 residuals,
residuala
to store the residual dependent onua
and similarly forub
len(residuala)
&len(residualb)
? If so, then we can simply slice the residual at a specific point and still maintain the current API.bc
dependence onua
andub
. So we won't have to do sparsity detection and can manually reorder the Jacobian Matrix to provide a fast path compared to standard BVPsbc
has no5
argument function, we construct a regular BVProblem?Introduce a
BVPFunction
. This allows us to provide things likejac_prototype
and evenjac
and similar stuff.ODEFunction
but it might be better to have a specific function for this.Allow
bc
to be out of place (if we want to use AD through it peacefully). I see two options here:f
is IIP thenbc
has to be IIP and similar for OOPf
.f
andbc
to be independent, which means we will have to do moreisinplace
checks but also provides a smoother end-user experience.Implemented Features
cc @ChrisRackauckas @ErikQQY @EthanDecleyn