{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Homework5

# Homework5 -...

This preview shows pages 1–2. Sign up to view the full content.

Ford Kirkland THIS WORK I'M SUBMITTING FOR GRADING REPRESENTS MY OWN EFFORT. I DID NOT COPY IN WHOLE OR IN PART THE WORK OF OTHERS, NOR DID I HELP OTHERS CHEAT. #include <iostream> #include <iomanip> using namespace std; int main() { cout << "Please enter a 4x4 matrix one row at a time.\n"; int i=0; int j=0; int matrix [i][j]; for (i=0; i <= 3; i++) { cout << "Row " << (i+1) << ": "; for (j=0; j <= 3; j++) { cin >> matrix[i][j]; }} double det; ((matrix[1][1]*(matrix[2][2]*matrix[3][3]-matrix[2][3]*matrix[3][2]))- (matrix[2][1]*(matrix[1][2]*matrix[3][3]-matrix[1][3]*matrix{3][2]))- (matrix[3][1]*(matrix[1][2]*matrix[2][3]-matrix[1][3]*matrix{2][2])))+ (-2)((matrix[0][1]*(matrix[2][2]*matrix[3][3]-matrix[2][3]*matrix[3][2]))-

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
(matrix[2][1]*(matrix[0][2]*matrix[3][3]-matrix[0][3]*matrix{3][2]))-
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: (matrix[3][1]*(matrix[0][3]*matrix[2][3]-matrix[0][3]*matrix{2][2])))+ (3)((matrix[0][1]*(matrix[1][2]*matrix[3][3]-matrix[1][3]*matrix[3][2]))-(matrix[1][1]*(matrix[0][2]*matrix[3][3]-matrix[0][3]*matrix{3][2]))-(matrix[3][1]*(matrix[0][2]*matrix[1][3]-matrix[0][3]*matrix{1][2])))+ (-4)((matrix[0][1]*(matrix[1][2]*matrix[2][3]-matrix[1][3]*matrix[2][2]))-(matrix[1][1]*(matrix[0][3]*matrix[2][2]-matrix[0][2]*matrix{2][3]))-(matrix[2][1]*(matrix[0][2]*matrix[1][3]-matrix[0][3]*matrix{1][2]))) = det; cout << "The matrix you entered is: \n" << matrix[i][j] << "\n\n"; cout << "The determinant of this matrix is: " << det; system ("pause"); return 0; }...
View Full Document

{[ snackBarMessage ]}

### Page1 / 2

Homework5 -...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online