# PetscRandom
Abstract PETSc object that manages generating random numbers 
## Synopsis
```
typedef struct _p_PetscRandom *PetscRandom;
```



## See Also
 `PetscRandomCreate()`, `PetscRandomGetValue()`, `PetscRandomType`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/include/petscsystypes.h.html#PetscRandom">include/petscsystypes.h</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/classes/random/tutorials/ex2.c.html">src/sys/classes/random/tutorials/ex2.c.html</A><BR>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/include/petsc/private/randomimpl.h.html#_p_PetscRandom">_p_PetscRandom in include/petsc/private/randomimpl.h</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/include/petscsystypes.h)


[Index of all Sys routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
