SLIDE 19 In order to detect an extremum introduce the function R(u, v) =
|u| + |v|
where q is an integer power. R(u, v) = 1 whenever u and v have opposite signs. When u = v = 0, R(u, v) should be assigned the value zero. Now set sj+1
2 = R
2, ∆uj−1 2
so that sj+1
2 = 1 when ∆uj+3 2 and ∆uj−1 2 have opposite signs which will
generally be the case if either uj+1 or uj is an extremum. In a smooth region where ∆uj+3
2 and ∆uj−1 2 are not both zero, sj+1 2 is of the order ∆xq, since
∆uj+3
2 − ∆uj−1 2 is an undivided difference. In order to avoid activating the
switch at smooth extrema, and also to protect against division by zero, R(u, v) may be redefined as R(u, v) =
max {(|u| + |v|), ǫ}
where ǫ is a tolerance.
c
Stanford University, Stanford, CA 19/73