Debug to correctly compute the result matrix for 5x5 samples