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

Sample mesh manager wrongly (?) assigns boundary labels to boundary #275

Open
JacobLotz opened this issue Feb 22, 2024 · 3 comments
Open
Assignees
Labels

Comments

@JacobLotz
Copy link
Collaborator

Somehow SampleMeshManager seems to assign a boundary attribute of 1 to element boundaries in the domain. These are not a part of the boundary specified in the mesh. I think these are or 1) the element boundaries of the sample mesh or 2) elements on the boundary between partitions corresponding to MPI groups or 3) a combination of both.
I have verified that the boundary attribute is specified correctly in the input mesh and used correctly in the non-sampled (full order model) finite element space.

The result is that the boundary condition I have specified for boundary attribute 1 is applied randomly in the domain. I encountered this problem in a 3D problem and I did not see it in 2D problems (although it might be occurring there as well).
Is this a known problem? Ping @dylan-copeland

@JacobLotz
Copy link
Collaborator Author

BTW. I think that a work around for me would be to specify boundary attribute 1 to a dummy boundary in the original mesh and not specify a boundary condition to it.

@dylan-copeland
Copy link
Collaborator

Hi @JacobLotz, thanks for raising this issue. Setting boundary attributes on a sample mesh is tricky, because the domain is smaller for the sample mesh than the original mesh. This is a known issue which has not been resolved, because there is no general way to set boundary attributes that will work for all cases. In other words, boundary attributes may need to be defined in a way dependent on the application.

For example, in Laghos, see SetBdryAttrForVelocity and SetBdryAttrForVelocity_Cartesian in
https://github.com/CEED/Laghos/blob/rom/rom/laghos_rom.cpp
I determine boundary elements and set their attributes based on some geometric definitions.

Since each application may need to define boundary attributes in its own way, I suppose the best we can do is to make it more user-friendly to do that, without automating anything. Maybe SampleMeshManager could take an input parameter for the boundary attribute to be applied to boundary elements in the interior of the original mesh. Those interior boundary elements may need different attributes set in a customized way, but at least marking them as interior may be useful as a first step. A customized post-processing step may still be necessary to change those interior boundary attributes. Would this be helpful for you?

@JacobLotz
Copy link
Collaborator Author

Hi @dylan-copeland, thanks for your explanation and examples! I will try to find a similar workaround.

I will leave this issue open for reference for others encountering similar issues.

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

No branches or pull requests

2 participants