some enhancements were made in chapter 2