On Fri, Jan 16, 2009 at 6:58 AM, Tim Kroeger <span dir="ltr">&lt;<a href="mailto:tim.kroeger@cevis.uni-bremen.de">tim.kroeger@cevis.uni-bremen.de</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Dear PETSc team,<br>
<br>
If I create a vector using VecCreateGhost() and then query the local size using VerGetLocalSize(), will the resulting number then include the number of ghost values or not? &nbsp;In either case, how can I ask a vector about the number of ghost values that are stored locally?</blockquote>
<div><br>No, it will have the local size without ghosts. You can get the number of ghosts from the size of the local form VecGhostGetLocalForm()<br>or from the size of the LocalToGlobalMapping.<br>&nbsp;</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
I assume that if I know this number, I can use the ISLocalToGlobalMapping*() functions to get the global indices of the ghost values.<br>
<br>
I also assume that the values supplied by VecGetOwnershipRange() do not include ghost cells (since it wouldn&#39;t be a consecutive range otherwise).</blockquote><div><br>Yes.<br><br>&nbsp;&nbsp; Matt<br>&nbsp;</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Are these assumptions correct?<br>
<br>
(My conjecture is that VecGetLocalSize() does include the ghost cells<br>
while I can get the number without the ghost cells by subtracting the<br>
two numbers that VecGetOwnershipRange() supplies.)<br>
<br>
Best Regards,<br>
<br>
Tim<br><font color="#888888">
<br>
-- <br>
Dr. Tim Kroeger<br>
<a href="mailto:tim.kroeger@mevis.fraunhofer.de" target="_blank">tim.kroeger@mevis.fraunhofer.de</a> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Phone +49-421-218-7710<br>
<a href="mailto:tim.kroeger@cevis.uni-bremen.de" target="_blank">tim.kroeger@cevis.uni-bremen.de</a> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Fax &nbsp; +49-421-218-4236<br>
<br>
Fraunhofer MEVIS, Institute for Medical Image Computing<br>
Universitaetsallee 29, 28359 Bremen, Germany<br>
<br>
</font></blockquote></div><br><br clear="all"><br>-- <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>