public class ProbabilityFunction
extends java.lang.Object
| Constructor and Description |
|---|
ProbabilityFunction() |
| Modifier and Type | Method and Description |
|---|---|
static double |
computeCombination(int n,
int m)
组合数
|
static double |
computeContinuousProduct(int n,
int m)
compute m*(m+1)*...*n where n>=m
|
static double |
computeFactorial(int n)
n的阶乘
|
static double |
computePermutation(int n,
int m)
排列数
|
static void |
main(java.lang.String[] str) |
public static double computeFactorial(int n)
n - 要计算的阶public static double computeContinuousProduct(int n,
int m)
m - start valuen - end valuepublic static double computeCombination(int n,
int m)
n - 总个数,C的下标m - 要选取的个数,C的上标public static double computePermutation(int n,
int m)
n - 总个数,A的下标m - 要排列的个数,A的上标public static void main(java.lang.String[] str)