MATLAB: How to get minimum element of matrix and corresponding row elements

Control System Toolboxstatistics

Hello Dears, I have matrix A of 3X10 as below:
A=[0.250 1.000 0.111 0.040 16.000 4.000 0.360 1.563 0.111 0.563 0.000 4.000 1.000 0.360 0.000 1.000 0.160 0.063 0.028 1.000 0.250 9.000 1.778 0.040 9.000 2.250 0.360 0.563 0.444 3.063]
norm of each row (N) as follows:
N= [23.9980 7.6110 26.7480]
I want to find minimum element of N (7.6110 in this case) and corresponding row elements in matrix A.
In this case minimum element in N is 7.6110 which is appears in 2nd row, and corresponding 2nd row elements in A:[0.000 4.000 1.000 0.360 0.000 1.000 0.160 0.063 0.028 1.000]
Pl some one help how to do this. Thanks in advance

Best Answer

N = sqrt(sum(A.^2,2)); % I assume you mean the L2 norm
[Nmin,ix] = min(N);
Amin = A(ix,:);
where Nmin is the minimum row norm and Amin is the corresponding row of A.