added hints in comments for calculating cofactors