add code for sections 5.6 & 5.7 pred & equi