AOCL-FFTZ uses a specific convention for dimension ordering in multi-dimensional FFTs. The innermost dimension is always indexed as Dim 0. This means that elements along Dim 0 are stored contiguously in memory, and this is the fastest changing dimension.
For higher-dimensional problems, Dim 1 is the next outer dimension, followed by Dim 2, and so on. In a 3D FFT, for example, Dim 0 is the innermost, Dim 1 is the middle, and Dim 2 is the outermost dimension. The outermost dimension changes the slowest in memory layout.
This ordering is important for the correctness of FFT. When specifying the dimensions in the descriptor, always list them from innermost (Dim 0) to outermost (highest Dim index).
Example: 3D matrix of shape 2x4x3
Dim 0 (size 3): innermost, elements are contiguous in memory.
Dim 1 (size 4): middle dimension.
Dim 2 (size 2): outermost, changes slowest.