Shift matrix
版本 1.1.0.0 (13.2 KB) 作者:
Shalin Mehta
Fast and convenient function for shifting a matrix in 2D.
The code uses array indexing to implement shifting of the matrix. It is about 2.5 times faster than using interp2 with 'nearest neighbor' option for shifting of the matrices. Inspiration for optimized array indexing comes from a snippet on circular shift in: "MATLAB array manipulations tips and tricks" guide by Peter J. Acklam (http://home.online.no/~pjacklam).
引用格式
Shalin Mehta (2024). Shift matrix (https://www.mathworks.com/matlabcentral/fileexchange/31840-shift-matrix), MATLAB Central File Exchange. 检索时间: .
MATLAB 版本兼容性
创建方式
R2010b
兼容任何版本
平台兼容性
Windows macOS Linux类别
在 Help Center 和 MATLAB Answers 中查找有关 Creating and Concatenating Matrices 的更多信息
标签
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!