Vectors: Examples

PETSc vectors (Vec objects) are used to store the field variables in PDE-based (or other) simulations.

Beginner - Basic usage
NORM_1 VecDestroyVecsF90 VecRestoreArray4d
NORM_1_AND_2 VecDuplicate VecRestoreArrayF90
NORM_2 VecDuplicateVecsF90 VecScatter
NORM_FROBENIUS VecExp VecSet
NORM_INFINITY VecGetArray VecSetFromOptions
NORM_MAX VecGetArray4d VecSetValue
NormType VecGetArrayF90 VecSetValueLocal
VECMPI VecGetLocalSize VecSetValues
VECSEQ VecGetOwnershipRange VecSqrt
Vec VecGetOwnershipRanges VecSum
VecAssemblyBegin VecGetSize VecType
VecAssemblyEnd VecGetValues VecView
VecCopy VecLog VecZeroEntries
VecCreate VecPermute
VecDestroy VecRestoreArray
Intermediate - Setting options for algorithms and data structures
VecAXPBY VecLoad VecScatterDestroy
VecAXPBYPCZ VecLoadIntoVector VecScatterEnd
VecAXPY VecMAXPY VecScatterView
VecAYPX VecMDot VecSetLocalToGlobalMapping
VecAbs VecMTDot VecSetLocalToGlobalMappingBlock
VecConjugate VecMax VecSetOption
VecContourScale VecMin VecSetRandom
VecCreateMPI VecNorm VecSetSizes
VecCreateMPIWithArray VecNormalize VecSetType
VecCreateSeq VecReciprocal VecSetValuesBlocked
VecCreateSeqWithArray VecRestoreArrays VecSetValuesBlockedLocal
VecDestroyVecs VecScale VecSetValuesLocal
VecDot VecScatterBegin VecShift
VecDuplicateVecs VecScatterCreate VecStashSetInitialSize
VecEqual VecScatterCreateLocal VecTDot
VecGetArrays VecScatterCreateToAll VecViewFromOptions
VecGetType VecScatterCreateToZero VecWAXPY
Advanced - Setting more advanced options and customization
VecAppendOptionsPrefix VecMTDotEnd VecStashView
VecCreateGhost VecMaxPointwiseDivide VecStrideGather
VecCreateGhostBlock VecNormBegin VecStrideGatherAll
VecCreateGhostBlockWithArray VecNormEnd VecStrideMax
VecCreateGhostWithArray VecPointwiseDivide VecStrideMaxAll
VecCreateShared VecPointwiseMax VecStrideMin
VecDotBegin VecPointwiseMaxAbs VecStrideMinAll
VecDotEnd VecPointwiseMin VecStrideNorm
VecDotNorm2 VecPointwiseMult VecStrideNormAll
VecGetBlockSize VecRegister VecStrideScale
VecGetOptionsPrefix VecRegisterAll VecStrideScaleAll
VecGhostGetLocalForm VecRegisterDestroy VecStrideScatter
VecGhostRestoreLocalForm VecRegisterDynamic VecStrideScatterAll
VecGhostUpdateBegin VecScatterCopy VecSwap
VecGhostUpdateEnd VecSetBlockSize VecTDotBegin
VecMDotBegin VecSetOptionsPrefix VecTDotEnd
VecMDotEnd VecSetUp Vecs
VecMTDotBegin VecStashGetInfo
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
ISInitializePackage PetscMapSetLocalSize VecReplaceArray
PetscMapDestroy PetscMapSetSize VecResetArray
PetscMapGetBlockSize PetscMapSetUp VecRestoreArray1d
PetscMapGetLocalSize VecFinalizePackage VecRestoreArray2d
PetscMapGetRange VecGetArray1d VecRestoreArray3d
PetscMapGetRanges VecGetArray2d VecScatterGetMerged
PetscMapGetSize VecGetArray3d VecScatterRemap
PetscMapInitialize VecInitializePackage VecValid
PetscMapSetBlockSize VecPlaceArray
No deprecated routines

Table of Contents