Transforming a matrix into linear one dimensional output ?

조회 수: 2 (최근 30일)
TAUSIF
TAUSIF 2014년 3월 2일
댓글: Walter Roberson 2014년 3월 9일
hi, Suppose I have a matrix A=[1 2 3 4 5 6 7 8;9 10 11 12 13 14 15 16;17 18 19 20 21 22 23 24;25 26 27 28 29 30 31 32;33 34 35 36 37 38 39 40;41 42 43 44 45 46 47 48;49 50 51 52 53 54 55 56;57 58 59 60 61 62 63 64] Now I want linear output as [1 2 9 10 3 4 11 12 17 18 25 26 19 20 27 28 5 6 13 14 7 8 15 16 21 22 29 30 23 24 31 32 33 34 41 42 35 36 43 44 49 50 57 58 51 52 59 60 37 38 45 46 39 40 47 48 53 54 61 62 55 56 63 64];
I am in urgent need of it?
Thanks

채택된 답변

Image Analyst
Image Analyst 2014년 3월 2일
OK, I see that it's very similar to your prior question but slightly different. You have the concept. For this very specific and peculiar way of visiting all the pixels, you're just goin to have to use for loops to visit the 2x2 blocks of pixels in the specific order that you want.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Mathematics and Optimization에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by