387 |
|
if (outLevels > 1) { /* block reordering */ |
388 |
|
n = get_block_pos(r, c, outArray, outLevels); |
389 |
|
if (transpose) { |
390 |
< |
r = n/no_columns; |
391 |
< |
c = n - r*no_columns; |
392 |
< |
n = (long)r*ni_columns + c; |
390 |
> |
r = n/ni_rows; |
391 |
> |
c = n - r*ni_rows; |
392 |
> |
n = (long)c*ni_columns + r; |
393 |
|
} |
394 |
|
} else if (transpose) /* transpose only */ |
395 |
|
n = (long)c*ni_columns + r; |
439 |
|
no_columns = ni_rows; |
440 |
|
if (no_rows <= 0) |
441 |
|
no_rows = ni_columns; |
442 |
< |
if ((no_rows != ni_columns) | (no_columns != ni_rows)) |
442 |
> |
if (outLevels <= 1 && |
443 |
> |
(no_rows != ni_columns) | (no_columns != ni_rows)) |
444 |
|
goto badspec; |
445 |
|
} else { |
446 |
|
if (no_columns <= 0) |