MATLAB Answers

how can i plot this matrix

1 view (last 30 days)
Mariam Gasra
Mariam Gasra on 2 May 2019
Commented: jahanzaib ahmad on 3 May 2019
lamda1=0.2;
mu1=1-lamda1;
lamda2=0.3;
mu2=1-lamda2;
A=[-(lamda1+lamda2) mu2 mu1 0;lamda2 -(mu2+lamda1) 0 mu1;lamda1 0 -(lamda2+mu1) mu2;0 lamda1 lamda2 -(mu1+mu2)];
B=[1;0;0;0];
[m n] = size(A);
[p q] = size(B);
C = zeros(m*p,n*q);
for i = 1:m
for j = 1:n
C((i-1) * p + (1:p),(j-1) * q + (1:q)) = A(i,j) * B;
end
end
i went to add for loop in the answer
for t:1:5:100
and plot the result for it
  2 Comments
jahanzaib ahmad
jahanzaib ahmad on 3 May 2019
where u want to add t ?
C is 16 X4 matrix
t= 20x 1

Sign in to comment.

Answers (0)

Products


Release

R2015b

Community Treasure Hunt

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

Start Hunting!

Translated by