CDF
Evaluates the Poisson distribution CDF.
Controller: CodeCogs
Contents
Dependents
Interface
C++
CDF
doubleCDF( | int | k | |
double | m | ||
bool | upper = false | ) |
Example:
#include <stdio.h> #include <codecogs/statistics/distributions/discrete/poisson/cdf.h> using namespace Stats::Dists::Discrete::Poisson; int main() { int k[10] = { 9, 5, 1, 5, 8, 9, 0, 5, 2, 10 }; double m[10] = { 1.0, 7.3, 0.2, 4.7, 5.4, 6.0, 9.3, 8.9, 1.8, 6.2 }; for( int i=0; i<10; i++ ) printf( "CDF( %i, %1.1f, true ) = %f \n", k[i], m[i], CDF( k[i], m[i] ) ); return getchar(); }
Output:
CDF( 9, 1.0, true ) = 1.000000 CDF( 5, 7.3, true ) = 0.264043 CDF( 1, 0.2, true ) = 0.982477 CDF( 5, 4.7, true ) = 0.668438 CDF( 8, 5.4, true ) = 0.902650 CDF( 9, 6.0, true ) = 0.916076 CDF( 0, 9.3, true ) = 0.000091 CDF( 5, 8.9, true ) = 0.121900 CDF( 2, 1.8, true ) = 0.730621 CDF( 10, 6.2, true ) = 0.948559
Accuracy:
See Maths/Special/Gamma/Gamma_Lower_regParameters
k the number of terms to sum, must be positive m lambda, must be strictly positive upper Default value = false
Returns
- the sum of the terms k to infinity of the Poisson distribution
Authors
- Stephen L. Moshier (June 2000)
Updated by Vince Cole (April 2005)
Source Code
Source code is available when you agree to a GP Licence or buy a Commercial Licence.
Not a member, then Register with CodeCogs. Already a Member, then Login.