-
Notifications
You must be signed in to change notification settings - Fork 51
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 divergence cleaning when a model has no real boundaries #269
Conversation
…ple a structure which has only periodic boundaries
palace/linalg/divfree.cpp
Outdated
MPI_Comm_split(comm, color, Mpi::Rank(comm), &split_comm); | ||
if (split_comm != MPI_COMM_NULL && Mpi::Root(split_comm)) |
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.
So there's only one dof on each processor with more than one dof correct?
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.
Yeah this was a silly overcomplication, thanks for pointing this out. Simplified in ee3dbd7.
Original/Duplicate pair for periodic boundary No need for div free operator after awslabs#269: it doesn't fail when it is triply periodic but it cannot handle partially periodic meshes
Original/Duplicate pair for periodic boundary No need for div free operator after awslabs#269: it doesn't fail when it is triply periodic but it cannot handle partially periodic meshes
This avoids solving a singular Laplace problem when calculating the scalar potential for a model with no real boundaries. For example, this can be observed by printing the output of divergence-free projection linear solve for the cavity example with PMC boundaries. After this PR, the divergence-free solves actually converge normally in a few iterations and the eigensolve converges as well.
Correctly handles the case of some subdomains having potentially no true dofs and just enforces a potential = 0 on the processor of lowest rank with some non-zero number of local true dofs.