How to write code for hankle and toeplitz matrix?
显示 更早的评论
I have matrices like
F = [CA;CA^2;CA^3;CA^4;CA^5;CA^6;CA^7;CA^8;CA^9;CA^10]
and other matrix is
phi=[CB 0 0 0;
CAB CB 0 0;
CA^2B CAB CB 0;
CA^3B CA^2B CAB CB;
CA^4B CA^3B CA^2B CAB;
CA^5B CA^4B CA^3B CA^2B;
CA^6B CA^5B CA^4B CA^3B;
CA^7B CA^6B CA^5B CA^4B;
CA^8B CA^7B CA^6B CA^5B;
CA^9B CA^8B CA^7B CA^6B]
How can I do matlab coding for these matrices
3 个评论
the cyclist
2014-9-12
I assume A, B, and C variables you already have.
Matt J
2014-9-13
Does CA^2 signify C*A^2 or (CA)^2 where 'CA' is the name of one variable. Are A,B,C scalars are matrices and, if matrices, of what size?
baruch
2014-9-14
采纳的回答
更多回答(2 个)
Roger Stafford
2014-9-12
编辑:Roger Stafford
2014-9-12
phi = toeplitz(C*A.^(0:9)*B,zeros(1,4));
It is assumed that C*A^n*B is a scalar.
类别
在 帮助中心 和 File Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!