Skip to content
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

fix: fix initialization with defaults dependent on indepvar #2820

Merged
merged 1 commit into from
Aug 8, 2024

Conversation

AayushSabharwal
Copy link
Member

@AayushSabharwal AayushSabharwal commented Jun 26, 2024

Close #2799

Checklist

  • Appropriate tests were added
  • Any code changes were done in a way that does not break public API
  • All documentation related to code changes were updated
  • The new code follows the
    contributor guidelines, in particular the SciML Style Guide and
    COLPRAC.
  • Any new documentation only uses public API

Additional context

Add any other context about the problem here.

@AayushSabharwal AayushSabharwal force-pushed the as/defaults-indepvar branch 3 times, most recently from 257cb77 to 7565795 Compare July 1, 2024 10:40
@hersle
Copy link
Contributor

hersle commented Aug 6, 2024

I think the only problem is that t should not be substituted for DDEs. Same as in #2877.

@AayushSabharwal
Copy link
Member Author

Thank you! I never would've found that

@AayushSabharwal
Copy link
Member Author

Is there any way to check if an ODESystem represents a DDE?

@hersle
Copy link
Contributor

hersle commented Aug 7, 2024

From what I understand in test/dde.jl, it is not possible to tell at the system level; only the problem level (since DDE systems are ODESystems, but DDE problems are DDEProblems).

Maybe process_DEProblem(constructor, ...; symbolic_u0, ...) could check if constructor isa DDEFunction || constructor isa SDDEFunction, and if so pass t0 = nothing to get_u0*()? Alternatively, it looks to me like symbolic_u0 = true is passed if (and only if) the system/problem is a (S)DDE, so maybe it could check if symbolic_u0 instead?

@hersle
Copy link
Contributor

hersle commented Aug 7, 2024

Nice. This looks good now?

@ChrisRackauckas ChrisRackauckas merged commit 1482786 into SciML:master Aug 8, 2024
23 checks passed
@AayushSabharwal AayushSabharwal deleted the as/defaults-indepvar branch August 8, 2024 11:30
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.

Cannot (re)make problems with defaults involving the independent parameter
3 participants