预订演示

请注意 : 本帮助页面不适用于最新版本的Enterprise Architect. 最新的帮助文档在这里.

前页 后页

bdtr

Binomial distribution.

SYNOPSIS:

int k, n;
double p, y, bdtr();
y = bdtr(k, n, p);

DESCRIPTION:

Returns the sum of the terms 0 through k of the Binomial probability density:

k
-- (n) j n-j
> () p (1-p)
-- (j)
j=0

The terms are not summed directly; instead the incomplete beta integral is employed, according to the formula:

y = bdtr(k, n, p) = incbet(n-k, k+1, 1-p).

The arguments must be positive, with p ranging from 0 to 1.

ACCURACY:

Tested at random points (a,b,p), with p between 0 and 1.

a,b Relative error:
arithmetic domain # trials peak rms
For p between 0.001 and 1:
IEEE 0,100 100000 4.3e-15 2.6e-16

ERROR MESSAGES:

message condition value returned
domain k < 0 0.0
n < k
x < 0, x > 1