completed hw5 - inverse / rank / independence etc.