<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Oct 20, 2015 at 2:53 AM, Francesco Caimmi <span dir="ltr"><<a href="mailto:francesco.caimmi@polimi.it" target="_blank">francesco.caimmi@polimi.it</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><u></u>
<div style="font-family:Verdana;font-size:9pt;font-weight:400;font-style:normal">
<p style="margin:0px;text-indent:0px">Dear all,</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">for an application I have in mind I have a domain divided in cells (more or less) and for each cell centroid, say ci, I need  to know which cell centroids are inside a spherical neighbourhood of radius r  centred at ci.</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">Were the centroids placed on regular grid, a typical value for the ratio of r over the grid spacing would be something like 3 or 4.</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">However, since the discrete domain is actually not structured, I am using a DMPlex object to manage the domain. </p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">It is not very clear to me *if* and *how* I can tell the DMPlex to add ghost points for all the points in such a spherical neighbourhood. If I were using  DMDA object I think I could just set the stencil width, but I wasn't able to figure out a corresponding option/procedure for DMPlex (if it exists).</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">Any hint would be really really appreciated.</p></div></blockquote><div><br></div><div>The function that defines grid overlap is here:</div><div><br></div><div>  <a href="https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexdistribute.c?at=master&fileviewer=file-view-default#plexdistribute.c-546">https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexdistribute.c?at=master&fileviewer=file-view-default#plexdistribute.c-546</a></div><div><br></div><div>It calls a routine to define this overlap topologically</div><div><br></div><div>  <a href="https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexdistribute.c?at=master&fileviewer=file-view-default#plexdistribute.c-612">https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexdistribute.c?at=master&fileviewer=file-view-default#plexdistribute.c-612</a></div><div><br></div><div>You would have to modify this function to use a geometric criterion</div><div><br></div><div>  <a href="https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexpartition.c?at=master&fileviewer=file-view-default#plexpartition.c-1470">https://bitbucket.org/petsc/petsc/src/fc309a34c451569cb3041ed38231443f9c022d73/src/dm/impls/plex/plexpartition.c?at=master&fileviewer=file-view-default#plexpartition.c-1470</a></div><div><br></div><div>If you do this, I can put it in as an option.</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-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="font-family:Verdana;font-size:9pt;font-weight:400;font-style:normal">
<p style="margin:0px;text-indent:0px">Best Regards,</p>
<p style="margin:0px;text-indent:0px">-- </p>
<p style="margin:0px;text-indent:0px">Francesco Caimmi</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">Laboratorio di Ingegneria dei Polimeri</p>
<p style="margin:0px;text-indent:0px"><a href="http://www.chem.polimi.it/polyenglab/" target="_blank">http://www.chem.polimi.it/polyenglab/</a></p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">Politecnico di Milano - Dipartimento di Chimica,</p>
<p style="margin:0px;text-indent:0px">Materiali e Ingegneria Chimica “Giulio Natta”</p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px">P.zza Leonardo da Vinci, 32</p>
<p style="margin:0px;text-indent:0px">I-20133 Milano</p>
<p style="margin:0px;text-indent:0px">Tel. <a href="tel:%2B39.02.2399.4711" value="+390223994711" target="_blank">+39.02.2399.4711</a></p>
<p style="margin:0px;text-indent:0px">Fax <a href="tel:%2B39.02.7063.8173" value="+390270638173" target="_blank">+39.02.7063.8173</a></p>
<p style="margin:0px;text-indent:0px"> </p>
<p style="margin:0px;text-indent:0px"><a href="mailto:francesco.caimmi@polimi.it" target="_blank">francesco.caimmi@polimi.it</a></p>
<p style="margin:0px;text-indent:0px">Skype: fmglcaimmi (please arrange meetings by e-mail)</p>
<p style="margin:0px;text-indent:0px"> </p></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">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></div>