small matrix in big matrix
조회 수: 1 (최근 30일)
이전 댓글 표시
I want to put a small matrix (p*q) called B into a bigger matrix (m*n) called A. How can I do it. Matrix B should be put on the left-right corner of matrix A.
댓글 수: 3
the cyclist
2013년 6월 2일
편집: the cyclist
2013년 6월 2일
Walter's comment here http://www.mathworks.com/matlabcentral/answers/77746-small-matrix-in-big-matrix duplicates Image Analyst's comment here: http://www.mathworks.com/matlabcentral/answers/77746-small-matrix-in-big-matrix.
[Sorry. Couldn't resist teasing the master!]
채택된 답변
the cyclist
2013년 6월 2일
I don't know what "left-right corner" means, but in general you can do this as:
A = magic(7);
B = magic(3);
A(2:4,3:5) = B;
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!