What help do you need? Do you know mathematically how to calculate the determinate of a 3x3 matrix by using determinates of associated 2x2 matrices? Can you define a 3x3 matrix in the program and populate it from data entered by the user? Can you obtain the required 2x2 matrices from the entered 3x3 matrix in the program? Given a 2x2 matrix, can you write the code to determine the determinant? Have you designed the program specifying required functions, algorithms etc etc?

Post your current code.

Post your current code.

a_{11} ( a_{22} a_{33} - a_{23} a_{32} ) + a_{12} ( a_{23} a_{31} - a_{21} a_{33} ) + a_{13} ( a_{21} a_{32} - a_{22} a_{31} )

(Expansion by cyclic permutation because it's easier to check. Alternative approach reverses the outside sign of the middle term and flips the terms in the bracket.)

Watch out for zero-based arrays in c++!

(Expansion by cyclic permutation because it's easier to check. Alternative approach reverses the outside sign of the middle term and flips the terms in the bracket.)

Watch out for zero-based arrays in c++!

Last edited on

Registered users can post here. Sign in or register to post.