Create a matrix inverse solver with caching