Skip to content

Firedrake assemble of bilinear form and Boundary conditions question. #3948

Discussion options

You must be logged in to vote

There's a couple of things to say here. The direct answer is that if you want the reduced global matrix then you need to use RestrictedFunctionSpace to create test and trial spaces restricted to the non-constrained dofs. If you assemble a matrix or residual based on those then you'll get the restricted matrix.

The second thing is that you seem to be hand-rolling a Firedrake-ml coupling. We actually already have those for Pytorch and JAX, and you could use the same template to create solutions for other frameworks. The coupling code is in https://www.firedrakeproject.org/firedrake.ml.html and there's an arXiv paper about it at: https://arxiv.org/pdf/2303.06871

In this case, I don't think y…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@MariosChristop
Comment options

Answer selected by MariosChristop
Comment options

You must be logged in to vote
1 reply
@dham
Comment options

dham Jan 5, 2025
Maintainer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants