μ[S_]:=(
p=Dimensions[S][[1]];
d=Dimensions[S][[2]];
vars=Table[Symbol["x"<>ToString[i]],{i,d}];
X=S.Transpose[{vars}];
F=ConstantArray[1,{p,1}];
r=1;
m=0;
While[r<p,
m++;
F+=X^m;
T=Flatten[CoefficientList[F,vars,ConstantArray[m+1,d]],{{1},Range[ 2,d+2]}];
r=MatrixRank[T];
];
Return[m]
)

S={{4,1},{4,3}}
μ[S]

S={{8,2},{8,4},{12,1},{8,6},{12,3},{16,0},{8,8},{12,5},{16,2},{8,10},{12,7},{16,4},{8,12},{12,9},{16,6},{8,14},{12,11}}
μ[S]