Figure 9.1, and vairious fixes
Figure 9.2 and fixes to broken tests