petsc-3.7.1 2016-05-15
Report Typos and Errors

# VecCreateShared

Creates a parallel vector that uses shared memory.

### Synopsis

    #include "petscvec.h"
    PetscErrorCode  VecCreateShared(MPI_Comm comm,PetscInt n,PetscInt N,Vec *v)

### Input Parameters

comm -the MPI communicator to use Many br
n -local vector length (or PETSC_DECIDE to have calculated if N is given) Many br
N -global vector length (or PETSC_DECIDE to have calculated if n is given) Many br

### Output Parameter

vv -the vector Many br

Collective on MPI_Comm Many br

### Notes

Currently VecCreateShared() is available only on the SGI; otherwise, Many brthis routine is the same as VecCreateMPI(). Many br

Use VecDuplicate() or VecDuplicateVecs() to form additional vectors of the Many brsame type as an existing vector. Many br

Many br

### See Also

VecCreateSeq(), VecCreate(), VecCreateMPI(), VecDuplicate(), VecDuplicateVecs(),
VecCreateGhost(), VecCreateMPIWithArray(), VecCreateGhostWithArray() Many br

Level:advanced
Location:src/vec/vec/impls/shared/shvec.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/vec/vec/examples/tutorials/ex1.c.html
src/vec/vec/examples/tutorials/ex11.c.html
src/vec/vec/examples/tutorials/ex1f.F.html
src/vec/vec/examples/tutorials/ex11f.F.html
src/snes/examples/tutorials/ex5s.c.html