matlab find two dimensional array indices code example Example: matlab find 2d index second_value=array(2)