div simplification that cleans up matrix inverse.