How do i create a system of matrices from a single matrix?

1 view (last 30 days)
I have a matrix A(n,n) where n is a random number btw. 5-10000. I am supposed to create a system of matrices H1, H2....Hk, for k=2,3...n with a rule that is Hk = H1 * H(k-1), while H1 = A.
Basically i have to create so many matrices until i have n of them. I am sorry if anything is insufficient, i am totaly new to Matlab and have no idea what to do about it. Do you have any ideas?

Accepted Answer

Matt J
Matt J on 3 Dec 2021
Edited: Matt J on 3 Dec 2021
H=cell(1,n);
H{1}=A;
for k=2:n
H{k}=A*H{k-1};
end

More Answers (0)

Categories

Find more on Mathematics in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!