[2][0] [2][1] [2][2] [2][3] [2][4] [1][0] [1][1] [1][2] [1][3] [1][4]
[0][0] [0][1] [0][2] [0][3] [0][4]
i1 are preceded by
(u1 - i1 - 1)u2
elements that have a larger first index. Since the
elements with the same first index are stored from right to left,
map(i1, i2) = (u1 - i1 - 1)u2 + i2