Matrix memory allocation and testing done