Function advances a vector to get the next vector in the cartesian product set.
Given a vector of integers this routine returns the next vector in the cartesian product set.