> On Jan 21, 2015, at 12:43 PM, Grischa Jacobs <[email protected]> wrote:
> 
> Hi,
> 
> I don't understand the concept with local and global vec's in petsc when it 
> come to DMDAVecGetArray and VecGetValues. I'm creating some DMDA Vec in 
> parallel which works well. Now I want to access certain non local values of 
> my Vec without receiving the whole global array (will not fit into my main 
> memory) on each processor.
> 
> Is there something I'm getting wrong? In the documentation of VecGetValues it 
> is written "Gets values from certain locations of a vector. Currently can 
> only get values on the same processor".

   You want to use VecScatterCreate() to create a scatter that provides for 
each process the values that it wants. Once you have obtained the values 
locally then you use VecGetArray() on that process to access the values you 
want.

   Barry

> 
> thx, Pete
> 

Reply via email to