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

Differences with ImplicitDifferentiation.jl #2

Open
gdalle opened this issue May 3, 2022 · 2 comments
Open

Differences with ImplicitDifferentiation.jl #2

gdalle opened this issue May 3, 2022 · 2 comments

Comments

@gdalle
Copy link

gdalle commented May 3, 2022

Hi there! Glad to see that differentiation of implicit functions is a hot topic 😉
I am also developing a package for that purpose: https://github.com/gdalle/ImplicitDifferentiation.jl
Maybe we should join forces instead of duplicating the work?

@tpapp
Copy link
Owner

tpapp commented May 4, 2022

Thanks for reaching out. I agree that we should not duplicate work, and your package is very neatly written so I would be happy to contribute.

This package is currently an experiment for the following:

  1. conceptually, given an x::AbstractVector, map to a "model" m = p(x) and then f(p) (eg scalar), but x may never be constructed, we work with the opaque object p

  2. the mapping is defined by solving an implicit function g(p, y) = 0 for y(p), and then f(p) = h(p, y)

  3. the supported interface is
    A. calculating f(x) and f'(x) from p, pretending we map from x
    B. translating the p corresponding to x by d to p2 = m(x .+ d), again without necessarily constructing x .+ d. This allows reusing y(p) + dy/dx * d as an initial guess for the iterative solver in the condition.

Currently, I am working on refining the interface, while using this in an actual research project, so this repo is for fast experimentation. I would recommend that once I am done, we assess what can be merged and decide how to proceed.

@gdalle
Copy link
Author

gdalle commented May 4, 2022

Thanks for your answer! Not sure I understand it entirely but I'll let you work on it, just ping me when you reach a stable state :)
Btw, Mohamed and I will present ImplicitDifferentiation.jl at JuliaCon (if it gets accepted), so maybe we can chat then

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

No branches or pull requests

2 participants