# PetscPDFSampleConstant3D
Sample uniformly from a uniform distribution on [-1, 1] x [-1, 1] in 3D 
## Synopsis
```
#include "petscdt.h" 
PetscErrorCode PetscPDFSampleConstant3D(const PetscReal p[], const PetscReal dummy[], PetscReal x[])
```
Not collective


## Input Parameter

- ***p -*** Three uniform variables on [0, 1]



## Output Parameter

- ***x -*** Coordinate in [-1, 1] x [-1, 1] x [-1, 1]





## See Also
 `PetscPDFConstant3D()`, `PetscCDFConstant3D()`, `PetscPDFSampleConstant1D()`, `PetscPDFSampleConstant2D()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/dt/interface/dtprob.c.html#PetscPDFSampleConstant3D">src/dm/dt/interface/dtprob.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/dt/interface/dtprob.c)


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