Transforming a matrix into linear one dimensional output ?
1 次查看(过去 30 天)
显示 更早的评论
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
2 个评论
Image Analyst
2014-3-2
How is this any different than your prior question http://www.mathworks.com/matlabcentral/answers/119697#answer_126680???
采纳的回答
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 Center 和 File Exchange 中查找有关 Mathematics and Optimization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!