how to put/get a matrix from array
조회 수: 2 (최근 30일)
이전 댓글 표시
hi guys. i have 4 matrixes. i put them in a array. now i want to get the nth matrix from this array. i used B(1) (forexample) but it gives me [2×2 double].
plz help me. how i can get the nth matrix ?
s0=[1 0;0 1];
sx=[0 1;1 0];
sy=[0 -1i;1i 0];
sz=[1 0;0 -1];
B={s0 sx sy sz};
댓글 수: 0
채택된 답변
KALYAN ACHARJYA
2019년 10월 20일
편집: KALYAN ACHARJYA
2019년 10월 20일
B{1}
Do call other cell array in simillar ways.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Matrices and Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!