Purpose

The module HistogramLinearFunction computes (an approximation to) a PDF (probability density function) and a CDF (cumulative distribution function) of a piecewise multi-linear function.

The module internally employs the same algorithm as the ThresholdLinearFunction module to compute the CDF, see there for more details. The PDF the derivative of the CDF and is computed out of the CDF using central differences.

Windows

Default Panel

../../../Modules/ML/MLStochasticCollocation/mhelp/Images/Screenshots/HistogramLinearFunction._default.png

Input Fields

inputFunction

name: inputFunction, type: MLBase

Output Fields

outputCurves

name: outputCurves, type: MLBase

Parameter Fields

Field Index

Apply: Trigger
Auto apply: Bool
Interpolate PDF: Bool
Level: Integer
Number of Points: Integer
Recommended Level: Integer

Visible Fields

Number of Points

name: numPoints, type: Integer, default: 100, minimum: 2

Sets the number of points in which the CDF (and hence also the PDF) is actually computed.

The higher the number, the better are the approximations. But note that in order to get a correct result, it is also required to choose the Level parameter large enough.

Interpolate PDF

name: interpolatepdf, type: Bool, default: TRUE

If checked, the PDF is being replaced with a piecewise linear function.

Since the approximation to the PDF is computed out of a piecewise linear CDF, it is naturally piecewise constant. If this field is enabled, it is, however, replaced with a piecewise linear function (obtained by interpolation between the interval midpoints). Since the curves are approximations anyway, this is usually recommended to do since it makes the PDF smoother. However, be aware of the fact that enabling this field will cause the integral of the PDF approximation to differ from the correct value of 1.

Level

name: level, type: Integer, default: 1, minimum: 1

Sets a value to influence the precision of the computation.

The higher this value is chosen, the more precise the result is. The number of points at which the function is evaluated is given by (2l + 1)d, but the algorithm will evaluate some points more than once, and the number of function evaluations is therefore larger and given by (3 * 2l - 1)d. The level must be at least 1. (You will find the reason for this yourself if you compute the number of function evaluations for l=0.)

Auto apply

name: autoApply, type: Bool, default: FALSE

If checked, the module computes anew on any parameter or input change.

Apply

name: apply, type: Trigger

If pressed, the module computes anew.