Elecmetric

Binomial Distribution Calculator

Enter the number of independent trials, the chance of success in one trial and k, and get the chance of exactly k, fewer than k, at most k

Number of independent trials (n) 20, probability of success in one trial (p) 0.05, number of successes (k) 2 gives
P(X = k), exactly k: 0.1886768013 · P(X < k), fewer than k: 0.7358395249 · P(X ≤ k), at most k: 0.9245163262

Estimate only. Not engineering or safety advice. Check the result against the applicable standard and the equipment data, and have a competent engineer review it before it is relied on. Terms of use.

Open in the calculator with these values

About this calculator

This page calculates P, exactly k, P, fewer than k, P, at most k and 5 more results from number of independent trials, probability of success in one trial and number of successes. Change any value or its unit and the result updates. The steps below show the working for the default values, so you can check each line against your own method.

Limits of this calculator

For a k-out-of-n system, count a unit that works as a success: the chance that at least k of n units work is the P(X ≥ k) result. For the number of ways to pick k items use the permutations and combinations calculator, and for two events use the probability calculator.

Cross-check: 34 reference cases, calculated from textbook formulas coded separately from the engine by the same author, agree with this calculator. This is not an independent review.

Verification status: Engineering reference

Engineering reference. Formula and method documented and tested against separately coded reference calculations. Not yet Verified: the evidence listed on this page is still needed.

What this calculator checks

What remains unverified

Verification register entry

Calculation authorRahul Sharma (author)
Technical reviewNo independent technical review has been carried out
Individual professional approvalNot recorded
Formula referencenot recorded
Standard and editionNot applicable: Pure mathematics or statistics; no electrical standard governs the method
Standard review stateNot applicable
Scope-screening notenot recorded
Cross-check test cases34 reference vectors (tests/reference_vectors.json)
Review datenot recorded
Next review datenot recorded
StatusEngineering reference

Needed before this calculator can be marked Verified: reviewer name, qualification and review date; exact formula reference; formula source (textbook or standard); next review date.

Formula

P(X = k) = nCk pᵏ (1 − p)ⁿ⁻ᵏ P(X ≤ k) = sum of P(X = j) for j = 0 to k mean = n p variance = n p (1 − p)

Worked example

InputValue
Number of independent trials (n)20
Probability of success in one trial (p)0.05
Number of successes (k)2
  1. P(X = k) = nCk pᵏ (1 − p)ⁿ⁻ᵏ = 0.1886768013 (n = 20, p = 0.05, k = 2)
  2. P(X ≤ k) = 0.9245163262 P(X < k) = 0.7358395249
  3. P(X ≥ k) = 0.2641604751 P(X > k) = 0.0754836738
  4. Mean = n p = 1 Variance = n p (1 − p) = 0.95 Standard deviation = 0.9746794345

Assumptions

For a k-out-of-n system, count a unit that works as a success: the chance that at least k of n units work is the P(X ≥ k) result. For the number of ways to pick k items use the permutations and combinations calculator, and for two events use the probability calculator.

Inputs and results

InputUnitAllowed or shownNote
Number of independent trials (n)(number)1 or more, up to 1,000A whole number from 1 to 1000, such as the number of lamps, units or samples.
Probability of success in one trial (p)(number)0 or more, up to 1A number from 0 to 1. For 5% enter 0.05. Use the chance of the event you are counting, for example a lamp failing.
Number of successes (k)(number)0 or more, up to 1,000A whole number from 0 to n. A success is the event with probability p.
ResultUnitAllowed or shownNote
P(X = k), exactly k(number)Shown to 10 decimal places
P(X < k), fewer than k(number)Shown to 10 decimal places
P(X ≤ k), at most k(number)Shown to 10 decimal places
P(X > k), more than k(number)Shown to 10 decimal places
P(X ≥ k), at least k(number)Shown to 10 decimal places
Mean number of successes (n p)(number)Shown to 10 decimal places
Variance (n p (1 − p))(number)Shown to 10 decimal places
Standard deviation(number)Shown to 10 decimal places

How it is calculated

Each input is converted to the base unit of its quantity, the formula above is applied in the order shown in the worked example, and each result is shown in the unit you choose. Results are held at full precision and rounded only for display, except where a step selects a standard size, as the worked example shows. A value outside its allowed range is refused with a message instead of giving a result.

How the result changes with number of independent trials (n)

Number of independent trials (n)P(X = k), exactly kP(X < k), fewer than kP(X ≤ k), at most k
20.00250.99751
50.0214343750.97740750.998841875
100.07463479850.91386164410.9884964426
200.18867680130.73583952490.9245163262
400.27767169560.39906406510.6767357607
800.14456671210.08605379280.2306205049
2000.00193226610.00040402810.0023362942

Other inputs are the same as in the worked example above.

Standards and further reading

Complex numbers, rectangular and polar form and angle conversion are standard mathematics, not the subject of a standard. Standards apply when the result feeds an electrical design, and they set the method there.

Frequently asked questions

What do I need to enter?

Enter number of independent trials (n), probability of success in one trial (p) and number of successes (k). Change the unit of a value with its selector and the result stays the same.

What does this calculator assume?

Each of the n trials is independent, has only two outcomes, and has the same probability p of success. Units that share a power supply, a cable or a cause of failure are not independent, so the result is optimistic for them. The tail figures are added up term by term, not found as 1 minus the other side, so a very small tail keeps its precision. Terms are calculated from sums of logarithms, accurate to about 12 significant figures for n up to 1000. k must be a whole number from 0 to n. The model has no wear-out, repair or ageing: p is the same for every trial.

Which calculators should I use next?

Common next steps are Permutations and Combinations Calculator (nPr, nCr), Probability Calculator (Two Events, A and B, and Repeated Trials), Standard Deviation and Variance and Percentage Calculator. The related links at the bottom of this page open them.

How accurate are the results?

Every figure comes from the same tested engine as the Elecmetric calculators and is meant for estimating. 34 reference cases, calculated from textbook formulas coded separately from the engine by the same author, agree with this calculator. This is not an independent review. Check design values against the standard and the equipment data you work to.

Formula guides and reference

Longer explanations with worked examples and tables, written for the same topic.

More Engineering Mathematics calculatorsAll engineering calculatorsBinomial Distribution Calculator (Exactly k, At Most, At Least) in Elecmetric

Tell us how to improve this page

This opens your email app. Nothing is sent until you press send.