2.78.2 Algorithm for Acceptance Sampling Analysis

Contents

Attributes Acceptance Sampling

Sample size and acceptance number

Sample size (\(n\)) and acceptance number (\(c\)) are the minimum values that satisfy the following inequality
\[ \text{CDF}(c, n, p_1) < \alpha \]
\[ \text{CDF}(c, n, p_2) < \beta \]
\[ 0 < p_1 < p_2 < 1 \]
\[ 0 < \beta < 1 - \alpha < 1 \]
where

Probability of acceptance

The probability that a lot will be accepted, given a specific sampling plan (\(c\) and \(n\)) and the incoming proportion defective or number of defects (\(p\)).
\[ P_a = \text{CDF}(c, n, p) \]

Probability of rejecting

The probability that a lot will be rejected, given a specific sampling plan and the incoming proportion defective or number of defects.
\[P_r = 1 - P_a\]

Average outgoing quality (AOQ)

The quality level of the product based on the incoming proportion defective or number of defects.
\[AOQ = \frac{P_ap(N-n)}{N}\]

Average total inspection (ATI)

The average number of units to be inspected for a certain sampling plan and probability of acceptance.
\[ATI = n + (1 - P_a)(N-n)\]

Variables Acceptance Sampling (Create/Compare)

Sample size and critical distance

The sample size (\(n\)) and critical distance (\(k\)) depend on the provided specification and whether the standard devidation is known.

Single specification limit and known standard deviation

\[n=(\frac{Z_\beta+Z_\alpha}{Z_1-Z_2})^2\]
\[k = \frac{K_1+K_2}{2}\]
where
\[K_1 = Z_1 - \frac{Z_\alpha}{\sqrt{n}}\]
\[K_2 = Z_2 + \frac{Z_\beta}{\sqrt{n}}\]
\(Z_1\): the \((1-p_1)*100\) percentile of the standard normal distribution
\(Z_2\): the \((1-p_2)*100\) percentile of the standard normal distribution
\(Z_\alpha\): the \((1-\alpha)*100\) percentile of the standard normal distribution
\(Z_\beta\): the \((1-\beta)*100\) percentile of the standard normal distribution
\(p_1\): acceptable quality level (AQL)
\(p_2\): rejectable quality level (RQL or LTPD)
\(\alpha\): producer's risk
\(\beta\): consumer's risk

Single specification limit and unknown standard deviation

\[n = (1 + \frac{k^2}{2})(\frac{Z_\alpha + Z_\beta}{Z_1 - Z_2})^2\]
\[k = \frac{Z_\alpha Z_2 + Z_\beta Z_1}{Z_\alpha + Z_\beta}\]

Double specification limits and known standard deviation

\[n=(\frac{Z_\beta+Z_\alpha}{Z_{p_L}-Z_2})^2\]
\[k = \frac{K_1+K_2}{2}\]
where
\[K_1 = Z_{p_L} - \frac{Z_\alpha}{\sqrt{n}}\]
\[K_2 = Z_2 + \frac{Z_\beta}{\sqrt{n}}\]
\(Z_{p_L}\): the \((1 – p_L) * 100\) percentile of the standard normal distribution
\(p_L\): determined using the following procedure:
  • \(p_L = \text{max}\left\{ \Phi(\frac{L-\mu}{\sigma}), 1 - \Phi(\frac{U-\mu}{\sigma})\right\}\), where \(\mu\) is chosen such that \(\Phi(\frac{L-\mu}{\sigma}) + 1 - \Phi(\frac{U-\mu}{\sigma}) = p_1\)
  • \( p_L = p_1 \), if \(\Phi(\frac{L-\mu}{\sigma}) + 1 - \Phi(\frac{U-\mu}{\sigma})\) deviates substantially from \(p_1\)
\(\Phi\): the cdf of the standard normal distribution
\(L\): the lower spec
\(U\): the upper spec
\(\sigma\): the historical standard deviation

Double specification limits and unknown standard deviation

\[n = (1 + \frac{k^2}{2})(\frac{Z_\alpha + Z_\beta}{Z_1 - Z_2})^2\]
\[k = \frac{Z_\alpha Z_2 + Z_\beta Z_1}{Z_\alpha + Z_\beta}\]

Calculation of Maximum Standard Deviation (MSD)

Default Method[1]
  1. \[v_1 = \max\left\{0, \frac{1}{2} - \frac{1}{2}k\frac{\sqrt{n}}{n-1}\right\}\]
  2. \(p = Beta(v_1, a, b)\), where \(a = b = \frac{n-2}{2}\) and \(Beta\) is the CDF of beta distribution.
  3. \[v_2 = Beta^{-1}(p/2,a,b)\]
  4. \[k^* = \frac{(n-1)(1-2v_2)}{\sqrt{n}}\]
  5. \[MSD = \frac{U-L}{2*k^*}\]
