> why does the linterp for Wl(x,i,Phi) work without a vector
Why do you think it does?
ww(i, phi) is a 2 x 2 matrix and you use the first resp. second column of that matrix as arguments for linterp. Those columns ARE vectors (with two elements each).