:orphan:
# VecLog
Replaces each component of a vector by log(x_i), the natural logarithm 
## Synopsis
```
#include "petscvec.h" 
PetscErrorCode VecLog(Vec v)
```
Not Collective


## Input Parameter

- ***v -*** The vector



## Output Parameter

- ***v -*** The vector of logs





## See Also
 `Vec`, `VecExp()`, `VecAbs()`, `VecSqrtAbs()`, `VecReciprocal()`


## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/vec/vec/utils/vinv.c.html#VecLog">src/vec/vec/utils/vinv.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/vec/vec/utils/vinv.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)  
