My adapted code

Final version of my inverse matrix code