The matrix is generated from a matrix which looks like this: