- #1
twoski
- 181
- 2
Homework Statement
Consider the n x n matrix A = diag[1,3,1]
and vector x: (1,2,3)
Determine the number of operations needed to compute the LU decomposition of this n x n matrix.
The Attempt at a Solution
So for a general n x n matrix, my prof's notes say that LU decomposition takes [itex]n^{3}/3 - n/3 + mn^{2}[/itex] operations for m right hand sides.
however this question is different since there are zeroes in the matrix. Specifically, there are only n-1 values on the left hand side of the diagonal that i need to deal with. So this means the total number of multiplications for getting the U matrix is 2(n-1) (because each multiplication affects the diagonal as well).
Does the nature of this matrix affect the operation count for the Lg=f and Ux=g calculations?