These function creates a special matrix and cache its inverse