#include "petscvec.h" PetscErrorCode VecCreateSeqWithArray(MPI_Comm comm,PetscInt bs,PetscInt n,const PetscScalar array[],Vec *V)Collective on MPI_Comm Many br
comm | - the communicator, should be PETSC_COMM_SELF Many br | |
bs | - the block size Many br | |
n | - the vector length Many br | |
array | - memory where the vector elements are to be stored. Many br |
If the user-provided array is NULL, then VecPlaceArray() can be used Many brat a later stage to SET the array for storing the vector values. Many br
PETSc does NOT free the array when the vector is destroyed via VecDestroy(). Many brThe user should not free the array until the vector is destroyed. Many br
Many br
Level:intermediate
Location:src/vec/vec/impls/seq/bvec2.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages