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

Improve Rosenbrock finite difference by swapping dt with J #1611

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

ChrisRackauckas
Copy link
Member

src/derivative_utils.jl Outdated Show resolved Hide resolved

# This is for numerical differentiation cache correctness
# Requires Newton methods are FSAL
nlsolver.cache.du1 .= integrator.fsalfirst
Copy link
Member

Choose a reason for hiding this comment

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

Right, all the methods are programmatically FSAL for dense outputs, we should use it well. BTW, can we simply set integrator.fsalfirst === nlsolver.cache.du1? Will that lead to incorrectness?

Copy link
Member Author

Choose a reason for hiding this comment

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

du1 can get overwritten/changed, for example in the central differencing method, so it's not always correct.

@ChrisRackauckas ChrisRackauckas force-pushed the difftype branch 2 times, most recently from ebc2d1b to 328ca32 Compare April 2, 2022 01:15
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.

Do the autodiff options have any meaning when the Jacobi matrix is provided?
2 participants