<div dir="ltr">Hi,<div><br></div><div>I have some questions about the differences between distributed local and global vectors that are created using the same DM.</div><div><ol><li>I used a local vector for 'x' in the KSPSolve function, and I got a size mismatch error (due to extra ghost points on the local vector). So I had to use a global vector to perform the linear solve, and then later copy the values to a local vector to be able to perform finite-difference stencil-type operations. This doubles my memory usage. Is there a way to use this without the extra storage? </li>
<li>When I use VecView to print the vectors to file, the global vector gets printed in full, but only the local values on process 0 are printed for a local vector. </li><li>Should I assume that I always pass only global vectors to PETSc functions, and use local vectors only when I perform the stencil operations?</li>
</ol><div>Thank you,</div></div><div>Anush</div></div>