What does CUSUM Alarms conclude, in numbers, about “The Boundaries of Optimality: Autocorrelation, Residual Charts and Large Jumps”?
Answer: In the combined rule the CUSUM limit rises from 4.096 to 4.148, and the false-alarm interval is still 370.0 days. The cost falls on small drifts and is small: for half a standard deviation the combined rule needs 28.0 days and the pure CUSUM 27.7. The gain falls on large jumps: for four standard deviations the combined rule needs 1.3 days, the pure CUSUM 1.7 and the fixed threshold 1.1; for five standard deviations the three need 1.1, 1.3 and 1.0 days. Nowhere in the table is the combined rule the slowest of the three, and almost nowhere is it noticeably slower than the fastest.
Scope of the numbers: Parameters are illustrative; all calculations are generated by the book's programs; the book is general business analysis, not individualised business advice, and Chapter 8 is an offline model that reads no server. Marked boxes separate published evidence, runnable Python calculations (23 programs), classical sources and the author's hypotheses.
Data table
The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 1.0, 1.1, 1.3, 1.7, 27.7, 28.0
| CUSUM h = 4.096; combined h = 4.148 with cap 3.5 | |||
| combined ARL0 = 370.0 | |||
| shift | fixed | CUSUM | combined |
| 0.50 | 88.9 | 27.7 | 28.0 |
| 1.00 | 26.7 | 8.6 | 8.6 |
| 2.00 | 4.6 | 3.4 | 3.3 |
| 3.00 | 1.7 | 2.2 | 2.0 |
| 4.00 | 1.1 | 1.7 | 1.3 |
| 5.00 | 1.0 | 1.3 | 1.1 |
Show the full program
# Chapter 6. p63: big jumps favour the fixed threshold, so combine them.
# Model: z ~ N(delta, 1). Three rules share ARL0 = 370: the fixed
# threshold (L = 2.782, solved here), the CUSUM of p12 (k = 0.5,
# h = 4.096), and a combined rule that alarms when z > 3.5 or when the
# CUSUM passes its own re-solved limit. For the combined rule the Brook
# and Evans chain keeps only the moves with z <= 3.5, so a single large
# reading ends the run (m = 60, illustrative).
import math
def cdf(x):
return 0.5 * math.erfc(-x / math.sqrt(2.0))
def upper(x):
return 0.5 * math.erfc(x / math.sqrt(2.0))
def solve(a, b):
# Gaussian elimination with partial pivoting; back substitution
# adds its terms with math.fsum
n = len(b)
m = [list(row) + [b[i]] for i, row in enumerate(a)]
for p in range(n):
q = max(range(p, n), key=lambda r: abs(m[r][p]))
m[p], m[q] = m[q], m[p]
piv = m[p]
for r in range(p + 1, n):
f = m[r][p] / piv[p]
if f != 0.0:
m[r] = m[r][:p] + [x - f * y for x, y in
zip(m[r][p:], piv[p:])]
x = [0.0] * n
for i in range(n - 1, -1, -1):
s = math.fsum(m[i][j] * x[j] for j in range(i + 1, n))
x[i] = (m[i][n] - s) / m[i][i]
return x
def arl(k, h, delta, cap=None, m=60):
# cap: also alarm at once when the reading z exceeds cap
w = 2.0 * h / (2 * m - 1)
top = 50.0 if cap is None else cap - delta
a = []
for i in range(m):
c = i * w - k + delta
row = [-cdf(min(w / 2.0 - c, top))]
for j in range(1, m):
lo = j * w - w / 2.0 - c
hi = min(j * w + w / 2.0 - c, top)
row.append(-max(0.0, cdf(hi) - cdf(lo)))
row[i] = row[i] + 1.0
a.append(row)
return solve(a, [1.0] * m)[0]
def limit_for(arl0):
lo, hi = 0.0, 10.0
for _ in range(200):
mid = 0.5 * (lo + hi)
if upper(mid) > 1.0 / arl0:
lo = mid
else:
hi = mid
return 0.5 * (lo + hi)
def h_for(k, target, cap):
lo, hi = 0.5, 15.0
for _ in range(30):
mid = 0.5 * (lo + hi)
if arl(k, mid, 0.0, cap) < target:
lo = mid
else:
hi = mid
return 0.5 * (lo + hi)
if __name__ == "__main__":
L, k = limit_for(370.0), 0.5
h1 = h_for(k, 370.0, None)
h2 = h_for(k, 370.0, 3.5)
print("CUSUM h = {:.3f}; combined h = {:.3f} with cap 3.5".format(h1, h2))
print("combined ARL0 = {:.1f}".format(arl(k, h2, 0.0, 3.5)))
print(" shift fixed CUSUM combined")
for d in (0.5, 1.0, 2.0, 3.0, 4.0, 5.0):
print(" {:5.2f} {:6.1f} {:6.1f} {:8.1f}".format(
d, 1.0 / upper(L - d), arl(k, h1, d), arl(k, h2, d, 3.5)))Single source and citation
Fan, Y. (2026). CUSUM Control Charts and Average Run Length: the Fastest Alarm within a False-Alarm Budget for Latency Drift and Silent Conversion Drops (Version 1.0.0), Chapter 6: The Boundaries of Optimality: Autocorrelation, Residual Charts and Large Jumps. 5D Library. DOI pending
DOI pending · monograph page goes live after publication · 5DL-B-305 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026305,
author = {Fan, Yafu},
title = {CUSUM Control Charts and Average Run Length: the Fastest Alarm within a False-Alarm Budget for Latency Drift and Silent Conversion Drops},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}Other chapter answers in this book
- Chapter 1 · The Sluggish Red Line: at Equal False-Alarm Rates the CUSUM Is Several Times Faster
- Chapter 2 · One Line of Recursion: the CUSUM Is a Running Log-Likelihood Ratio
- Chapter 3 · The Markov Chain of Brook and Evans: the Average Run Length as a System of Linear Equations
- Chapter 4 · Siegmund's Approximation and Lorden's Bound: Detection Delay Grows Only with the Logarithm of the False-Alarm Interval
- Chapter 5 · Design Tables for the Reference Value and the Limit: the Cost of a Wrong Shift and a Wrong Baseline
- Chapter 7 · Eastern and Western Sources: the Dike of a Thousand Zhang and Shewhart's Three Sigma
- Chapter 8 · A Daily CUSUM at the Toll Gate: P99 Latency, Silent Conversion Drops and a Falsification Protocol