On 05/22/11 10:53, petros wrote:
Hi Larry,
apologies, for not being clear.
No problem.
Yes, MA is boost::multi_array. M, N, L are the dimensions (this is
only a "logical" statement, rather than a proper code snippet).
I think I have pretty much sorted out the calling practices wrt
multi-aray and looking for if certain functionality exists.
My problem amounts to having a view that would allow for the permutation
(if not rotation) of axes.
I'm not sure I understand permutation and rotation. For example, say
you have:
multi_array ma2(extents[3][4]);
The array would have 3 rows and 4 columns. Now, since there are only
2 axes (row and column) permuting the axes would be transposing the
matrix. Is that right. In general, for:
multi_array maN(extents[L[0]][L[1]]...[L[(N-1)]]);
a permutaion of the axes could be specified by a permutation, p, of:
(0,1,...,N-1)
and the resulting array, maT, would satisify, for all:
unsigned i[N];
such that for all axis in (0...N-1), i[axis]http://article.gmane.org/gmane.comp.lib.boost.devel/218623/match=index_list
The q_i in that post corresponds to the p vector (which is a
permutation of (0...N-1) mentioned above.
The book referenced in that post also has a section on rotation;
hence, it may be useful for that also.
[snip]
I hope this is clearer now - don't mean to drag you into my
problem. Thank you for your response,
[snip]
You're welcome, Petros.
HTH.
-Larry