Find the "I J K" indices of any element number "e" in the 2D or 3D matrix

Many a times it may be required to identify the indices, 'i','j' and 'k' values of an element number
293.0 次下载
更新时间 2012/2/14

查看许可证

Many a times it may be required to identify the indices, 'i'(row),'j'(column) and 'k'(plane) values of an element number 'e'

% SAMPLE USAGE 1
% [row,column,plane]=findijk(79,[10 10 10])
% row =
% 9
% column =
% 8
% plane =
% 1
% SAMPLE USAGE 2
% [row,column,plane]=findijk(79,[10 10])
% row =
% 9
% column =
% 8
% plane =
% 1
% SAMPLE USAGE 3
% [row,column,plane]=findijk(301,[10 10 10])
% row =
% 1
% column =
% 1
% plane =
% 4

[NOTE: Its just another method and users who are inquisitive enough to know a different approach (as with the inbuilt function ind2sub) to do the same job, would find this interesting.]

引用格式

sunil anandatheertha (2024). Find the "I J K" indices of any element number "e" in the 2D or 3D matrix (https://www.mathworks.com/matlabcentral/fileexchange/34824-find-the-i-j-k-indices-of-any-element-number-e-in-the-2d-or-3d-matrix), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R2010b
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Physics 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
版本 已发布 发行说明
1.2.0.0

In accordance with the comment on this file, i have included adequate changes in the code as regards to the code formatting and layout. Also included a NOTE in the code description.

1.1.0.0

included a small change in the title and included an errata in the description.

1.0.0.0