Implementation of cache matrix.