<Ax,y> = sum from k=1 to m of (Ax)_k * y_k
and
(Ax)_k = sum from p=1 to n of A_kp * x_p
Replace in the previous sum and change the order of the sums :
<Ax,y> = sum(k=1,m) sum(p=1,n) A_kp * x_p * y_k = sum(p=1,n) x_p * sum(k=1,m) A_kp * y_k
Notice that A_kp = (AT)_pk :
<Ax,y> = sum(p=1,n) x_p * sum(k=1,m) (AT)_pk * y_k
and sum(k=1,m) (AT)_pk * y_k = (AT y)_p
it follows that :
<Ax,y> = sum(p=1,n) x_p * (AT y)_p = <x, (AT)y>