<div dir="ltr"><div><div>Hello,<br><br></div>I tried using periodic BC (in y-direction) for a 2D thermal conduction problem (Temperature gradient was imposed only in x-direction). I found that the temperature at the y-boundary drops rapidly even though there is no gradient present.<br></div><div>I tracked down the routine (gr_hypreApplyBcToFace) responsible for applying the BC for HYPRE matrix. Here appropriate modification to the Bmatrix is made to implement Dirichlet, Vacuum and other BC. <br><br>I was wondering if there could be a quick-fix to get the wraparound solution variables to modify Bmatrix, i.e. a way to access appropriate neighbors (blocks) that contain the periodic BC.<br><br></div><div>Thanks,<br></div><div>Nitesh<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Aug 31, 2015 at 1:53 PM, Klaus Weide <span dir="ltr"><<a href="mailto:klaus@flash.uchicago.edu" target="_blank">klaus@flash.uchicago.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Fri, 28 Aug 2015, Evan Scannapieco wrote:<br>
<br>
> I am wondering if anyone has had success implementing conduction with the unsplit solver with periodic boundary conditions.<br>
><br>
><br>
><br>
> HYPRE/Grid_advanceDiffusion says only OUTFLOW, VACUUM, and DIRICHLET are<br>
> supported, but I would think that, at least in principle, periodics<br>
> would be easy as there is nothing special to do on boundaries of the<br>
> box, just treat them the same as other block boundary. I would<br>
> appreciate input from anyone who has tried this.<br>
<br>
</span>Evan,<br>
<br>
Although we have never tried periodic boundaries with<br>
Grid_advanceDiffusion at the Flash Center AFAIK (thus cannot claim that<br>
it's supported), my expectation is that this should just work.<br>
<br>
Or at least, it MIGHT just work. At the level of the routines under<br>
GridSolvers/HYPRE (which basically act as an adapter between FLASH and<br>
HYPRE), periodic boundaries should not even be visible as such: the code<br>
should handle the coupling of local cells to cells in neighboring blocks<br>
the same way, whether these neighbors are adjacent directly or across a<br>
wrapped-around periodic boundary. (Note I am referring to the "paramesh"<br>
case, not "UG".)<br>
<br>
As long as the HYPRE matrix that the adapter constructs and ultimately<br>
passes to HYPRE for solving stays sane (does not become singular, stays<br>
symmetric if you are using HYPRE_PCG as your gr_hypreSolverType, etc.),<br>
everything should work as before.<br>
<br>
If you try this, please let us know how it goes!<br>
<span class="HOEnZb"><font color="#888888"><br>
Klaus<br>
<br>
<br>
</font></span></blockquote></div><br></div>