Question: Write a Scilab function in the form function x = forwardsub(A, b) that solves the matrix equation Ax = b using forward substitution. Input: A:

Write a Scilab function in the form function x = forwardsub(A, b) that solves the matrix equation Ax = b using forward substitution. Input: A: n times n matrix (assumed to be lower triangular) b: n times 1 matrix Output: x: n times 1 matrix that solves the system Check if the matrix A is indeed upper triangular or lower triangular, respectively. If not, do nothing and set x = %nan
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
