Beta
Description
This function calculates Beta function with parameter a and b. The formula of the Beta function is:
/math-612930548017429a0b96fcca912777ab.png)
Syntax
double beta(double a,double b)
Parameters
a
- Input parameter. The first shape parameter, a, of the required beta distribution, must be positive( a>0 ).
b
- Input parameter. The second shape parameter, b, of the required beta distribution, must be positive ( b>0 ).
Return
Returns the value of Beta function with parameters a and b.
Example
aa = beta(2,2); aa = ; //aa=0.16666666666879