My question is how can I create the same type of matrix in a matlab program such that it keeps the same logic, that is 10s in the main diagonal, then 3s in the upper and lower diagonal surrounding the main diagonal, and ones in the diagonals above and below the 3s and 0s in other cases, and that I can be able to modify for whatever NxN I'd like?
something like this for a 6x6 case
A = [10 3 1 0 0 0 ;
3 10 3 1 0 0 ;
1 3 10 3 1 0 ;
0 1 3 10 3 1 ;
0 0 1 3 10 3 ;
0 0 0 1 3 10 ];