Problem 43117. 2D Indexes
Given in input the maximum degree P, the algorithm furnishes a ordered list of two dimensional vectors [i,j] i,j>=0 such that i+j<=P-1
P=2 indexes=[0,0;1,0;0,1]
P=3 indexes=[0,0;1,0;0,1;2,0;1,1;0,2]
Solution Stats
Problem Comments
-
2 Comments
Rafael S.T. Vieira
on 25 Sep 2020
The indexes must follow a cantor-like order for some reason, and this zig-zag should probably be added to the problem description.
Dyuman Joshi
on 26 Apr 2021
What exactly do you mean by an ordered pair? Specify it in the problem description.
Solution Comments
Show commentsProblem Recent Solvers15
Suggested Problems
-
Remove any row in which a NaN appears
8587 Solvers
-
2924 Solvers
-
Number of 1s in the Binary Representation of a Number
444 Solvers
-
Permute diagonal and antidiagonal
447 Solvers
-
If you have matrix A, create matrix B using matrix A as an "element"
120 Solvers
More from this Author2
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!