Skip to main content
`Ctrl`+`K`

# PetscRandom

Abstract PETSc object that manages generating random numbers

## Synopsis

    typedef struct _p_PetscRandom *PetscRandom;

## See Also

`PetscRandomCreate()`, `PetscRandomGetValue()`, `PetscRandomType`

## Level

intermediate

## Location

include/petscsystypes.h

## Examples

src/ksp/ksp/tutorials/ex59.c
src/ksp/ksp/tutorials/ex81.c
src/ksp/ksp/tutorials/ex18.c
src/ksp/ksp/tutorials/ex11.c
src/ksp/ksp/tutorials/ex46.c
src/ksp/ksp/tutorials/ex86.c
src/ksp/ksp/tutorials/ex81a.c
src/ksp/ksp/tutorials/ex60.c
src/dm/tutorials/swarm_ex3.c
src/dm/field/tutorials/ex1.c

## Implementations

_p_PetscRandom in include/petsc/private/randomimpl.h
PetscRandom_CURAND in src/sys/classes/random/impls/curand/curand.c

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages