question about matrix interleavers??

조회 수: 9 (최근 30일)
mary
mary 2013년 5월 26일
how to interleave a matrix and deinterleave it?? so it gets back to its original state?
  댓글 수: 3
mary
mary 2013년 5월 26일
interleaver: it rearrange or reshape the matrix deinterleaver : it restores the original arrangement of the maatrix
Image Analyst
Image Analyst 2013년 5월 26일
That's no answer.

댓글을 달려면 로그인하십시오.

채택된 답변

Azzi Abdelmalek
Azzi Abdelmalek 2013년 5월 26일
you can use reshape function. give an example of matrices you want to interleave
  댓글 수: 9
Azzi Abdelmalek
Azzi Abdelmalek 2013년 5월 26일
There are many function to change your matrix
flipud
fliplr
rot90
circshift
mary
mary 2013년 5월 26일
i will try these .. thank you indeed

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Image Analyst
Image Analyst 2013년 5월 26일
Not sure what you mean, but here's one way/interpretation:
m1 = magic(6)
m2 = ones(10, 6)
columns = size(m1, 2)
m1Rows = size(m1, 1)
m2Rows = size(m2, 1)
m3 = zeros(m1Rows+m2Rows, columns);
% Interleave. If there's any difference in the number of rows,
% the mismatching rows will be zero.
% You could handle that differently if you want to,
% for example, just append the remaining rows
% of the taller array.
for row = 1 : max([m1Rows, m2Rows])
m3Row = 2 * (row-1)+1;
if row <= m1Rows
m3(m3Row, :) = m1(row, :);
end
if row <= m2Rows
m3(m3Row+1, :) = m2(row, :);
end
end
m3

카테고리

Help CenterFile Exchange에서 Interleaving에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by