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 replace_derivative_nodes #360

Merged

Conversation

pbrubeck
Copy link
Contributor

@pbrubeck pbrubeck commented Mar 18, 2025

Fixes firedrakeproject/firedrake#4120

This PR implements coefficient derivatives on more generic ufl types such as Cofunctions.

Inspired from DerivativeRuleDispatcher, the right thing would be

ufl_type = MultiFunction.reuse_if_untouched

Copy link
Contributor

@michalhabera michalhabera left a comment

Choose a reason for hiding this comment

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

This looks correct. But the function has very confusing name. I'd rather call it replace_coefficient_derivative...

@michalhabera michalhabera added this pull request to the merge queue Mar 21, 2025
Merged via the queue into FEniCS:main with commit c484384 Mar 21, 2025
12 checks passed
schnellerhase pushed a commit to schnellerhase/fenics-ufl that referenced this pull request Mar 30, 2025
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.

BUG: ExternalOperator not compatible with LinearVariationalProblem in adjoint mode anymore
2 participants