Índice JS 1D para 2D Coord
y = index / width;
x = index % width;
Old-fashioned Oyster
y = index / width;
x = index % width;
index = x + width * y;