Use MATLAB to solve the following system of linear equations
Use MATLAB to solve the following system of linear equations:
Solution
% matlab code
A = [ 28 58 34 92 2
56 118 176 451 236
28 59 103 271 120
112 235 313 874 398
224 470 626 1688 733];
b = [1; 2; 3; 4; 5];
disp (\'X1 X2 X3 X4 X5\')
x = A\\b;
disp(x);
%{
output:
x =
74.91909
-36.25348
0.64507
-0.17826
0.21739
%}
