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
Introduce internal::MatrixFreeFunctions::ConstraintInfo #13519
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kronbichler As discussed, I have copied together the most relevant functions to be able to use them in MGTwoLevelTransfer
. This is not a perfect solution and should be regarded as intermediate step, but should give us a feeling what to generalize in the other classes.
} | ||
|
||
void | ||
read_dof_indices( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function and the next one are adopted from DoFInfo
and MatrixFree
.
|
||
template <typename T, typename VectorType> | ||
void | ||
read_write_operation(const T & operation, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This and the next one are adopted from FEEvaluationBase
.
} | ||
|
||
void | ||
finalize() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A difference to the setup in the original code is that I am first collecting everything in vectors of vectors and after that convert them to CRS data structures. I do this to put the data to the right position during the cell loop in the setup of the global-coarsening transfer. But what could do is to loop over all cells category by category or alternatively to sort the data in a second step. Both needs some more involved refactoring in MGTwoLevelTransfer
so that I would like to postpone this to a follow-up PR!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that makes sense. In any case, this looks like a good intermediate step what could later be unified with how FEEvaluation
/DoFInfo
treats this case with one set of code.
/rebuild |
c4a13d0
to
eb907a7
Compare
@kronbichler I have split up the declaration and interpolation and have added a test. |
def708e
to
ccb8c1d
Compare
ccb8c1d
to
653832d
Compare
Add dummy test
653832d
to
d3ea260
Compare
A class that allows to efficiently evaluate constraints in matrix-free loops in user codes. The first application is the global-coarsening transfer operator in #13520.