Problem 44887. Given a matrix A (size m x n) create a matrix B (size m+2 x n+2) which consists of matrix A surrounded by zeros. See Example below:
Solution Stats
Problem Comments
Solution Comments
-
1 Comment
James
on 27 Jun 2019
Looks like the image toolbox still isn't available on Cody. Otherwise, padarray would be perfect for this one.
Problem Recent Solvers140
Suggested Problems
-
5960 Solvers
-
Find the largest value in the 3D matrix
1232 Solvers
-
Generate N equally spaced intervals between -L and L
710 Solvers
-
423 Solvers
-
335 Solvers
More from this Author4
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!