update code that 2D matrix is maked subscript