matrix with multiple matrices
8 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
hello all,
I have the following example
c1 c11 c111 c11' c111' c111......
c2 c22 c222 c22' c222' c222....
.....
ci cii ciii cii' ciii' ......
and so on where c1 is like a pointer for c11 and c111, and c11 is like a pointer for c11' c111' .... c111 is also a pointer for c11''.... and so on, the form of the above example is like pointers of pointers of pointers... in c, can you help me how to make a function to represent it as a matrix form ???
Thank you for your help
3 commentaires
Jan
le 7 Juil 2012
The explanation, that a "pointer looks like a pointer" is not helpful. I cannot imagine what a "matrix of matrices" could be also. As long as I do not know what "c11 c111" is, I cannot know, how they could be represented by c1. The quotes behind C11'' are not explained in addition. And finally no point in your question reminds me to a C++ pointer, which is simply a memory address.
I suggest either to post a handmade example or to describe the purpose of this structure.
Réponses (2)
Image Analyst
le 7 Juil 2012
Does the quote mean transpose? If so are the c square or rectangular? In general you can stitch together matrices horizontally like this:
wideMatrix = [a b c d e f];
or vertically:
tallMatrix = [a; b; c; d; e; f];
Of course the size of the dimensions have to match up along the stitching edge.
0 commentaires
Jan
le 7 Juil 2012
I guess you could mean a nested cell:
C = {{{1, 2}, {3, 4}}, {{5, 6}, {7, 8}}}
disp(C{1}{2})
But I do see only a very vague connection to the provided information.
0 commentaires
Voir également
Catégories
En savoir plus sur Matrix Indexing dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!