<div dir="ltr"><div dir="ltr">On Fri, Dec 2, 2022 at 5:16 AM Nicholas Arnold-Medabalimi <<a href="mailto:narnoldm@umich.edu">narnoldm@umich.edu</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 dir="ltr">Hi Petsc Users<br><br>I have become familiar with usage of DMPlexGet(Restore)TransitiveClosure as well as general traversal of the graph using DMPlexGetCone and GetSupport. <br><br>I was wondering if there is a more trivial way to get access to adjacent points of the same Stratum. <br><br>For example, I have an 2D mesh. I have identified the point value of a cell of interest and I would like to get the point value of the surrounding cells. So far the way I get that is I descend a level using GetCone and then for each constituent point (face in this case) call GetSupport (which yields the adjacent cell and the original cell) and discard the original cell. <br><br>Is there a direct function call that achieves this? I've looked a bit into the Adjacency commands but they seem to be more for variable influence (FV or FE) and using them seems to throw an error. <br></div></blockquote><div><br></div><div>It is important to lay out why you want to do this, because it influences the choice of implementation.</div><div><br></div><div>If you just want to discover topology, then doing it using Cone and Support is fine. This is what GetAdjacency is doing underneath.</div><div><br></div><div>However, if you want to repeatedly do this, which most people do for dof traversal, then you should make an index. There are two cases</div><div>of this in Plexx right now, but we could easily have more. GetAdjacency is used to construct the sparsity pattern for the Jacobian, which</div><div>serves as an index. Also GetClosure is used to construct the closure index which we use when setting values since this is a common</div><div>operation in FE.</div><div><br></div><div>What do you want to do with this?</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 dir="ltr">Sincerely<br>Nicholas<br><div><br></div>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div style="font-family:arial;font-size:small"><font color="#000000">Nicholas Arnold-Medabalimi<br><br></font><span style="font-family:sans-serif;font-size:14px">Ph.D. Candidate</span><font color="#000000"><br>Computational Aeroscience Lab<br>University of Michigan</font></div></div></div></div></div></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>