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

Add example using preconditioning. #8

Open
patrick-kidger opened this issue May 28, 2023 · 2 comments
Open

Add example using preconditioning. #8

patrick-kidger opened this issue May 28, 2023 · 2 comments
Labels
documentation Improvements or additions to documentation

Comments

@patrick-kidger
Copy link
Owner

No description provided.

@patrick-kidger patrick-kidger added the documentation Improvements or additions to documentation label May 28, 2023
@frederic-bender
Copy link

frederic-bender commented Jul 8, 2024

Hey, I'm using a Newton-GMRES-algorithm for implicitly solving large ODEs, based on Diffrax/Optimistix/Lineax – a pretty awesome set of libraries!

Right now I'm trying to figure out, how to create a Jacobi-preconditioner (or a more advanced one) for matrix-free computations. Using lx.diagonal(...) materializes the Jacobian and therefore is not possible for a vector of length ~500,000. Do you have any idea how to solve this problem?

@patrick-kidger
Copy link
Owner Author

patrick-kidger commented Jul 9, 2024

This depends on the kind of operator you have. A tridiagonal linear operator, for example, can get the diagonal without further materialization!

However it's a classic (sad) fact in autodifferentiation that accessing the diagonal of a Jacobian requires computing the whole Jacobian.

You'll probably need to find a different approach for your problem.

Sorry I couldn't be more help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants