Thank you both for the suggestions.

Periodic faces should be treated as interior faces and then the flag 
MeshWorker::assemble_own_interior_faces_once should apply and only one of the 
periodic face pairs should be used for assembly, even though physically they 
are different faces.

I want to make sure this is happening, and will write some small test code.

The code of mesh_loop is checking about periodicity, but the logic is not clear 
to me from reading the code.

I have used these features in a DG code (and I am sure many others also) and it 
seems to work as expected. But I do observe some issues on gmsh grids when I 
use periodicity, but maybe it is not related to MeshWorker. I will post a 
separate issue on this.

best
praveen

> On 4 Mar 2026, at 2:19 AM, Luca Heltai <[email protected]> wrote:
> 
> Dear Praveen, 
> 
> to add to what Wolfgang said: I implemented the first version of 
> MeshWorker::mesh_loop function, and at the time periodicity was not 
> supported. Unless someone else implemented the logic for periodic faces later 
> on, I would assume that they are treated as boundary faces.
> 
> We’d of course be very happy to review a patch that adds the correct 
> behaviour for periodic faces! 
> 
> :)
> 
> L
> 
>> Il giorno 3 mar 2026, alle ore 12:09, Praveen C <[email protected]> ha 
>> scritto:
>> 
>> Dear all
>> 
>> Suppose I have a 2d square domain with periodicity in both directions.
>> 
>> I loop over faces with MeshWorker::mesh_loop, specify assemble_flags as below
>> 
>>    auto assemble_flags = MeshWorker::assemble_own_cells;
>>      assemble_flags |= MeshWorker::assemble_own_interior_faces_once;
>>      assemble_flags |= MeshWorker::assemble_ghost_faces_once;
>> 
>> Suppose face1 and face2 are periodic pairs of faces. Will the above 
>> mesh_loop ensure that only one of face1 or face2 is visited during assembly ?
>> 
>> Or will it visit both periodic face pairs ?
>> 
>> thanks
>> praveen
>> 
>> -- 
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see 
>> https://groups.google.com/d/forum/dealii?hl=en
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "deal.II User Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> To view this discussion visit 
>> https://groups.google.com/d/msgid/dealii/CAEvUdMKpZWWcgiwrwZdF8XJs7xTaywvBbHvFv4Dv3AmGa2Z2bg%40mail.gmail.com.
> 
> -- 
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> --- 
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To view this discussion visit 
> https://groups.google.com/d/msgid/dealii/C2CDF68B-358A-4E19-B3C5-FD763D93D7BF%40gmail.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/dealii/FC044ECE-4FB2-4FB3-A3B4-F07FBFA7350E%40gmail.com.

Reply via email to