matrix generation changes from 10/10