libCEED icon indicating copy to clipboard operation
libCEED copied to clipboard

Jeremy/periodic bps

Open jeremylt opened this issue 3 years ago • 8 comments

jeremylt avatar Jun 07 '21 16:06 jeremylt

Side note, using -dm_plex_box_bd periodic,periodic,periodic sets the boundary cells as periodic rather than the faces, which is annoying when paired with the fact that for bps.c we removed the ability to directly set the number of cells in each direction.

jeremylt avatar Jun 07 '21 19:06 jeremylt

@jeremylt I do not understand the distinction between periodic cells and faces. Maybe I can make the interface easier if I understand.

knepley avatar Jun 07 '21 20:06 knepley

Really, I should have said element instead of cell. But I think I was misunderstanding the information I was seeing.

jeremylt avatar Jun 07 '21 21:06 jeremylt

I rebased my very (!) old branch here. https://gitlab.com/petsc/petsc/-/merge_requests/2178

It makes DMPlexSetClosurePermutationTensor work with periodicity. Maybe we should merge clean and merge that up-front, but the coordinates are still a mess because you have normal coordinates and "localized" coordinates in the elements that wrap.

jedbrown avatar Mar 08 '22 22:03 jedbrown

I want to fix that by making the local space always distinguish and using the sf mapping local to global spaces to tie it back together. Matt says that won't work, but I think I'm going to need to try it and see what breaks.

The solution fields should be managed correctly in the PETSc MR so we could test and merge it, then hack coordinates to make them good enough for us in fluids (@jrwrigh would really like this).

jedbrown avatar Mar 09 '22 00:03 jedbrown

Periodic boundaries work in https://github.com/CEED/libCEED/tree/jrwrigh/fluid_example, which is otherwise rough. I had to remove the DMProjectCoordinates and I hope @knepley can advise on what to do with that failing test case in PETSc because we do need an actual coordinate space at some point once we venture beyond the box with periodicity. https://gitlab.com/petsc/petsc/-/merge_requests/5107

jedbrown avatar Apr 13 '22 17:04 jedbrown

Which test is failing? Is this in an MR?

knepley avatar Apr 13 '22 17:04 knepley

Click through to the MR with failing test that I created and tagged you in. https://gitlab.com/petsc/petsc/-/merge_requests/5107

The question is how to get an FE for the localized space. I still think it's a big mess and we should excise "localized", but if we can't do that yet, we gotta decide how to make the test work.

jedbrown avatar Apr 13 '22 17:04 jedbrown

I'm closing this since we sorted this out in fluids

jeremylt avatar Mar 17 '23 18:03 jeremylt