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
Speed-up RBF matrix assembly #1320
Conversation
We should consider using Eigen::Index for the iteration instead of hard coding the type. |
Thinking about it: how about using |
The problem with using auto in for loops is that normally the end value has the desired type, but you need the type in the initializer of the for construct. Defining the end outside the loop and then using decltype is one option. |
Ah I see (and didn't know that). Then I will use the boost solution, thanks! |
For the sake of completeness let me add that we cannot exceed |
@fsimonis had a brief look at it. |
Main changes of this PR
Speed up matrix assembly of the RBF matrices by a factor of ~2.2 for compute intensive RBFs and ~6 for simple RBFs (measured for matrix A).
Motivation and additional information
The matrix assembly is a considerable factor in the
computeMapping
step (depending on the system size). For small systems, the assembly step is dominant, for big system, the decomposition is dominant. These changes lead for thecomputeMapping
step in a speedup of ~2.2 - 6.2 (for 150 vertices) to ~1.13 - 1.06 (for 13.300 vertices). Therefore, the interesting region for partition of unity mapping is accelerated considerably. In addition, there are several considerations to improve the decomposition strategies as well, which will make the overall relevance of an improved assembly more significant (see eg davidscn#3 ).Depends on #1319.
Author's checklist
make changelog
if there are user-observable changes since the last release.make format
to ensure everything is formatted correctly.Reviewers' checklist