<div dir="ltr"><div dir="ltr">On Wed, Nov 10, 2021 at 11:45 PM Eric Chamberland <<a href="mailto:Eric.Chamberland@giref.ulaval.ca">Eric.Chamberland@giref.ulaval.ca</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div>
<p>Hi Matthew,</p>
<p>I have joined the ex44.c example so you can see that we see.</p>
<p>The problem is about the "f" field number which I can't see any clue in the documentation to what to put there... We are missing some information maybe written elsewhere?</p>
<p>I have tried 3 different calls (lines 180-182) with comments aside:
</p>
<p> //ierr = DMSetBasicAdjacency(ddm, PETSC_TRUE, PETSC_FALSE); CHKERRQ(ierr); //This works: it give only 2 cells for the overlap
//ierr = DMSetAdjacency(ddm, 0, PETSC_TRUE, PETSC_FALSE); CHKERRQ(ierr); //This works too, but why do I have to use field #0 ??? Is it a convention?
ierr = DMSetAdjacency(ddm, PETSC_DEFAULT, PETSC_TRUE, PETSC_FALSE); CHKERRQ(ierr); //This does not works: it give 3 cells for the overlap instead of 2.</p></div></blockquote><div>Okay, I will fix the docs. I will run it, but I think I see what is happening here. The default is used _only_ when no fields are defined.</div><div>This is to support the case of just using Plex without any field definitions. Once you define fields, we let you have a different adjacency</div><div>for each field, so that Jacobian layout can be customized. However, what is used for topology then? Right now, I believe it is field 0.</div><div>It sounds like I need a flag to tell me whether the user set something, so we can have better defaults. <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><p>
</p>
<p style="margin:0px;text-indent:0px">Also, do you think your gitlab/knepley/fix-plex-g2n branch will find it's way into next or main? ;)</p></div></blockquote><div><br></div><div>Put in the MR today.</div><div><br></div><div> Thanks,</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>
<p style="margin:0px;text-indent:0px">
</p>
<p style="margin:0px;text-indent:0px">Thanks,</p>
<p style="margin:0px;text-indent:0px">Eric</p>
<p style="margin:0px;text-indent:0px">
</p>
<p></p>
<div>On 2021-11-10 3:26 p.m., Matthew
Knepley wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">Okay, so the PETSC_DEFAULT one is what is used for
topology. There are two separate uses for adjacency info.
<div class="gmail_quote">
<div>First, for this kind of topological extension, and the
second is for calculating Jacobians. You should be able to
see</div>
<div>the difference between FEM and FVM in just the case of a
2x2 mesh where each process gets 1 cell. With FEM,</div>
<div>the overlap is the whole mesh, whereas with FVM it leaves
out the diagonal partner.</div>
<div><br>
</div>
<div> Thanks,</div>
<div><br>
</div>
<div> Matt</div>
</div>
</div>
</blockquote>
<br>
</div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>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</div><div><br></div><div><a href="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div></div></div>