The OpenD Programming Language

rayleighInvCDF

Ditto, with scale parameter.

  1. T rayleighInvCDF(T p)
  2. T rayleighInvCDF(T p, T scale)
    @safe pure nothrow @nogc
    T
    rayleighInvCDF
    (
    T
    )
    (
    const T p
    ,
    const T scale
    )
    if (
    isFloatingPoint!T
    )

Parameters

p T

value to evaluate InvCDF

scale T

scale parameter

Examples

import mir.test: shouldApprox;

rayleighInvCDF(0.0).shouldApprox == 0.0;
rayleighInvCDF(0.25).shouldApprox == 0.7585276;
rayleighInvCDF(0.5).shouldApprox == 1.17741;
rayleighInvCDF(0.75).shouldApprox == 1.665109;
rayleighInvCDF(1.0).shouldApprox == double.infinity;

// Can also provide scale parameter
rayleighInvCDF(0.2, 2).shouldApprox == 1.336094;
rayleighInvCDF(0.4, 2).shouldApprox == 2.021535;
rayleighInvCDF(0.6, 2).shouldApprox == 2.707457;
rayleighInvCDF(0.8, 2).shouldApprox == 3.588245;

See Also

Meta