Solved bug at select method of matrix