Toolvito

Works on this device

Acceptance Sampling Calculator

A single sampling plan inspects n units of a lot and accepts the lot when c or fewer are defective. Type a plan to see how often it accepts lots of each quality, its risks at your AQL and LTPD, its OC curve and its AOQL, or let the tool find a plan from the AQL, the LTPD and the risks.

Enter your values

The probability of accepting a lot, the producer's and consumer's risks, the OC curve and the AOQL of a plan with n and c.

Your values

Needed for the hypergeometric model. With the other models it is used only for AOQ and the average total inspection.

Accept the lot when the sample has c or fewer defective units.

The acceptable quality level you and your customer agreed. It gives the producer's risk.

The lot tolerance percent defective (also called RQL): a quality you want to reject. It gives the consumer's risk.

More options

Left empty, a range is chosen from the plan, the AQL and the LTPD.

Your values are worked out in this browser. They are not sent to a server.

Your result will show here

Fill in the values, then choose Calculate.

How to use this calculator

  1. Choose Check a single sampling plan or Find a plan from the AQL, LTPD and risks.
  2. To check a plan, choose the model, then enter the sample size n and the acceptance number c. Add the lot size for the hypergeometric model, for AOQ with a finite lot and for the average total inspection.
  3. Type your AQL and LTPD in percent defective to see the producer's and the consumer's risk.
  4. To find a plan, enter the AQL with the producer's risk α and the LTPD with the consumer's risk β. Then choose Check this plan to see its OC curve.

The formulas

  • Probability of acceptance Pa = P(defective units in the sample ≤ c).
  • Binomial model: P(d = k) = C(n, k) × p^k × (1 − p)^(n − k). For a steady stream of units or a lot much larger than the sample.
  • Hypergeometric model: P(d = k) = C(D, k) × C(N − D, n − k) ÷ C(N, n), with D = p × N defective units in a lot of N, rounded to a whole unit. Exact for one lot.
  • Poisson model: P(d = k) = e^(−np) × (np)^k ÷ k!. Close to the binomial model when p is small.
  • Producer's risk α = 1 − Pa at the AQL. Consumer's risk β = Pa at the LTPD.
  • AOQ = Pa × p × (N − n) ÷ N, when rejected lots are inspected in full and defective units are replaced. AOQL is the highest AOQ over all qualities. Average total inspection = n + (1 − Pa) × (N − n).

Worked example

A plan takes n = 60 units and accepts the lot with c = 1 or fewer defective. By the binomial model, at 0.5% defective Pa = 0.995^60 + 60 × 0.005 × 0.995^59, which is about 96.4%, so the producer's risk is about 3.6%. At 6% defective Pa = 0.94^60 + 60 × 0.06 × 0.94^59, which is about 11.8%: the consumer's risk.

Sampling standards

Standards such as ANSI/ASQ Z1.4 (which follows MIL-STD-105E) and ISO 2859-1 give single, double and multiple sampling plans from tables of code letters by lot size and inspection level, with rules to switch between normal, tightened and reduced inspection. Those tables are not built in here. Read n and c from your copy of the standard and type them in the first part to see the OC curve and the risks of that plan.

Limits you should know

  • This is sampling by attributes (a unit is good or defective) with a single sample. Double, multiple and sequential plans and sampling by variables are not covered.
  • The plan that the second part finds is the smallest one that meets your two points by the model you choose. It is not a plan of any standard.
  • Common choices such as α = 5% and β = 10% are conventions, not rules. Agree the AQL, the LTPD and the risks with your customer or supplier.
  • For more on sample sizes and probabilities, see the Probability Calculator.

Related tools