Large Matrices using Matlab

Status
Not open for further replies.

rajivn786

Newbie level 2
Joined
May 23, 2007
Messages
2
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,302
matlab large matrices

Hi,

Can anyone tell me how to generate the following matrices using Matlab

B = [ 1
2
3
.
.
.
800]
800*800 coefficient matrix A is diagonally banded with a string of 4's down the main diagonal, a string of -1's down each of the 4 diagonals below and 4 above the main diagonal, and each of the diagonals directly above and below the main diagonal consists of the vector that starts off with [-1 -1 -1] and repeatedly takes the sequence [0 -1 -1 -1] onto this until the diagonal fills
A = [4 -1 0 0 -1 0 0 0.................. 0
-1 4 -1 0 0 -1 0 0................... 0
0 -1 4 -1 0 0 -1 0 ................... 0
0 0 -1 4 0 0 0 -1 0 0
-1 0 0 0 4 -1 0 0 ................ 0 0
0 -1 0 0 -1 4 -1 0 .................0 0
.
.
.
.

0
0 0 ----- -1 0 0 -1 4 -1
0 0 0 ... 0 -1 0 0 -1 4]
 

Is that how your matrix is supposed to look? I can't tell what you are trying to ask.
 

As per my understanding Matrix B is rom matrix and A is little confusing!
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…