<div dir="ltr">On Thu, Aug 15, 2013 at 1:30 AM, 丁老师 <span dir="ltr"><<a href="mailto:ztdepyahoo@163.com" target="_blank">ztdepyahoo@163.com</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial">
I want to know <br>1. What is the relationship between Vhat and LocalVhat. Is the LocalVhat a copy of the Vhat plus the Ghost values. I think the LocalVhat will consume more memeory than the Vhat, am i right?<br></div></div>
</div></div></blockquote><div><br></div><div>No, the reuse the same memory.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="line-height:1.7;font-size:14px;font-family:arial">
<div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial">2. can i direct call VecGetArrary to the Vhat if i do not operate on the ghost value.<br>
</div></div></div></div></blockquote><div><br></div><div>Yes.</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 style="line-height:1.7;font-size:14px;font-family:arial">
<div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial"></div></div><span title="neteasefooter"><span></span></span></div>
    Vec Vhat;<br>    Vec LocalVhat;<br>    double* VhatVec;<br><br>  VecCreateGhost(PETSC_COMM_WORLD,aMesh->Nx*aMesh->Ny/Commsize,PETSC_DECIDE,aMesh->nghosts,&aMesh->ghosts[0],&Vhat);     &nb
 
 sp; <br>    VecGhostGetLocalForm(Vhat,&LocalVhat);<br>    VecGhostUpdateBegin(Vhat,INSERT_VALUES,SCATTER_FORWARD);<br>    VecGhostUpdateEnd(Vhat,INSERT_VALUES,SCATTER_FORWARD);  <br><span title="neteasefooter"><span></span></span></div>
<br><br><span title="neteasefooter"><span></span></span></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
</div></div>