On Sun, May 6, 2012 at 5:57 PM, Jed Brown <span dir="ltr"><<a href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Now the next round:<div><br></div><div>For semi-coarsening, we used to have stuff like -da_refine_hierarchy_x 1,1,3 -da_refine_hierarchy_y 2,2,1 -da_refine_hierarchy_z 2,2,1. Two changes make this harder now:</div><div><br>

</div><div>1. You essentially got rid of DMRefineHierarchy (it's not called any more), so each call to DMRefine and DMCoarsen have to figure out where they are.</div></blockquote><div><br></div><div>This is a huge mistake. The only way unstructured stuff works is through this interface. That is why I added it</div>
<div><br></div><div>   Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>2. Since the coarse DMs are not reused by PCMG, but instead created again using DMCoarsen, we have to figure out how to reverse the refinement process so that the same coarse grids get reconstructed again.</div>

<div><br></div><div>I added a DMRefineHook so that we can port data the other way and I modified DMCoarsen_DA and DMRefine_DA to not call DMDACreate{1,2,3}d because it eagerly calls DMSetFromOptions before we can set the refinement/coarsen level. Unless someone stops me, I'm also going to add coarsen_{x,y,z} fields to DM_DA because the refinement ratio may have nothing to do with the coarsening ratio.</div>

<div><br></div><div>I have no idea how to expose semi-coarsening through a C API other than to hold the refinement/coarsening path arrays in each DM_DA so that refinement/coarsening steps can be retraced.</div><div><br><div class="gmail_quote">

On Sun, May 6, 2012 at 1:57 PM, Barry Smith <span dir="ltr"><<a href="mailto:bsmith@mcs.anl.gov" target="_blank">bsmith@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<br>
  Fine<br>
<div><div><br>
On May 6, 2012, at 2:44 PM, Jed Brown wrote:<br>
<br>
> Should the refinement level be copied over by DMCoarsen (and the coarsen level be copied by DMRefine)?<br>
><br>
> It's useful for diagnostics to be able to define a universal level. If I use PCMG and -snes_grid_sequence, there is effectively a sequence like<br>
><br>
> DMCreate(,&dm0); // r=0,c=0<br>
> DMRefine(dm0,&dmf); // r=1,c=0<br>
> DMCoarsen(dmf,&dmc); // r=0,c=1<br>
><br>
><br>
> I would like a way to identify dmc as being on the "same level" as dm0.<br>
<br>
</div></div></blockquote></div><br></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener<br>