I’m wondering that is it possible to apply the periodic boundary condition in more that one direction using DOLFINX_MPC, for example, if I have f(x,y) in [0,1]*[0,1] and I want f(0,y) = f(1,y) and f(x,0)=f(x,1).
In this case, it seems like some master point will the master for more than 1 slave points, can we difine one MPC directly, or we have to define the boundary condition in different direction speratly and apply them one by one.
Is there any demos or instruction about that? Thanks very much!
But I’m still confused about one point that you mentioned in that post. Why do we have to constraint some DOFs twice?
For example, consider an unit square, if we know that one dof is on the right-upp corner, can we just connect it to the left-down dof directly instead of using a nest (I think this is what we did in the old DOLFIN). In this case, all the dofs will only be slaves for up to once, and some dofs will be the master for mutiple times. It there any reason preventing doing this?
You could consider this official demo.
In 2D, the mapping is done as follows: (1) from right to left, (2) from top to bottom, in each case without mapping the corner of master-master surfaces (top right corner) and (3) mapping the top right corner to the bottom left corner.