% Define your [A] and {C}
A=[9 4 1;
1 6 0;
1 -2 -6];
C=[-17;
4;
14];
% Point Jacobi
M=[9 0 0;
0 6 0;
0 0 -6];
N=M-A;
P=inv(M)*N;
% Find Eigenvalues of [P]
eig(P)
% Gauss-Seidel
M=[9 0 0;
1 6 0;
1 -2 -6];
N=M-A;
P=inv(M)*N;
% Find Eigenvalues of [P]
eig(P)
% Define your [A] and {C}
A=[1 2 3 4;
3 4 8 9;
8 20 4 3;
5 6 7 8];
C=[3;4;8;10];
% Point Jacobi
M=[1 0 0 0;
0 4 0 0;
0 0 4 0;
0 0 0 8];
N=M-A;
P=inv(M)*A;
eig(P)
% Gauss-Seidel
M=[1 0 0 0;
3 4 0 0;
8 20 4 0;
5 6 7 8];
N=M-A;
P=inv(M)*A;
eig(P)