Minor fixes to chapters 3 and 4.