# PetscDT: Discretization Technology in PETSc#

This chapter discusses the low-level infrastructure which supports higher-level discretizations in PETSc, which includes things such as quadrature and probability distributions.

## Quadrature#

## Probability Distributions#

A probability distribution function (PDF) returns the probability density at a given location \(P(x)\), so that the probability for an event at location in \([x, x+dx]\) is \(P(x) dx\). This means that we must have the normalization condition,

where \(Omega\) is the domain for \(x\). In plain language, this means that something must happen in our domain. It also requires that the PDF must have units which are the inverse of the volume form \(dx\), meaning that it is homogeneous of order \(d\) under scaling

We can check this using the normalization condition,

The cumulative distribution function (CDF) is the incomplete integral of the PDF,

where \(x_-\) is the lower limit of our domain. We can work out the effect of scaling on the CDF using this definition,

so the CDF itself is scale invariant and unitless.

We do not add a scale argument to the PDF in PETSc, since all variables are assuming to be dimensionless. This means that inputs to the PDF and CDF should be scaled by the appropriate factor for the units of \(x\), and the output can be rescaled if it is used outside the library.