Updated version of the makeCacheMatrix and cacheSolve functions allowing to calculate matrix inverse