[petsc-users] Accessing non-local values of a vector

Najeeb Ahmad nahmad16 at ku.edu.tr
Mon Jun 18 09:10:11 CDT 2018


Hi all,

I am a novice user and I am trying to write my first project in PETSc. In
my code, I need to get vector values that may be residing on other
processes. I noticed that VecGetValues can get values on the same
processor.  For instance, I need a calculation like this:

temp = (dy(i) + dy(i + xmax));           /// xmax is length along x -
direction

where dy(i + xmax) may be on another processes. What is the best way to
accomplish this?

Thanks

-- 
*Najeeb Ahmad*


*Research and Teaching Assistant*
*PARallel and MultiCORE Computing Laboratory (ParCoreLab) *

*Computer Science and Engineering*
*Koç University, Istanbul, Turkey*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180618/6ddcc046/attachment.html>


More information about the petsc-users mailing list