alexnet Posted February 26, 2019 Share Posted February 26, 2019 Hello! There is the following code and a very strange result which returns the function of invert. How does the invert function actually work for zero determinant matrices? matrix3 matA = { {1,2,3}, {4,5,6}, {7,8,9} }; // Find the determinant of the matrix // If the determinant value is zero, then an inverted matrix cannot be found for such a matrix. int det = determinant(matA); // det == 0 matrix3 matB = invert(matA); // { {-0.75, 0.5, 0.25}, {-0.5, 0, -0.5}, {0.5833, 0.5, -0.083} } Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.