MATLAB: Please help with the code for Gauss Seidel Method

gauss-seidel

Please help with the code , I do not know what I am doing wrong. If you can please give me an advice. the first approximation should be x1=-0.2; x2=0.156 and x3=-.508. I have attached the code.
Please follow the format that I have already , because I will use it to do a bigger matrix 33 by 9

Best Answer

Your assigment to T should be within for loops where both sibscripts are changing
It is uncommon to call norm() passing in a single value. Also those subscripts imply the assigmnent to norm2 should be inside for loops.
Related Question