Eliminate an unnecessary and poorly-named local variable.
Make vMAT_pdist and vMAT_pdist2 take transposed arguments compared to their MATLAB equivalents, so vDSP_distancesq can have strides of 1.
Define vMAT_MAXDIMS (4).