Dear  Wu, <br><br>This might help:<br><br><a href="http://www.mcs.anl.gov/petsc/documentation/faq.html#mpi-vec-to-seq-vec">http://www.mcs.anl.gov/petsc/documentation/faq.html#mpi-vec-to-seq-vec</a><br><h3><a name="mpi-vec-to-seq-vec">How do I collect all the values from a parallel PETSc vector into a sequential vector on each processor?</a></h3>
<br><h3><a name="mpi-vec-to-mpi-vec">How do I collect all the values from a parallel PETSc vector into a vector on the zeroth processor?</a></h3><h3><a name="mpi-vec-to-mpi-vec"></a></h3><br>Regards,<br>Zhengyong<br><br><div class="gmail_quote">
On Fri, Aug 17, 2012 at 7:13 PM, Panruo Wu <span dir="ltr"><<a href="mailto:pwu@mymail.mines.edu" target="_blank">pwu@mymail.mines.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Dear PetSc developers and users,<div><br></div><div>I want to access a Petsc Vec v at index n whose value</div><div>is not necessarily stored in the same processor.</div><div>I noted that the current VecGetValues cannot do that.  Do you have</div>

<div>any suggestions on how I can access v(n) from arbitrary </div><div>processors(in the same communicator of course)?</div><div><br></div><div>Thanks,</div><div><br></div><div>best wishes,</div><div>Panruo Wu</div>
</blockquote></div><br><br clear="all"><br>-- <br>Zhengyong Ren<br>AUG Group, Institute of Geophysics<br>Department of Geosciences, ETH Zurich<br>NO H 47 Sonneggstrasse 5<br>CH-8092, Zürich, Switzerland<br>Tel: +41 44 633 37561<br>
e-mail: <a href="mailto:zhengyong.ren@aug.ig.erdw.ethz.ch">zhengyong.ren@aug.ig.erdw.ethz.ch</a><br>Gmail: <a href="mailto:renzhengyong@gmail.com">renzhengyong@gmail.com</a><br>