Wallis Method[2]
  1. \[p = 1 - \Phi(k)\]
  2. \[Z_p = \Phi^{-1}(1-p/2)\]
  3. \[MSD = \frac{U-L}{2*Z_p}\]

Probability of acceptance

The probability that a lot will be accepted, given a specific sampling plan (\(n\) and \(k\)) and the incoming proportion defective (\(p\)).

Single specification limit and known standard deviation

\[ P_a = \Phi(\sqrt{n}(Z_p-k)) \]
where
\(Z_p\): the \((1-p)*100\) percentile of the standard normal distribution
\(p\): probability of defective

Single specification limit and unknown standard deviation

\( P_a = 1 - nctcdf(\sqrt{n}k, n-1, \sqrt{n}Z_p) \), where \(nctcdf\) is the CDF of non-central t distribution.

Double specification limits and known standard deviation

Use the following procedure
\(P_a = \Phi(\sqrt{n}(\frac{U-\mu}{\sigma}-k)) - \Phi(\sqrt{n}(\frac{L-\mu}{\sigma}+k))\), where \(\mu\) is chosen such that \(\Phi(\frac{L-\mu}{\sigma}) + 1 - \Phi(\frac{U-\mu}{\sigma}) = p\)
\(P_a = \Phi(\sqrt{n}(Z_p-k))\), if \(\Phi(\frac{L-\mu}{\sigma}) + 1 - \Phi(\frac{U-\mu}{\sigma})\) deviates substantially from \(p\)

Double specification limits and unknown standard deviation

\[ P_a = 1 - nctcdf(\sqrt{n}k, n-1, \sqrt{n}Z_p) \]

Probability of rejecting

The probability that a lot will be rejected, given a specific sampling plan and the incoming proportion defective.
\[P_r = 1 - P_a\]

Average outgoing quality (AOQ)

The quality level of the product based on the incoming proportion defective or number of defects.
\[AOQ = \frac{P_ap(N-n)}{N}\]

Average total inspection (ATI)

The average number of units to be inspected for a certain sampling plan and probability of acceptance.
\[ATI = n + (1 - P_a)(N-n)\]

Acceptance region (AR)

Default Method
  1. \[v_1 = \max\left\{0, \frac{1}{2} - \frac{1}{2}k\frac{\sqrt{n}}{n-1}\right\}\]
  2. \(p = Beta(v_1, a, b)\), where \(a = b = \frac{n-2}{2}\) and \(Beta\) is the CDF of beta distribution.
  3. for each pair of \((v_{01}, v_{02})\) so that \(Beta(v_{01},a,b) + Beta(v_{02},a,b) = p\)
  • \[\bar{x} = \frac{U(1-2v_{01})-L(2v_{02}-1)}{2(1-v_{01}-v_{02})}\]
  • \[s = \frac{U-L}{2(1-v_{01}-v_{02})}(\frac{\sqrt{n}}{n-1})\]
Wallis Method
  1. \[p = 1 - \Phi(k)\]
  2. for each pair of \((p_{01}, p_{02})\) so that \(p_{01} + p_{02} = p\)
  • \[\bar{x} = \frac{UZ_{p_{01}}+LZ_{p_{02}}}{Z_{p_{01}}+Z_{p_{02}}}\]
  • \[s = \frac{U-L}{Z_{p_{01}}+Z_{p_{02}}}\]

Variables Acceptance Sampling (Accept/Reject Lot)

Mean and standard deviation are first calculated from the data.
\[\bar{X} = \frac{\sum X_i}{n}\]
\[s = \sqrt{\frac{\sum (X_i-\bar{X})^2}{n-1}}\]
Then calculate the acceptance criteria
\[Z_L = \frac{\bar{X}-L}{s}\]
\[Z_U = \frac{U-\bar{X}}{s}\]
Note that if historical standard deviation is provided, then \(\sigma\) is used for the \(Z\) calculation.

Single specification limit

If only lower spec is provided, then accept the lot if \(Z_L \ge k \)
If only upper spec is provided, then accept the lot if \(Z_U \ge k \)

Double specification limits and known standard deviation

Accept the lot if \(Z_L \ge k \) and \(Z_U \ge k \)

Double specification limits and unknown standard deviation

Accept the lot if \(s \le MSD \), \(Z_L \ge k \) and \(Z_U \ge k \)

Reference

  1. Duncan, A. J. (1986). "Quality Control and Industrial Statistics (5th ed.)". Homewood, Ill: Irwin
  2. Schilling and Neubauer (2009). "Acceptance Sampling in Quailty Control (2nd ed.)"