[petsc-users] DAVecGetArray, ghost access
pavel_chuvahov at mail.ru
Thu Apr 29 04:33:49 CDT 2010
Dear PETSc team, all!
I'm involved in developing PETSc-assisted code and recently came across the following problem.
As described in user manual (rev.3.1, p.48), elements of vector that is managed by DA object can be directly accessed by DAVecGetArray(...) and DAVecRestoreArray(...) where the vector is either local or global. Besides, there's written that GHOSTED values can be accessed in this way. It seems to be not applicable for global vectors, but for local ones only.
As far as I understand, it's proposed to get ghosts by creating a new local vector, that contains full local part of global vector plus ghosts. Therefore the memory is just twice we really need, not to mention excessive data coping.
So the question arises. In what way can user get access to ghosted values without creating additional DA local vector?
Best Wishes, Pavel V. Chouvakhov.
More information about the petsc-users