VecPointwiseMax#
Computes the component-wise maximum w[i] = max(x[i], y[i]).
Synopsis#
#include "petscvec.h"
PetscErrorCode VecPointwiseMax(Vec w, Vec x, Vec y)
Logically Collective
Input Parameters#
x - the first input vector
y - the second input vector
Output Parameter#
w - the result
Notes#
Any subset of the x, y, and w may be the same vector.
For complex numbers compares only the real part
See Also#
Vectors and Parallel Data, Vec, VecPointwiseDivide(), VecPointwiseMult(), VecPointwiseMin(), VecPointwiseMaxAbs(), VecMaxPointwiseDivide()
Level#
advanced
Location#
Examples#
src/vec/vec/tests/ex54.c
src/vec/vec/tests/ex69.c
src/mat/impls/diagonal/tests/ex1.c
Implementations#
VecPointwiseMax_Seq() in src/vec/vec/impls/seq/bvec2.c
VecPointwiseMax_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