Solution (source code)

= Solution

A classical <sequential probability ratio test> addresses a fixed-start choice between two simple <statistical hypotheses>. It sums <log-likelihood ratio> increments until an upper boundary accepts the alternative or a lower boundary accepts the null; it then terminates that test. A <CUSUM> instead monitors indefinitely for a change at an unknown time. Its reset at zero discards sustained evidence from a previously satisfactory period, so a late change need not first undo all earlier negative scores. An upper boundary $h$ signals when the accumulated change evidence is sufficiently large.

A <fast initial response CUSUM> takes $0<X_0<h$, often $X_0=h/2$, in place of a zero start. Until its first reset or signal, it acts like a fixed-start <sequential probability ratio test> with a lower boundary at $-X_0$ and an upper boundary at $h-X_0$ for the subsequent cumulative increments. Upon reaching the lower boundary it resets and continues as an ordinary <CUSUM>. \b[The head start gives faster detection if a change is already present when monitoring begins or restarts.] It is useful after an intervention, a shutdown or a previous alarm when immediate renewed surveillance is desired. Its initial false-alarm behavior differs from the zero-start scheme, so the head start and signalling boundary must be calibrated together; the preceding numerical choice is a design convention, not a universal optimum.