VecSum#
Computes the sum of all the components of a vector.
Synopsis#
#include "petscvec.h"
PetscErrorCode VecSum(Vec v, PetscScalar *sum)
Collective
Input Parameter#
v - the vector
Output Parameter#
sum - the result
See Also#
Level#
beginner
Location#
Examples#
src/tao/pde_constrained/tutorials/hyperbolic.c
src/tao/constrained/tutorials/tomographyADMM.c
src/tao/unconstrained/tutorials/spectraladjointassimilation.c
src/ts/tutorials/ex9.c
src/vec/vec/tutorials/ex13.c
src/tao/pde_constrained/tutorials/elliptic.c
src/ts/tutorials/extchem.c
src/dm/tutorials/ex2.c
src/ksp/ksp/tutorials/ex59.c
src/vec/vec/tutorials/ex18.c
Implementations#
VecSum_SeqKokkos() in src/vec/vec/impls/seq/kokkos/veckok.kokkos.cxx
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages