:orphan:
# VecPointwiseMaxAbs
Computes the component-wise maximum of the absolute values `w[i] = max(abs(x[i]), abs(y[i]))`.
## Synopsis
```
#include "petscvec.h"
PetscErrorCode VecPointwiseMaxAbs(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.
## See Also
[](ch_vectors), `Vec`, `VecPointwiseDivide()`, `VecPointwiseMult()`, `VecPointwiseMin()`, `VecPointwiseMax()`, `VecMaxPointwiseDivide()`
## Level
advanced
## Location
src/vec/vec/interface/vector.c
## Implementations
VecPointwiseMaxAbs_Seq in src/vec/vec/impls/seq/bvec2.c
---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/vec/vec/interface/vector.c)
[Index of all Vec routines](index.md)
[Table of Contents for all manual pages](/manualpages/index.md)
[Index of all manual pages](/manualpages/singleindex.md)