:orphan:
# VecPointwiseDivide
Computes the component-wise division `w[i] = x[i] / y[i]`.
## Synopsis
```
#include "petscvec.h"
PetscErrorCode VecPointwiseDivide(Vec w, Vec x, Vec y)
```
Logically Collective
## Input Parameters
- ***x -*** the numerator vector
- ***y -*** the denominator vector
## Output Parameter
- ***w -*** the result
## Note
Any subset of the `x`, `y`, and `w` may be the same vector.
## See Also
[](ch_vectors), `Vec`, `VecPointwiseMult()`, `VecPointwiseMax()`, `VecPointwiseMin()`, `VecPointwiseMaxAbs()`, `VecMaxPointwiseDivide()`
## Level
advanced
## Location
src/vec/vec/interface/vector.c
## Examples
src/ksp/ksp/tutorials/ex72.c
src/snes/tutorials/ex13.c
src/tao/constrained/tutorials/tomographyADMM.c
src/tao/pde_constrained/tutorials/elliptic.c
src/tao/pde_constrained/tutorials/parabolic.c
src/tao/tutorials/ex4.c
src/tao/unconstrained/tutorials/burgers_spectral.c
src/tao/unconstrained/tutorials/spectraladjointassimilation.c
src/ts/tutorials/ex50.c
src/vec/vec/tutorials/ex1.c
src/vec/vec/tutorials/ex1f.F90
## Implementations
VecPointwiseDivide_Nest in src/vec/vec/impls/nest/vecnest.c
VecPointwiseDivide_Seq in src/vec/vec/impls/seq/bvec2.c
VecPointwiseDivide_SeqKokkos in src/vec/vec/impls/seq/kokkos/veckok.kokkos.cxx
VecPointwiseDivide_SeqViennaCL in src/vec/vec/impls/seq/seqviennacl/vecviennacl.cxx
---
[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)