Question: python For a matrix (list of list) that represents a system of linear equations, if all the diagonal entries are equal to 1 and all

python

For a matrix (list of list) that represents a system of linear equations, if all the diagonal entries are equal to 1 and all other entries except for the rightmost column are equal to 0 then the rightmost column is the solution to the system of equations.

Write a function linsy(a) that takes an input matrix (list of lists) of float variables that represent a system of linear equations. The function should return the solution of the system as a list of floats. For example, if the input is [[1,2,4],[3, 1, 0]] the output should be [.80, 2.4] since the input matrix represents the equation x+2y=4, 3x+y=0 whose solution is x=.80 and y=2.4

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!