Sub topic 11
One-sided specifications
This chapter assumes you can already compute Cp and Cpk for a two-sided specification and that you know how to estimate sigma from subgroups with R-bar/d2. Here the specification has only one limit, and several things you relied on change.
What a one-sided specification is
Many characteristics have a limit on one side only:
- Upper limit only: impurity level, surface roughness, flatness, runout, cycle time, leak rate. Lower is better, and there is no penalty for being "too low".
- Lower limit only: tensile strength, wall thickness, fill weight guaranteed as a minimum, battery capacity. Higher is better.
There is no tolerance width, because there is only one limit (USL or LSL). There is also no "center" to aim for. The goal is to stay as far from the limit as is economical.
Why Cp does not apply
Cp is defined as (USL − LSL) / (6σ). It compares the width of the tolerance with the width of the natural spread. With one limit, the tolerance width is undefined, so Cp cannot be computed. It would also answer the wrong question, since with one limit nothing is "too wide".
Cpk is still defined, and it is simpler. Cpk is the minimum of Cpu and Cpl, and with one limit only one of those exists:
- USL only: Cpk = Cpu = (USL − mean) / (3σ)
- LSL only: Cpk = Cpl = (mean − LSL) / (3σ)
You report the single index you can compute. Most software labels it CPU or CPL, or simply Cpk. State which limit it refers to so readers do not wonder where Cp went.
Choosing the right index
A worked example with an upper limit
A chemical process has an impurity specification of at most 0.50 % (USL = 0.50). There is no lower limit, since less impurity is never a problem. A stable process has a mean of 0.20 % and a within-subgroup sigma of 0.08 %.
- Distance from mean to limit: 0.50 − 0.20 = 0.30
- Three sigma: 3 × 0.08 = 0.24
- Cpu = 0.30 / 0.24 = 1.25
The process has 3.75 standard deviations between its mean and the limit. This is below the common 1.33 benchmark, so the process is marginal.
The code below handles either limit, or both. It raises an error if no limit is given.
from statistics import NormalDist
def capability(mean, sigma, lsl=None, usl=None):
"""Return (cpk, expected_ppm) for a one- or two-sided specification."""
if lsl is None and usl is None:
raise ValueError("Provide at least one specification limit")
if sigma <= 0:
raise ValueError("sigma must be positive")
indices = []
if usl is not None:
indices.append((usl - mean) / (3 * sigma))
if lsl is not None:
indices.append((mean - lsl) / (3 * sigma))
cpk = min(indices)
dist = NormalDist(mu=mean, sigma=sigma)
ppm = 0.0
if usl is not None:
ppm += (1 - dist.cdf(usl)) * 1_000_000
if lsl is not None:
ppm += dist.cdf(lsl) * 1_000_000
return cpk, ppm
cpk, ppm = capability(mean=0.20, sigma=0.08, usl=0.50)
print(round(cpk, 2), round(ppm, 1))This prints a Cpk of 1.25 and an expected rate of about 88 parts per million above the limit. With a single limit there is only one tail to add up, so the conversion is just the upper tail beyond 3 × Cpk standard deviations.
Defect rates at one-sided benchmarks
With one limit, the expected defect rate depends only on one tail of the normal curve. The same Cpk therefore gives roughly half the defects of a centered two-sided process, because the two-sided case has a tail on each side.
| Cpk | Distance to limit | One-sided defect rate (normal model) |
|---|---|---|
| 1.00 | 3 sigma | about 1,350 ppm |
| 1.25 | 3.75 sigma | about 88 ppm |
| 1.33 | 4 sigma | about 32 ppm |
| 1.67 | 5 sigma | about 0.29 ppm |
Do not mix these with two-sided tables. A centered two-sided process at Cpk 1.33 shows about 63 ppm, because both tails count. The one-sided figure for the same index is about 32 ppm.
The normality problem is worse
One-sided characteristics are often bounded at zero. Flatness, runout, impurity level, and roughness cannot be negative. When the mean sits only a few sigmas above a hard zero, the distribution is skewed, with a long tail toward the limit that matters, and the normal model underestimates the risk.
Take the impurity example: mean 0.20, sigma 0.08. The mean is only 2.5 sigma above zero. A normal model puts about 0.6 % of the output below zero, which is impossible. The real distribution must bunch up near zero and stretch out toward the upper limit. That is the direction where you care about accuracy, so the normal-based Cpu of 1.25 is probably optimistic.
Here is what to do:
- Plot a histogram and a normal probability plot. Look for skew and for a pile-up against the physical bound.
- Run a goodness-of-fit test such as Anderson-Darling, but read the plot as well. With large samples the test rejects tiny departures, and with small samples it misses real ones.
- If the data are skewed, fit a better distribution (lognormal, Weibull, gamma) or apply a transformation such as the log or a Box-Cox transform. Compute the limit and the capability in the transformed scale.
- Alternatively, use a percentile-based index. For an upper limit:
Ppu-style index = (USL − median) / (P99.865 − median)
where P99.865 is the 99.865th percentile of the fitted or empirical distribution. For a normal distribution it equals mean + 3σ, so the index reduces to Cpu. For a skewed one it respects the long tail.
The next chapter, on checking normality, covers these checks in more detail. Do them before you trust any one-sided index near a natural boundary.
from math import log
from statistics import NormalDist, mean, stdev
# Right-skewed measurements, such as impurity in percent, bounded at zero
data = [0.12, 0.15, 0.09, 0.31, 0.18, 0.22, 0.14, 0.41, 0.11, 0.17,
0.26, 0.13, 0.19, 0.35, 0.10, 0.16, 0.24, 0.12, 0.28, 0.15]
usl = 0.50
# Naive normal-model Cpu on the raw data
cpu_raw = (usl - mean(data)) / (3 * stdev(data))
# Lognormal approach: work in log scale, where the data are closer to normal
logs = [log(x) for x in data]
z = (log(usl) - mean(logs)) / stdev(logs)
cpu_log = z / 3
ppm_log = (1 - NormalDist().cdf(z)) * 1_000_000
print(round(cpu_raw, 2), round(cpu_log, 2), round(ppm_log, 1))The two estimates disagree. The log-scale version describes the right tail honestly, so compare the two before deciding which to report. Note that this is a single sample used for illustration. It carries no stability check and no subgroup structure, so in practice you would first confirm the process is in control.
Stability and sigma estimation still apply
Nothing about the stability requirement changes. You still need a control chart showing no special causes before a capability index means anything. You still estimate sigma within subgroups, for example with R-bar/d2, to get the short-term capability, and you can use the overall standard deviation to get the long-term Ppu or Ppl.
One practical difference: for characteristics like runout, an individuals and moving range chart is common, because each part gives one measurement. In that case sigma is estimated from the average moving range divided by 1.128.
Common mistakes
- Reporting a Cp for a one-sided specification, usually by inventing a second limit.
- Setting the other limit to zero for "lower is better" characteristics. This turns a one-sided problem into a two-sided one and makes Cp and the centering penalty meaningless.
- Using the two-sided ppm table to interpret a one-sided Cpk.
- Applying a normal model to data piled up against a physical zero.
- Forgetting to say whether the reported index is Cpu or Cpl.
Exercise
A fill process has a lower specification limit of 500 g and no upper limit. Subgroup data give a mean of 506 g and a within-subgroup sigma of 2.0 g. Which index applies, what is its value, and what share of containers do you expect below the limit under a normal model (about 1,350 ppm at 3 sigma, about 32 ppm at 4 sigma)?
Show answer
Only a lower limit exists, so Cp is undefined and you report Cpl as the Cpk. Cpl = (506 − 500) / (3 × 2.0) = 6 / 6 = 1.0. The limit is 3 sigma below the mean, so you expect about 1,350 ppm (0.135 %) of containers below 500 g, and the process is not capable by the 1.33 benchmark.
Exercise
A process measures flatness with USL = 0.10 mm and no lower limit. The mean is 0.03 mm and sigma is 0.02 mm. The computed Cpu is 1.17. Why might this value be misleading, and what would you do next?
Show answer
The mean is only 1.5 sigma above zero, and flatness cannot be negative, so the distribution is bounded at zero and probably right-skewed. A normal model puts mass below zero and understates the tail toward the USL. Plot the data, test or inspect normality, then fit a skewed distribution such as lognormal or Weibull, or use a percentile-based index such as (USL − median) / (P99.865 − median), and compare it with the normal-based value.