I am disappointed that once again a new version (13.1) of Mathematica is issued and the periodic boundary condition errors of NDSolve have not been corrected. The examples in the documentation are also wrong. I have been reporting this for several years and every year you promise that you will fix it. This experience has shaken my faith in Wolfram and Mathematica.
Dear Marc,
Here is a suggested answer from the developers.
Still disappointing that this has not been fixed in Version 13.2, December 2022. This issue has existed for years. Comsol handles this situation with little aggravation. The two unit cell approach above was neat and clever but doubles or more the computational load Thank you.