code to distinguish between pass/fail in the matrix