created a script for caching matrix inverse