MathPHP\Probability\Distribution\Discrete\ShiftedGeometric::PMF PHP 메소드

PMF() 공개 정적인 메소드

The probability distribution of the number X of Bernoulli trials needed to get one success, supported on the set { 1, 2, 3, ...} https://en.wikipedia.org/wiki/Geometric_distribution k trials where k ∈ {1, 2, 3, ...} pmf = (1 - p)ᵏ⁻¹p
public static PMF ( integer $k, float $p ) : float
$k integer number of trials k ≥ 1
$p float success probability 0 < p ≤ 1
리턴 float
    public static function PMF(int $k, float $p) : float
    {
        Support::checkLimits(self::LIMITS, ['k' => $k, 'p' => $p]);
        $⟮1 − p⟯ᵏ⁻¹ = pow(1 - $p, $k - 1);
        return $⟮1 − p⟯ᵏ⁻¹ * $p;
    }
ShiftedGeometric