(Answers Dev) Restored edit
Info
This question is locked. 请重新打开它进行编辑或回答。
some other matrices matrix
3 次查看(过去 30 天)
显示 更早的评论
N=5;
C=sparse(zeros(N-1));
C([1 end])=C([1 end])+1;
B=speye(N-1);
B([1 end])=B([1 end])-1/2;
I have B and C matrices. I can form a blockdiagonal matrix such that C on the diagonal. As follows;
E0=speye(N);
E0=E0(1:end-1,1:end-1);
T2=kron(E0,C);
But I want to change the first and the last blocks with the matrix B.( In the first block and last block instead of C there should be B matrix.)
How can I do that? (N will be a variable so the size of the matrix will change according to the written N value.)
1 个评论
回答(1 个)
This question is locked.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Operating on Diagonal Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!