Question: Write a function luDecomposition that takes an n x n square matrix A as an input argument and performs Gaussian elimination. The output arguments should
Write a function luDecomposition that takes an square matrix as an input argument
and performs Gaussian elimination. The output arguments should be in this order, a lower
triangular matrix an upper triangular matrix and a permutation matrix such that
If the matrix is not square, the function should return a value of for each return argument.
Note that is an empty array. You can create an empty array as follows: myVariable
; You can of course use any variable name you would like. Test your function by running
the test stub called testluDecomposition.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
