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

Implement MappingDoFVector (ALE) for ElementType::Simplex #634

Open
wants to merge 23 commits into
base: master
Choose a base branch
from

Conversation

nfehn
Copy link
Member

@nfehn nfehn commented Dec 20, 2023

To enable ALE methods for ElementType::Simplex, we need to extend

  1. class MappingDoFVector:
  • function fill_grid_coordinates_vector() (in order to translate a Mapping into a DoFVector)
  • function initialize_mapping_from_dof_vector() (in order to translate a DoFVector into a Mapping)
  1. utility functions in namespace MappingTools:
  • functions initialize_coarse_mappings_from_mapping_dof_vector() to construct coarse mappings of type MappingDoFVector for use in h-multigrid methods
  • There are two functions with this name, differing in the number of arguments. The variant with only one triangulation object for all h-levels is not relevant for ElementType::Simplex (@peterrum)?

@dominiktassilostill FYI

@nfehn nfehn added ALE Arbitrary Lagrangian-Eulerian formulation simplex simplicial elements multigrid Multigrid implementation labels Dec 20, 2023
@nfehn
Copy link
Member Author

nfehn commented Dec 20, 2023

The first commit shows which places we need to extend / re-implement for simplex by introducing if-else-branches depending on the ElementType and by introducing asserts for element types not supported so far.

@nfehn
Copy link
Member Author

nfehn commented Dec 21, 2023

@kronbichler as discussed in person, the current implementation of MappingDoFVector might be problematic, because dof_handler (and the underlying FE and degree) passed to the function fill_grid_coordinates_vector() (and initialize_mapping_from_dof_vector()) can be independent of the mapping_degree passed to the constructor of MappingDoFVector. I removed the constructor argument and used dof_handler.get_fe().degree instead; the hierarchic/lexicographic indexing becomes a local variable instead of the member variable used previously. Could you please check commits 32efd75 and b6e3210?

@kronbichler
Copy link
Contributor

I had a close look at the code now. I think the new approach looks good. For the simplices, we do not have the equivalent of MappingQCache anyway, so all routines are more expensive. I think the longer-term solution will be to let all mapping-related code use the evaluators of solution fields, but that needs modification in deal.II as well; that is not part of the present PR in either case.

@nfehn
Copy link
Member Author

nfehn commented Jan 15, 2024

@kronbichler thanks for your review.

We need some more refactoring in order to integrate Simplex elements easily without having to touch several classes (see 923958b and 7fbcbe8).

Comment on lines 8 to 9
"DegreeMin": "2",
"DegreeMax": "2",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change was not actually intended and might cause the test to fail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ALE Arbitrary Lagrangian-Eulerian formulation multigrid Multigrid implementation simplex simplicial elements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants