AAE-NA-Labs/01_Direct-Methods-for-Solving-Linear-Systems/Report/problems/Problem1.m

13 lines
312 B
Mathematica
Raw Normal View History

2023-03-11 20:08:05 +01:00
A = [2, -1, 0, 0;
-1, 2, -1, 0;
0, -1, 2, -1;
0, 0, -1, 2];
b = [0;0;0;5];
B = Alg5([A b])
B =
1.0000 0 0 0 1.0000
0 1.0000 0 0 2.0000
0 0 1.0000 0 3.0000
0 0 0 1.0000 4.0000