#include "petscvec.h" PetscErrorCode VecCreateShared(MPI_Comm comm,PetscInt n,PetscInt N,Vec *v)
|comm||- the MPI communicator to use|
|n||- local vector length (or PETSC_DECIDE to have calculated if N is given)|
|N||- global vector length (or PETSC_DECIDE to have calculated if n is given)|
|vv||- the vector|
Use VecDuplicate() or VecDuplicateVecs() to form additional vectors of the same type as an existing vector.